Mailing List Archive

PGP5/gpg armoring
Okay, this seems to make PGP5 happy with my key:
gpg -z 0 --rfc1991 --no-comment --export bem > bem.key
pgpk -v -a ./bem.key

But if I add an '-a' to the GPG line for armoring the key, PGP5 refuses
to read it.

It looks like the armoring isn't quite compatible between the two.

Unless, of course, I'm doing something wrong.

BTW, this is a damned nice tool. Thanks. (Now if people would just
stop using RSA/IDEA.... And if the US Gov't didn't make even digital
signatures pointless...)

--
Brian Moore | "The Zen nature of a spammer resembles
Sysadmin, C/Perl Hacker | a cockroach, except that the cockroach
Usenet Vandal | is higher up on the evolutionary chain."
Netscum, Bane of Elves. Peter Olson, Delphi Postmaster
Re: PGP5/gpg armoring [ In reply to ]
brian moore <bem@cmc.net> writes:

> Okay, this seems to make PGP5 happy with my key:
> gpg -z 0 --rfc1991 --no-comment --export bem > bem.key
> pgpk -v -a ./bem.key
>
> But if I add an '-a' to the GPG line for armoring the key, PGP5 refuses
> to read it.

I think you can't use --rfc1991 as this does not produce OpenPGP/PGP 5
armor headers.

The "-z 0" is not needed anymore.


Werner
Re: PGP5/gpg armoring [ In reply to ]
On Mon, Sep 28, 1998 at 10:02:52AM +0200, Werner Koch wrote:
> brian moore <bem@cmc.net> writes:
>
> > Okay, this seems to make PGP5 happy with my key:
> > gpg -z 0 --rfc1991 --no-comment --export bem > bem.key
> > pgpk -v -a ./bem.key
> >
> > But if I add an '-a' to the GPG line for armoring the key, PGP5 refuses
> > to read it.
>
> I think you can't use --rfc1991 as this does not produce OpenPGP/PGP 5
> armor headers.

Nope:

[thorin:~] 9:29:10am 64 % gpg --no-comment -a --export bem > bem.asc
gpg (GNUPG) 0.4.0; Copyright (C) 1998 Free Software Foundation, Inc.
This program comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to redistribute it
under certain conditions. See the file COPYING for details.

[thorin:~] 9:29:18am 65 % pgpk -v -a ./bem.asc
Cannot open configuration file /home/bem/.pgp/pgp.cfg
Unable to import keyfile "./bem.asc".

But this works fine:

[thorin:~] 9:33:19am 82 % gpg --no-comment --export bem > bem.key
gpg (GNUPG) 0.4.0; Copyright (C) 1998 Free Software Foundation, Inc.
This program comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to redistribute it
under certain conditions. See the file COPYING for details.

[thorin:~] 9:33:20am 83 % pgpk -v -a ./bem.key
Cannot open configuration file /home/bem/.pgp/pgp.cfg

Adding keys:

Key ring: './bem.key'
Type Bits KeyID Created Expires Algorithm Use
pub 1024 0x44ABF134 1998-09-22 ---------- DSS Sign &
Encrypt
sub 1024 0xD087374B 1998-09-22 ---------- Diffie-Hellman

uid brian moore <bem@cmc.net>
uid brian moore <bem@thorin.cmc.net>
uid brian moore <bem@news.cmc.net>

1 matching key found

My guess is it's the armoring that PGP5 is being picky about:

If I add the above key (via binary, which works) to PGP5 and then export
it, adjust the GPG key to 64 columns and then run a diff:

(gpg -a --no-comment --export bem > bem.asc
pgpk -xa bem > bem1.asc
diff bem.asc bem1.asc
after accepting the above key.)

