Finding the key-id of an armoured key

Burns burns@runbox.com
Sat Jan 11 00:18:02 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Paste it into the text window at:
http://www.pgpdump.net/

That will give you all sorts of information about the public key,
including the key ID.


Randy

On Friday, January 10, 2003, you wrote:

> I need to be able to establish various details about a key (public or 
> secret) that is held as armoured text, preferably without having to 
> import it into a keyring first.
> 
> Many can be parsed from the output of "gpg --list-packets 
> /path/to/file" 
> but I can see no reliable way of getting the key id or its digest 
> algorithm from this. The digest algorithm can probably be established 
> from a self-signature if I know what the key id is so that I can match 
> it.
> 
> The best I can come up with for the key id is to import the key into a 
> temporary keyring and then use --fingerprint, along with options to 
> restrict it to the temporary key ring, and parse the output from there. 
> This has a lot of problems for me though, and I'd prefer something 
> cleaner. It also doesn't work for secret keys, AFAICT.
> 
> Any suggestions as to how I can get this information. I'm sure it 
> should 
> be simple, but I just can't see it.
> -- 
> Chris Hastie
> 
> 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1-nr1 (Windows Me) - GPGshell v2.65
Comment: 0x3D78B385 / 0x2CECAE1F - http://www.geocities.com/burns98

iD8DBQE+H1PNhNLaTSzsrh8RAikCAKDb4mjt42N//MkWOmFBXGRC/FFtLQCgoklJ
6MdOFQMqmD3N6sfNokVYwmM=
=hzx+
-----END PGP SIGNATURE-----