Hello, I have the following question:
unsigned char *plaintext = "Test message"; unsigned char * ciphertext=NULL; RSA *rsa =...; /*here I have an RSA key */ RSA_public_encrypt(strlen(plaintext), plaintext, ciphertext, rsa, RSA_PKCS1_OAEP_PADDIN*G* ); What will be the length of ciphertext? When I use RSA_private_decrypt (flen, ...) to decrypt the message just encrypted, what should I pass to fuction as the first argument? (I read a mail thread with a similar problem with enc/dec, and there was suggested to avoid determination of ciphertext using 'strlen', because it may be not null-terminated). Thanks in advance. Arsen. -- PGP Key: ID 0xBBE3DFD8 (expires: 2006-08-03) Fingerprint: 1C3B 2C01 40DF ED87 23B1 BF6F 95C4 2E77 BBE3 DFD8
smime.p7s
Description: S/MIME Cryptographic Signature