toofishes/python-pgpdump — pull request #10 by abeluck (2012-08-03 21:17:40+00:00)
Title: Support SecretKey (and SecretSubKey) packets (w/ tests)

I've added parsing of Secret[Sub]Key packets. You can parse nearly all data fields (except count and checksum).

If the packets are not protected, you can even access the raw private key material. If the packets are protected (i.e., encrypted) you cannot. In the future I might add support for decrypting the encrypted packets, but that would be quite some work as there are a bunch of cipher and hash algos.

FYI: you can export unprotected subkey packets with the following gnupg options:
`--export-options export-reset-subkey-passwd,export-minimal --export-secret-subkeys KEYID`