What is wrong with this code?

2008-04-06 Thread Julian
The encrypted.file is exactly as the original. Thanks in advance, julian void aes::encrypt_file(const char * key, const char * path, unsigned char * buf /*[in|out]*/) { // ... unsigned char fbuf_in[1024]; unsigned char fbuf_out[1024]; // Open the reading and writing paths.

Re: What is wrong with this code?

2008-04-06 Thread Marek . Marcola
Hello, The encrypted.file is exactly as the original. If length of your file is multiple of 16 then you will got this behavior. AES_encrypt_cbc() function does not add additional padding block in this case. void aes::encrypt_file(const char * key, const char * path, unsigned char *

what is wrong in my code?

2002-08-01 Thread LongJi Chen
hello, In serv.cpp and cli.cpp demo programs, I can't get client's certificte. Could anyone help me? begin 666 ssl.zip M4$L#!!0(`/-U`2TG@.YX\@(``,,#```*V5R=F5R+FME6V3-[*C M6 ``TZAG%%AA6J)L \$$9XGR$^W@D03\#I=W;C[;2#COIZ_8L`%-6\N!Y_

Re: what is wrong in my code?

2002-08-01 Thread Federico Sauter
Hi LongJi Chen! At a first glance the problem seems very simple: /* Get client's certificate (note: beware of dynamic allocation) - opt */ client_cert = SSL_get_peer_certificate (ssl); printf(cli %d\n, client_cert); if (client_cert == NULL) { printf (Client certificate:\n);