in reply to
Re: Stumped by Crypt::OpenPGP::Signature->key_id
in thread Stumped by Crypt::OpenPGP::Signature->key_id
Sorry, but I don't see how that helps.
The node mentioned has nothing to do with the issue at hand.
Yup, just nostalgia
The Searchlink doesn't work.
Sorry if you have to copy/paste, at least I made it tab-key navigable (couldn't have posted the link otherwise )
There is no Crypt::OpenPGP::Signature->key_id_hex
Too bad, it was worth a shot
Anyway, hex of anything is
$ perl -le " print unpack qw/H*/, $_ for @ARGV; " 1 aSdF82
Now I remember why I linked Crypt OpenPGP Brain twister, its a Short, Self Contained, Correct Example, in otherwords, more effective :)
If you modify Crypt-OpenPGP-1.06\t\12-sign.t at the first verify call, you can see that this is to be expected
my( $signer , $sigobj ) = $pgp->verify( Signature => $sig );
use DDS; die Dump( [ $key_id , $sigobj->key_id, unpack('H*', $sigo
+bj->key_id ) , pack('H*',$key_id) ] );
$ARRAY1 = [
I don't know if keyid is supposed to be 8 or 10 or 16, but the round trip with pack seems to work , so key_id is correct, and the hex representation is correct
AFAIK printf would actually try to convert it, which might overflow as in
$ perl -le " print 0x39f560a90d7f1559
Integer overflow in hexadecimal number at -e line 1.
Maybe this is the private key, and you're looking for the public key? Maybe it depends on algorithm? :)
shiny regexes and rules offered by Perl 6
other CPAN module
by looking at it on my monitor
I print it and I read it in spare time
first I convert it into $FORMAT, then I parse it
I hire someone to do it
using my custom module
I write a brand new language to do the task
on the server where I play as human, XML is forbidden
what is XML?
I speak XML natively
I write a new grammar for Perl 6
some other way
Results (283 votes),