This link has been bookmarked by 3 people . It was first bookmarked on 02 Mar 2006, by Alberto Adrián Schiano.
-
01 Jul 08
-
24 Feb 06
-
Expect.pm Test Program One
The following test program runs the unreliable program twenty times. If the unreliable program takes longer than five seconds, the attempt to run it is terminated and the test program continues. -
Note: This isn't really a Perl thing, but I'm using it for Perl scripts and it's too handy not to share
-
This node How to Make Crypt::DSA use a your key to sign something got me thinking about how to extend Crypt::DSA's potential, to make public and private keys, for signing verification. The script below, will verify 2 ways, once with scalars inside the script, and once from files. The generated sig, is actually binary, so note the base64 encoding of it, for attachment to emails, etc. I must thank sisyphus for the trick of reblessing a hash back into an object. This is the critical part of the script, where the public and private keys are generated. The docs for Crypt::DSA don't show how to separate them,( and you wouldn't want to be distributing your private key in the public PEM file. :-)
-
looking at a post by Sisyphus on comp.lang.perl. misc, it seems that you CAN use the numeric keys, like you tried in your original post. He showed a neat trick ( which I will have to explore further) where he reblessed the key data, and it works.
-
here is a working example. This script shows 2 ways, one is saving the key to a file and reading it back in, the other, just hard codes the file contents into a variable. I tried a few things to avoid a temp file, but no luck. There is a Content type for the write, but it dosn't seem to work for scalar....it still writes a file.
-
How to Make Crypt::DSA use a your key to sign something
-
Because PHP sucks: escape to Perl
-
-
11 Sep 04
Page Comments
Would you like to comment?
Join Diigo for a free account, or sign in if you are already a member.