diff options
author | lloyd <[email protected]> | 2010-10-29 15:15:30 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2010-10-29 15:15:30 +0000 |
commit | 66b163323d39ac5c0be30fd0b1c0fd91b64a55f3 (patch) | |
tree | e745b4824105f600ec5452e591a112229bc01478 /src/block/aes | |
parent | 89a2e78d2ff2f0266825708a0294b13a4c370a29 (diff) |
Make MemoryRegion::set protected, change all callers
Diffstat (limited to 'src/block/aes')
-rw-r--r-- | src/block/aes/aes.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/block/aes/aes.cpp b/src/block/aes/aes.cpp index f149a0ac0..b19699dbc 100644 --- a/src/block/aes/aes.cpp +++ b/src/block/aes/aes.cpp @@ -666,8 +666,10 @@ void aes_key_schedule(const byte key[], size_t length, store_be(XEK[i], &MD[4*i]); } - EK.set(&XEK[0], length + 24); - DK.set(&XDK[0], length + 24); + EK.resize(length + 24); + DK.resize(length + 24); + copy_mem(&EK[0], &XEK[0], EK.size()); + copy_mem(&DK[0], &XDK[0], DK.size()); } } |