Hi again,

Yes, ecdsa_sig is defined like

{
    int r;
    int s;
}

But the problem is that I don't know how to get my SignaturValue which is 
"724PlFGHTTL1cFlLFU6g6UetcPVBEAN6oNpogAUx3rgELFH86gA+NqvjVf316zek" into this 
struct. 

The function d2i_ECDSA_SIG which should fill this struct always return -1; ;o(


Jürgen

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of jimmy
Sent: Dienstag, 20. März 2007 11:32
To: openssl-users@openssl.org
Subject: Re: Problem with ecdsa

Jürgen Heiss wrote:
> Hi Jim,
> 
> First of all thanks for your fast answer.
> But still it don't understand 100%!
> If have an SignatureValue which is
> 
> 724PlFGHTTL1cFlLFU6g6UetcPVBEAN6oNpogAUx3rgELFH86gA+NqvjVf316zek
> 
> But how can I but this now into an ECDSA_SIG struct?
> 
> Jürgen
>  

[not sure of the openssl aspect, somebody correct me if i'm wrong]

ecdsa_sig is defined as two integers:

{
   int r;
   int s;
}

normally with ecdsa, signatures have sizeof(r) == sizeof(s) == sizeof(prime 
field). if you use a 160-bit prime field then you have a 40 byte signature (20 
byte r, 20 byte s).

you divide the total length into half and the first half could be 'r' 
and second half 's' (or vice versa depending on how your ECDSA_SIG is defined).


-jb
-- 
mathematician, n.:
         Some one who believes imaginary things appear right before your 
i's.

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]


______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to