From 15fe01c368550bb06bcaad88fb34b7e251f7c0d2 Mon Sep 17 00:00:00 2001 From: Nick Thomas Date: Thu, 8 Aug 2013 08:24:55 +0100 Subject: [PATCH] Fix a bug where we included the IV in the data to decrypt while unwrapping --- pass-1/rlocs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pass-1/rlocs.c b/pass-1/rlocs.c index 75d1012..52bdec7 100644 --- a/pass-1/rlocs.c +++ b/pass-1/rlocs.c @@ -607,7 +607,7 @@ ssize_t rlocs_decrypt( struct rlocs *reg, struct rloc *x, struct rloc *y, unsign goto fail; } - if ( !EVP_DecryptUpdate( &entry->ctx, dest, &outl, data, data_len ) ) { + if ( !EVP_DecryptUpdate( &entry->ctx, dest, &outl, data + 16, data_len - 16 ) ) { warn( "EVP_DecryptUpdate() failed" ); goto fail; }