> Can you please send me the test code you're using?
void IVMac::TestVMac( int _num, vector<uint64> *_res )
{
const char key[16] = "somedummykey345";
const byte pattern[100] = {
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9 };
if ( sizeof(pattern) < _num )
_num = sizeof(pattern);
const uint64 nonce[2] = { 0x10, 0x0 };
CryptoPP::VMAC<CryptoPP::AES, 64> hasher;
hasher.SetKey( (byte*)key, 16, CryptoPP::MakeParameters
( CryptoPP::Name::IV(), (const byte*)&nonce, false )
( CryptoPP::Name::KeySize(), 128 ) );
_res->clear();
for ( size_t i = 1, e = _num; i != e; ++ i )
{
uint64 cv;
hasher.Resynchronize( (const byte*)nonce );
hasher.CalculateDigest( (byte*)&cv, pattern, i );
_res->push_back( cv );
}
}
Part of output for win32-asm version (same for solaris-x32-asm build)
001: 1a389ca500d4eaf0
002: e149caa17fe0b40a
...
060: 1dfc4e591d2eedfe
061: 1ba45cc0c3ed0829
062: c996642079603e2b
063: 9d44fabe3aee558f
064: 46e4869622115be9
065: 7517e94a7ae02859
066: ce5f7ae6bdbbe8b9
067: c78eafeb12f60ac6
068: 29bb6477ff69dd56
069: 45b48cffc229c764
...
098: 700d75c652ef4712
099: 51e6c6f7a2e117ce
Same part for win32-noasm version (same for solaris-x64-asm and
solaris-x32-noasm)
001: 1a389ca500d4eaf0
002: e149caa17fe0b40a
...
060: 1dfc4e591d2eedfe
061: 1ba45cc0c3ed0829
062: c996642079603e2b
063: 9d44fabe3aee558f
064: 46e4869622115be9
065: 27e30b88034cbfa
066: 897f00d2d199c0ac
067: 5bf580ff41fca8d4
068: c94d16b7f98ae18c
069: ff397910e46c009f
...
098: acaf5798f9c12eeb
099: c55dec74a12110ae
btw, I were wrong, problem starts from 65 bytes msg length.
> BTW, if you run "cryptest.exe v" it will test VMAC with messages of up to
> 512 bytes. Does that pass for you?
As I see in "TestVectors/vmac.txt" only short (less then 10 bytes
length) messages used. And yes - cryptest v passed.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users"
Google Group.
To unsubscribe, send an email to [email protected].
More information about Crypto++ and this group is available at
http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---