This commit is contained in:
Max Lv
2015-12-01 12:12:46 +08:00
parent dbbaae6b99
commit d57b63fd31
+1 -1
View File
@@ -1241,7 +1241,7 @@ int ss_decrypt_all(buffer_t *cipher, int method, int auth)
static buffer_t tmp = { 0 };
brealloc(&tmp, cipher->len, cipher->capacity);
buffer_t *plain = &tmp;
plain->len = cipher->len;
plain->len = cipher->len - iv_len;
uint8_t iv[MAX_IV_LENGTH];
memcpy(iv, cipher->array, iv_len);