diff options
author | lloyd <[email protected]> | 2012-05-18 13:58:23 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2012-05-18 13:58:23 +0000 |
commit | 2c3dc93d6466a9215d585613fb55f5222ce70d10 (patch) | |
tree | 9d44c738fdbb79103bed2d34c8fb171f8eaa00a2 /src/pk_pad/emsa2/emsa2.cpp | |
parent | c2d0d2982e96ab7ce15e90b8d73c9774e2650d86 (diff) |
First step towards replacing the existing containers with std::vector
with a custom allocator; remove the 3 argument version of
MemoryRegion::copy, replacing with freestanding buffer_insert
function.
Diffstat (limited to 'src/pk_pad/emsa2/emsa2.cpp')
-rw-r--r-- | src/pk_pad/emsa2/emsa2.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pk_pad/emsa2/emsa2.cpp b/src/pk_pad/emsa2/emsa2.cpp index 96ac8e908..50ea7dbe3 100644 --- a/src/pk_pad/emsa2/emsa2.cpp +++ b/src/pk_pad/emsa2/emsa2.cpp @@ -39,7 +39,7 @@ SecureVector<byte> emsa2_encoding(const MemoryRegion<byte>& msg, output[0] = (empty ? 0x4B : 0x6B); output[output_length - 3 - HASH_SIZE] = 0xBA; set_mem(&output[1], output_length - 4 - HASH_SIZE, 0xBB); - output.copy(output_length - (HASH_SIZE + 2), &msg[0], msg.size()); + buffer_insert(output, output_length - (HASH_SIZE + 2), &msg[0], msg.size()); output[output_length-2] = hash_id; output[output_length-1] = 0xCC; |