PGP key details
qadwjoh
created: 2004-07-02 06:24:42
Hi

Does anyone know of a Perl module which can take a PGP key and return details about it such as whether it's a public or private key, it's key ID, the user ID associated with the key,...etc? I tried looking on cpan, but couldn't find anything.

Thanks
A
Re: PGP key details
created: 2004-07-02 06:36:59
Try GnuPG.
Re^2: PGP key details
created: 2004-07-16 09:17:36
This is a wrapper around the GnuPG program itself. Are there any modules that don't require the software?
Re^3: PGP key details
created: 2004-07-17 03:27:24

I'm not aware of something that does what you want (extract key metadata in pure perl). But consider that driving gpg is probably the Right Way to do this: crypto is hard enough to get right, and it's better to keep your bugs in only one implementation.

Maybe it would have been cleaner if there were a libgnupg that both gpg and the Perl modules would act as frontends for, instead of gpg providing runtime hooks; but it seems to work well enough now. (There are GUI frontends to gpg that seem to interface to it in the same manner.)

What's bothering you, is it the extra dependency? Size? Performance? If you really do need a well-defined subset that's so small that it doesn't warrant bringing in gpg, perhaps you could reimplement it yourself; but I wouldn't expect many people to have had the exact same subset requirements already.

BTW, since your original post I noticed GnuPG::Interface too, but I think it follows the same design. Don't know which is newer or better.

Re^3: PGP key details
created: 2004-07-20 00:38:49
I've since learned of Crypt::OpenPGP which is pure Perl.

perlmonks.org content © perlmonks.org and gaal, qadwjoh

prlmnks.org © 2006 edmund von der burg (eccles & toad)

v 0.03