fprintf(stdout,"Testing SHA-256 ");
- SHA256("abc",3,md);
+ SHA256((unsigned char *)"abc",3,md);
if (memcmp(md,app_b1,sizeof(app_b1)))
{ fflush(stdout);
fprintf(stderr,"\nTEST 1 of 3 failed.\n");
else
fprintf(stdout,"."); fflush(stdout);
- SHA256("abcdbcde""cdefdefg""efghfghi""ghijhijk"
+ SHA256((unsigned char *)"abcdbcde""cdefdefg""efghfghi""ghijhijk"
"ijkljklm""klmnlmno""mnopnopq",56,md);
if (memcmp(md,app_b2,sizeof(app_b2)))
{ fflush(stdout);
fprintf(stdout,"Testing SHA-224 ");
- SHA224("abc",3,md);
+ SHA224((unsigned char *)"abc",3,md);
if (memcmp(md,addenum_1,sizeof(addenum_1)))
{ fflush(stdout);
fprintf(stderr,"\nTEST 1 of 3 failed.\n");
else
fprintf(stdout,"."); fflush(stdout);
- SHA224("abcdbcde""cdefdefg""efghfghi""ghijhijk"
+ SHA224((unsigned char *)"abcdbcde""cdefdefg""efghfghi""ghijhijk"
"ijkljklm""klmnlmno""mnopnopq",56,md);
if (memcmp(md,addenum_2,sizeof(addenum_2)))
{ fflush(stdout);
fprintf(stdout,"Testing SHA-512 ");
- SHA512("abc",3,md);
+ SHA512((unsigned char *)"abc",3,md);
if (memcmp(md,app_c1,sizeof(app_c1)))
{ fflush(stdout);
fprintf(stderr,"\nTEST 1 of 3 failed.\n");
else
fprintf(stdout,"."); fflush(stdout);
- SHA512("abcdefgh""bcdefghi""cdefghij""defghijk"
+ SHA512((unsigned char *)"abcdefgh""bcdefghi""cdefghij""defghijk"
"efghijkl""fghijklm""ghijklmn""hijklmno"
"ijklmnop""jklmnopq""klmnopqr""lmnopqrs"
"mnopqrst""nopqrstu",112,md);
fprintf(stdout,"Testing SHA-384 ");
- SHA384("abc",3,md);
+ SHA384((unsigned char *)"abc",3,md);
if (memcmp(md,app_d1,sizeof(app_d1)))
{ fflush(stdout);
fprintf(stderr,"\nTEST 1 of 3 failed.\n");
else
fprintf(stdout,"."); fflush(stdout);
- SHA384("abcdefgh""bcdefghi""cdefghij""defghijk"
+ SHA384((unsigned char *)"abcdefgh""bcdefghi""cdefghij""defghijk"
"efghijkl""fghijklm""ghijklmn""hijklmno"
"ijklmnop""jklmnopq""klmnopqr""lmnopqrs"
"mnopqrst""nopqrstu",112,md);