On Wed, Jul 03, 2002 at 02:58:45PM +0200, Judith Retief wrote:
> 
>   I have to encrypt and decrypt an RSA key using symmetrical encryption,
> using RC4 or one of the other symmetrical encryption APIs. I'm working in C.
> 
> 
>   But I assume I can't just give the RSA key struct to the encryption
> algorithm as input data; its members are BIGNUM pointers so the structure
> has dynamic data that is not part of the struct footprint. I need to stream
> the RSA struct into a continious memory byte buffer to give to the
> encryption algorithm, and after decrypting this stream I need to build up
> the RSA key struct from it. 
> 
>   Are there standard functions available for these streaming functions? Or
> do I have to pull apart the pem_asn1_write/read() functions and implement my
> own? Am I guaranteed that the internal structure of the RSA struct will
> remain the same?

It is ASN.1 and DER that are here to guarantee encoded data will be
restored on any platform

> 
>   Regards, 
>      Judith
> ______________________________________________________________________
> OpenSSL Project                                 http://www.openssl.org
> User Support Mailing List                    [EMAIL PROTECTED]
> Automated List Manager                           [EMAIL PROTECTED]

-- 
Naina library: http://www.unity.net/~vf/naina_r1.tgz
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to