aboutsummaryrefslogtreecommitdiff
path: root/crypto/modes/wrap128.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/modes/wrap128.c')
-rw-r--r--crypto/modes/wrap128.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/modes/wrap128.c b/crypto/modes/wrap128.c
index 4dcaf0326fa8..384978371af2 100644
--- a/crypto/modes/wrap128.c
+++ b/crypto/modes/wrap128.c
@@ -76,7 +76,7 @@ size_t CRYPTO_128_wrap(void *key, const unsigned char *iv,
return 0;
A = B;
t = 1;
- memcpy(out + 8, in, inlen);
+ memmove(out + 8, in, inlen);
if (!iv)
iv = default_iv;
@@ -113,7 +113,7 @@ size_t CRYPTO_128_unwrap(void *key, const unsigned char *iv,
A = B;
t = 6 * (inlen >> 3);
memcpy(A, in, 8);
- memcpy(out, in + 8, inlen);
+ memmove(out, in + 8, inlen);
for (j = 0; j < 6; j++) {
R = out + inlen - 8;
for (i = 0; i < inlen; i += 8, t--, R -= 8) {