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.


In reply to Re^3: PGP key details by gaal
in thread PGP key details by qadwjoh

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.