> buff = (char *)malloc(bptr->length);
> memcpy(buff, bptr->data, bptr->length-1);
> buff[bptr->length-1] = 0;
Umm, you don't copy the last byte of data. You don't allocate enough space to
hold the data and a terminator. This is probably your main error. How will
'buff' hold a C-style string wh
> When i use to encrypt data, i have not problems.. when i
> decrypt the result of this code, i have not problem...
> when i decrypt with this program, i have
> 13015:error:06065064:digital envelope routines:
> EVP_DecryptFinal_ex:bad decrypt:evp_enc.c:461:
> The EVP_DecryptUpdate works ok, dec
Hi i'm having problems with the function EVP_DecryptFinal_ex... i have
the next code:
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#define LEN_KEY 16
#define ENC_SIZE 512000
#define MSG_SIZE 512000
#define ENCRIPTA 1
ciphertext?
> thanks
> -Original Message-
> From: owner-openssl-us...@openssl.org
> [mailto:owner-openssl-us...@openssl.org] On Behalf Of Victor Duchovni
> Sent: Thursday, January 15, 2009 3:00 PM
> To: openssl-users@openssl.org
> Subject: Re: Help with EVP_DecryptFinal_
: Re: Help with EVP_DecryptFinal_ex:bad decrypt
On Thu, Jan 15, 2009 at 02:45:49PM -0500, Adam Bender wrote:
> > BUG: Don't pass the same buffer/offset to EncryptFinal_ex(), this
clobbers
> > the first encrypted block. Instead use "sym_out_buf + out_total" if
the
> &g
On Thu, Jan 15, 2009 at 02:45:49PM -0500, Adam Bender wrote:
> > BUG: Don't pass the same buffer/offset to EncryptFinal_ex(), this clobbers
> > the first encrypted block. Instead use "sym_out_buf + out_total" if the
> > buffer is long enough for both the original ciphertext and the final block.
>
On Thu, Jan 15, 2009 at 2:29 PM, Victor Duchovni <
victor.ducho...@morganstanley.com> wrote:
> On Wed, Jan 14, 2009 at 06:17:28PM -0500, Adam Bender wrote:
>
> > if (!EVP_EncryptUpdate(&ctx, sym_out_buf, &out_total, (const unsigned
> char
> > *) data, data_len)) {
> > ERR_print_errors_fp(std
On Wed, Jan 14, 2009 at 06:17:28PM -0500, Adam Bender wrote:
> if (!EVP_EncryptUpdate(&ctx, sym_out_buf, &out_total, (const unsigned char
> *) data, data_len)) {
> ERR_print_errors_fp(stdout); }
> if (!EVP_EncryptFinal_ex(&ctx, sym_out_buf, &out_len)) {
> ERR_print_errors_fp(stdout); }
BU
Hi, I'm trying to write simple AES encryption/decryption routines. I'm
having trouble with the decryption routine, specifically, I get this error:
27013:error:06065064:digital envelope routines:EVP_DecryptFinal_ex:bad
decrypt:evp_enc.c:461:
I've included my code below; I compile it with:
g++ -o
After doing this I could encrypt / decrypt upto 7 KB only.
The code fails after 7 KB.
Please help.
thanks
From: [EMAIL PROTECTED]
To: openssl-users@openssl.org
Subject: RE: Reposting: EVP_DecryptFinal_ex:bad decrypt
Date: Wed, 21 Nov 2007 01:32:12 +
Thanks for the response Dr
));
for(int i=0;i Date: Mon, 19 Nov 2007 21:52:35 +0100
> From: [EMAIL PROTECTED]
> To: openssl-users@openssl.org
> Subject: Re: Reposting: EVP_DecryptFinal_ex:bad decrypt
>
> On Mon, Nov 19, 2007, Pankaj Mathur wrote:
>
> >
> > I am still strugglin
On Mon, Nov 19, 2007, Pankaj Mathur wrote:
>
> I am still struggling with this issue.
> I did not get much help from the list, so I am reposting again.
>
if(!EVP_EncryptUpdate(&ctx,&pBuff[currentLength],
&datalength,
I am still struggling with this issue.
I did not get much help from the list, so I am reposting again.
Thanks!
> From: [EMAIL PROTECTED]
> To: openssl-users@openssl.org
> Subject: EVP_DecryptFinal_ex:bad decrypt
> Date: Fri, 9 Nov 2007 22:33:52 +
>
> Hi ,
>
> I
Hello Pankaj,
Am 09.11.2007 um 23:33 schrieb Pankaj Mathur:
Hi ,
I am trying to encrypt and decrypt a large file using the Openssl
API.
I am doing this by calling EVP_EncryptUpdate / EVP_DecryptUpdate
iteratively for a block size of 1024 and then calling the
EVP_EncryptFinal_ex/ EVP_Dec
Hi ,
I am trying to encrypt and decrypt a large file using the Openssl API.
I am doing this by calling EVP_EncryptUpdate / EVP_DecryptUpdate iteratively
for a block size of 1024 and then calling the EVP_EncryptFinal_ex/
EVP_DecryptFinal_ex respectively in the end.
It always fails to decrypt fo
Hi ,
I am trying to encrypt and decrypt a large file using the Openssl API.
I am doing this by calling EVP_EncryptUpdate / EVP_DecryptUpdate iteratively
for a block size of 1024 and then calling the EVP_EncryptFinal_ex/
EVP_DecryptFinal_ex respectively in the end.
It always fails to decrypt fo
16 matches
Mail list logo