diff options
Diffstat (limited to '')
-rw-r--r-- | src/lib/libcrypto/aes/aes_ctr.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/libcrypto/aes/aes_ctr.c b/src/lib/libcrypto/aes/aes_ctr.c index 8e800481de..aea3db2092 100644 --- a/src/lib/libcrypto/aes/aes_ctr.c +++ b/src/lib/libcrypto/aes/aes_ctr.c | |||
@@ -106,8 +106,8 @@ void AES_ctr128_encrypt(const unsigned char *in, unsigned char *out, | |||
106 | 106 | ||
107 | while (l--) { | 107 | while (l--) { |
108 | if (n == 0) { | 108 | if (n == 0) { |
109 | AES_ctr128_inc(counter); | ||
110 | AES_encrypt(counter, tmp, key); | 109 | AES_encrypt(counter, tmp, key); |
110 | AES_ctr128_inc(counter); | ||
111 | } | 111 | } |
112 | *(out++) = *(in++) ^ tmp[n]; | 112 | *(out++) = *(in++) ^ tmp[n]; |
113 | n = (n+1) % AES_BLOCK_SIZE; | 113 | n = (n+1) % AES_BLOCK_SIZE; |