2,3c2
< Version: GNUPG v0.4.0 (GNU/Linux)
< Comment: Get GNUPG from ftp://ftp.guug.de/pub/gcrypt/
---
> Version: PGP for Personal Privacy 5.0
14,29c13,28
< cmUgPGJlbUBjbWMubmV0PohXBBMRAgAXBQI2By9aAwsEAwUVAwIGAQMWAgECF4AA
< CgkQESResESr8TRP5QCfcAJDPzf+Zkrrp6dBMZEOHCsSKd4AoKF5NHEDysuxWLwf
< zVeBhVRmTKNXtCBicmlhbiBtb29yZSA8YmVtQHRob3Jpbi5jbWMubmV0PohXBBMR
< AgAXBQI2BzgwAwsEAwUVAwIGAQMWAgECF4AACgkQESResESr8TRIQACgg+9SLal+
< Jplge0HEXLg+qGmfOj0An3a5W7TBCgQN9f20WzIyQUSeYlh/tB5icmlhbiBtb29y
< ZSA8YmVtQG5ld3MuY21jLm5ldD6IVwQTEQIAFwUCNgc4UgMLBAMFFQMCBgEDFgIB
< AheAAAoJEBEkXrBEq/E0pEIAoMonkkOYKMyeKolWyUE9u+9XQN/z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yMi0xSnZ3Jz6At7lbiTob+dAehYqs5pacE
> b4AZYlhlTGjdzn6ZRMayIxLeESXOqagijdxzttK6pWR1D6fgZW5e2+zuBCEgRKs5
> BTYjTBrl/IKW+PcABA0D/0nlOtYu92jIFqkZtPQpEWiXRyuyw2u1xvgHPJFIJHW6
> Ft7fXK1SC2shrOxQPE+okSG+ZkjGJHSYepvtcx7XWiwwWqOlGg8JrsLTP9xBi5EX
> hlKIucM02CGzyn4Eftrt2W/Wjb6v3ejnTlBV+HcLA2/4pFYF1BV0b3HYVfedGkGz
> iQBGBBgRAgAGBQI2By+QAAoJEBEkXrBEq/E0EJIAn2IlMCEEAkF6fpm7s9c13dkA
> aV3uAJ43EIgWz+7T6r3aX/U5Fcz7vTo47A==
> =49W3

It appears to get out of sync with PGP's for some reason.

I think this is the reason the Internic won't accept my GPG keys
being added.

--
Brian Moore | "The Zen nature of a spammer resembles
Sysadmin, C/Perl Hacker | a cockroach, except that the cockroach
Usenet Vandal | is higher up on the evolutionary chain."
Netscum, Bane of Elves. Peter Olson, Delphi Postmaster
Re: PGP5/gpg armoring [ In reply to ]
Well, I've been able to import pgp5 secret keys in my gpg keyring (I've
removed the pgp passphrase, then exported the key from secring.skr and
reimported the same in gpg secret keyring and finally replaced the
passprhase) and gpg is now able to decrypt messages encrypted by pgp5 using
the pubkey.
But If I try to encrypt a message using gpg, I get a
Unusable pubkey algorithm
What does it means?
Maybe the pgp pubkey have a invalid lenght?

pub 1024D/40AC5709 1997-09-03 Fabio Coatti <cova@felix.unife.it>
sub 4096g/96E96B20 1997-09-03

And I'm unable to check signatures (with pgp5) made with gpg
using the same key. Has anyone tried something liker this? Any success?
Thanks for any help...

--
Fabio Coatti
2:332/409.414 Fidonet
cova@felix.unife.it Internet
http://felix.unife.it/~cova Home page
Old SysOps never die... they simply forget their password.
Re: PGP5/gpg armoring [ In reply to ]
Okay, here's another example that may explain the problem better or may
be a different problem:

[thorin:~] 11:43:53am 183 % cat test1.txt
1
2
3
4
5
[thorin:~] 11:44:01am 184 % gpg --clearsign test1.txt
gpg (GNUPG) 0.4.0; Copyright (C) 1998 Free Software Foundation, Inc.
This program comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to redistribute it
under certain conditions. See the file COPYING for details.

[thorin:~] 11:45:08am 185 % pgpv test1.txt.asc -o test1a.txt
Opening file "test1a.txt" type text.
Opening file "/dev/null" type text.
[thorin:~] 11:45:41am 186 % diff test1.txt test1a.txt
1,5c1,5
< 1
< 2
< 3
< 4
< 5
---
> 1
> 2
> 3
> 4
> 5
\ No newline at end of file

In short, it's losing the last character if it's a newline.

(It doesn't seem to lose it if you're naughty and make a file with no
closing newline.)

--
Brian Moore | "The Zen nature of a spammer resembles
Sysadmin, C/Perl Hacker | a cockroach, except that the cockroach
Usenet Vandal | is higher up on the evolutionary chain."
Netscum, Bane of Elves. Peter Olson, Delphi Postmaster
Re: PGP5/gpg armoring [ In reply to ]
brian moore <bem@cmc.net> writes:

> Okay, here's another example that may explain the problem better or may
> be a different problem:
[...]
> In short, it's losing the last character if it's a newline.

That is another problem and I know about it. You should have noticed
that the signature is valid and that is what counts most :-)

I have put the armoring problems on my todo list and I will see what I
can do - I have some keys which I can't import due to some related
problems.

Werner