aboutsummaryrefslogtreecommitdiffstats
path: root/src/hash/md5/md5.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/hash/md5/md5.cpp')
-rw-r--r--src/hash/md5/md5.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/hash/md5/md5.cpp b/src/hash/md5/md5.cpp
index 7c280aab7..8c1e5a8e1 100644
--- a/src/hash/md5/md5.cpp
+++ b/src/hash/md5/md5.cpp
@@ -64,9 +64,7 @@ void MD5::compress_n(const byte input[], u32bit blocks)
for(u32bit i = 0; i != blocks; ++i)
{
- for(u32bit j = 0; j != 16; ++j)
- M[j] = load_le<u32bit>(input, j);
- input += HASH_BLOCK_SIZE;
+ load_le(M.begin(), input, M.size());
FF(A,B,C,D,M[ 0], 7,0xD76AA478); FF(D,A,B,C,M[ 1],12,0xE8C7B756);
FF(C,D,A,B,M[ 2],17,0x242070DB); FF(B,C,D,A,M[ 3],22,0xC1BDCEEE);
@@ -108,6 +106,8 @@ void MD5::compress_n(const byte input[], u32bit blocks)
B = (digest[1] += B);
C = (digest[2] += C);
D = (digest[3] += D);
+
+ input += HASH_BLOCK_SIZE;
}
}
@@ -123,7 +123,7 @@ void MD5::copy_out(byte output[])
/*
* Clear memory of sensitive data
*/
-void MD5::clear() throw()
+void MD5::clear()
{
MDx_HashFunction::clear();
M.clear();