Yeah, I just got all the pre-requisites installed, and see the problem in my testing....sorry if I led you off track. After a groups.google.search for the problem, it has been asked before on the newsgroups. What it seems to come down to, is that you cannot just take the Dump
$key{"priv_key"} = "864936564936746739711078786791024560681741810216";
and use that as a private key. The "key" must be a Crypt::DSA::Key object. From the looks of things, you need to save your key to a file, like
$key->write( Type => 'PEM', Filename => $keyfile);
then when you want to import that file
$key = Crypt::DSA::Key->new(Type => 'PEM', Filename => $keyfile);
Now whether you can read that into a scalar value, I don't know. But the PEM key should look like
-----BEGIN DSA PRIVATE KEY----- MIH3AgEAAkEAuu/8bF0QtFaU8Eo3XzJzyuwyfIEoCvYxzcx5dGkTa7przkVGPaJp n6uEPIueBQEP21+SmfebPpkbKF98gw+MSwIVAMGFQpGtsAWNedBzQ85p0CkTuKYZ AkBLciRf48J8u/LYz2FejmaPs88sKPt/mNLLfzOUz6LO0HqjXOq6vD0WzGcek0Z6 VK9JD3r9eyclPNvsArZ7v/LaAkBxM58UjEqschS9r7Je28kCQ4eYC4lhkRq+pAot /kh86LBlohQZ6A6zgCyPiKNLT5VQ29vKW49f36XjYrIDUk21AhQdRFsMvKVp+W5C 7L7i0FLp3tYb6w== -----END DSA PRIVATE KEY-----
and NOT the number string you originaly had. I will post an example if I can get it to work. :-)

I'm not really a human, but I play one on earth. flash japh

In reply to Re^3: How to Make Crypt::DSA use a your key to sign something by zentara
in thread How to Make Crypt::DSA use a your key to sign something by xorl

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.