On Thu, 26 Mar 1998, George Chung wrote:
> Does anyone have some test vectors for the SSL MAC algorithms? Both MD5 and
> SHA?
>
> By test vectors, I mean a series of input paired with the expected MAC.
My current MD5-HMAC test vectors (quite a few taken from the relevent RFC I
think)
struct test_st
{
unsigned char key[16];
int key_len;
unsigned char data[64];
int data_len;
unsigned char *digest;
} test[4]={
{ "",
0,
"More text test vectors to stuff up EBCDIC machines :-)",
54,
"e9139d1e6ee064ef8cf514fc7dc83e86",
},{ {0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,
0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,0x0b,},
16,
"Hi There",
8,
"9294727a3638bb1c13f48ef8158bfc9d",
},{ "Jefe",
"what do ya want for nothing?",
28,
"750c783e6ab0b503eaa86e310a5db738",
},{
{0xaa,0xaa,0xaa,0xaa,0xaa,0xaa,0xaa,0xaa,
0xaa,0xaa,0xaa,0xaa,0xaa,0xaa,0xaa,0xaa,},
16,
{0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,
0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,
0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,
0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,
0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,
0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,
0xdd,0xdd},
50,
"56be34521d144c88dbb8c733f0e8b3f6",
},
};
+-------------------------------------------------------------------------+
| Administrative requests should be sent to [EMAIL PROTECTED] |
| List service provided by Open Software Associates, http://www.osa.com/ |
+-------------------------------------------------------------------------+