mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2025-06-19 15:18:00 +00:00
Fixed multiple use of GCM-context bug due to split-up of GCM functions
This commit is contained in:
parent
d6f41c5bcd
commit
52cf16caeb
|
@ -181,7 +181,12 @@ int gcm_starts( gcm_context *ctx,
|
||||||
const unsigned char *p;
|
const unsigned char *p;
|
||||||
size_t use_len;
|
size_t use_len;
|
||||||
|
|
||||||
|
memset( ctx->y, 0x00, sizeof(ctx->y) );
|
||||||
|
memset( ctx->buf, 0x00, sizeof(ctx->buf) );
|
||||||
|
|
||||||
ctx->mode = mode;
|
ctx->mode = mode;
|
||||||
|
ctx->len = 0;
|
||||||
|
ctx->add_len = 0;
|
||||||
|
|
||||||
if( iv_len == 12 )
|
if( iv_len == 12 )
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue