On Wed, 2 May 2001 [EMAIL PROTECTED] wrote:

> If I use the code below to encrypt and decrypt it doesn't always produce the 
> same results.  The majority of the time it works but I can't find anything 
> explaining why it doesn't work 100% of the time.
> 
> void EnDe(unsigned char *buf)
> {
>     RC4_KEY key;
>     unsigned char keys[17] = "s1fuk8wfe4hj9ksi";
>     
>     RC4_set_key(&key,keys[0],&(keys[1]));
> 

I have not used RC4 routines before, just the RSA but strlen() wont work
on encrypted data because it can have null's now I am not sure if this is
the case or not w/ RC4 or not.  Its ok to encrypt w/ strlen() because you
are in theory encrypting text (or not?).

-jay

>     RC4(&key,strlen((const char *)buf), buf, buf);
>     
> }
> ______________________________________________________________________
> OpenSSL Project                                 http://www.openssl.org
> User Support Mailing List                    [EMAIL PROTECTED]
> Automated List Manager                           [EMAIL PROTECTED]
> 

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

Reply via email to