diff options
author | weidai <weidai11@users.noreply.github.com> | 2009-03-10 02:56:19 +0000 |
---|---|---|
committer | weidai <weidai11@users.noreply.github.com> | 2009-03-10 02:56:19 +0000 |
commit | 8ca6148ad5a4943ab05491d7f02152351e650f43 (patch) | |
tree | 1c52d52d455d3b48e60bfc8b075f4d611068be14 /vmac.cpp | |
parent | da24db2a8b834ba3c3ee5c54041ff3782e9c1984 (diff) | |
download | cryptopp-git-8ca6148ad5a4943ab05491d7f02152351e650f43.tar.gz |
add x86/x64 assembly for SHA-256,
add DEFAULT_CHANNEL and AAD_CHANNEL,
fix macChannel for AuthenticatedEncryptionFilter
Diffstat (limited to 'vmac.cpp')
-rwxr-xr-x | vmac.cpp | 9 |
1 files changed, 3 insertions, 6 deletions
@@ -57,12 +57,8 @@ void VMAC_Base::UncheckedSetKey(const byte *userKey, unsigned int keylength, con /* Fill nh key */ in[0] = 0x80; - for (i = 0; i < m_nhKeySize()*sizeof(word64); i += blockSize) - { - cipher.ProcessBlock(in, out.BytePtr()); - ConditionalByteReverse(BIG_ENDIAN_ORDER, m_nhKey()+i/sizeof(word64), out.begin(), blockSize); - in[15]++; - } + cipher.AdvancedProcessBlocks(in, NULL, (byte *)m_nhKey(), m_nhKeySize()*sizeof(word64), cipher.BT_InBlockIsCounter); + ConditionalByteReverse<word64>(BIG_ENDIAN_ORDER, m_nhKey(), m_nhKey(), m_nhKeySize()*sizeof(word64)); /* Fill poly key */ in[0] = 0xC0; @@ -137,6 +133,7 @@ void VMAC_Base::Resynchronize(const byte *nonce, int len) void VMAC_Base::HashEndianCorrectedBlock(const word64 *data) { assert(false); + throw 0; } #if CRYPTOPP_BOOL_SSE2_ASM_AVAILABLE && CRYPTOPP_BOOL_X86 |