diff --git a/test/auth.c b/test/auth.c index 34fade68..93518512 100644 --- a/test/auth.c +++ b/test/auth.c @@ -1,6 +1,9 @@ #include #include "crypto_auth_hmacsha512256.h" +#define TEST_NAME "auth" +#include "cmptest.h" + /* "Test Case 2" from RFC 4231 */ unsigned char key[32] = "Jefe"; unsigned char c[28] = "what do ya want for nothing?"; diff --git a/test/auth2.c b/test/auth2.c index 0433a51e..89f034ca 100644 --- a/test/auth2.c +++ b/test/auth2.c @@ -3,6 +3,9 @@ #include #include "crypto_auth_hmacsha256.h" +#define TEST_NAME "auth2" +#include "cmptest.h" + unsigned char key[32] = { 0x01,0x02,0x03,0x04,0x05,0x06,0x07,0x08 ,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,0x10 diff --git a/test/auth3.c b/test/auth3.c index fcc6e0ea..b19b27fc 100644 --- a/test/auth3.c +++ b/test/auth3.c @@ -3,6 +3,9 @@ #include #include "crypto_auth_hmacsha256.h" +#define TEST_NAME "auth3" +#include "cmptest.h" + unsigned char key[32] = { 0x01,0x02,0x03,0x04,0x05,0x06,0x07,0x08 ,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,0x10 diff --git a/test/auth5.c b/test/auth5.c index ae266e1f..1c2b2f2b 100644 --- a/test/auth5.c +++ b/test/auth5.c @@ -4,6 +4,9 @@ #include "randombytes.h" #include "windows/windows-quirks.h" +#define TEST_NAME "auth5" +#include "cmptest.h" + unsigned char key[32]; unsigned char c[10000]; unsigned char a[32]; diff --git a/test/box.c b/test/box.c index ab204ca7..ded5e954 100644 --- a/test/box.c +++ b/test/box.c @@ -1,6 +1,9 @@ #include #include "crypto_box_curve25519xsalsa20poly1305.h" +#define TEST_NAME "box" +#include "cmptest.h" + unsigned char alicesk[32] = { 0x77,0x07,0x6d,0x0a,0x73,0x18,0xa5,0x7d ,0x3c,0x16,0xc1,0x72,0x51,0xb2,0x66,0x45 diff --git a/test/box2.c b/test/box2.c index bfafcc12..193b9b58 100644 --- a/test/box2.c +++ b/test/box2.c @@ -1,6 +1,9 @@ #include #include "crypto_box_curve25519xsalsa20poly1305.h" +#define TEST_NAME "box2" +#include "cmptest.h" + unsigned char bobsk[32] = { 0x5d,0xab,0x08,0x7e,0x62,0x4a,0x8a,0x4b ,0x79,0xe1,0x7f,0x8b,0x83,0x80,0x0e,0xe6 diff --git a/test/box7.c b/test/box7.c index ab67ee4c..a4fb7ce6 100644 --- a/test/box7.c +++ b/test/box7.c @@ -2,6 +2,9 @@ #include "crypto_box.h" #include "randombytes.h" +#define TEST_NAME "box7" +#include "cmptest.h" + unsigned char alicesk[crypto_box_SECRETKEYBYTES]; unsigned char alicepk[crypto_box_PUBLICKEYBYTES]; unsigned char bobsk[crypto_box_SECRETKEYBYTES]; diff --git a/test/box8.c b/test/box8.c index 574b2b67..bade157f 100644 --- a/test/box8.c +++ b/test/box8.c @@ -4,6 +4,9 @@ #include "randombytes.h" #include "windows/windows-quirks.h" +#define TEST_NAME "box8" +#include "cmptest.h" + unsigned char alicesk[crypto_box_SECRETKEYBYTES]; unsigned char alicepk[crypto_box_PUBLICKEYBYTES]; unsigned char bobsk[crypto_box_SECRETKEYBYTES]; diff --git a/test/core1.c b/test/core1.c index 41dcab83..5e6aa82e 100644 --- a/test/core1.c +++ b/test/core1.c @@ -1,6 +1,9 @@ #include #include "crypto_core_hsalsa20.h" +#define TEST_NAME "core1" +#include "cmptest.h" + unsigned char shared[32] = { 0x4a,0x5d,0x9d,0x5b,0xa4,0xce,0x2d,0xe1 ,0x72,0x8e,0x3b,0xf4,0x80,0x35,0x0f,0x25 diff --git a/test/core2.c b/test/core2.c index cb3387dd..20010cff 100644 --- a/test/core2.c +++ b/test/core2.c @@ -1,6 +1,9 @@ #include #include "crypto_core_hsalsa20.h" +#define TEST_NAME "core2" +#include "cmptest.h" + unsigned char firstkey[32] = { 0x1b,0x27,0x55,0x64,0x73,0xe9,0x85,0xd4 ,0x62,0xcd,0x51,0x19,0x7a,0x9a,0x46,0xc7 diff --git a/test/core3.c b/test/core3.c index 4585ce4b..ca9fc7c3 100644 --- a/test/core3.c +++ b/test/core3.c @@ -2,6 +2,9 @@ #include "crypto_core_salsa20.h" #include "crypto_hash_sha256.h" +#define TEST_NAME "core3" +#include "cmptest.h" + unsigned char secondkey[32] = { 0xdc,0x90,0x8d,0xda,0x0b,0x93,0x44,0xa9 ,0x53,0x62,0x9b,0x73,0x38,0x20,0x77,0x88 diff --git a/test/core4.c b/test/core4.c index 08489778..6d168610 100644 --- a/test/core4.c +++ b/test/core4.c @@ -1,6 +1,9 @@ #include #include "crypto_core_salsa20.h" +#define TEST_NAME "core4" +#include "cmptest.h" + unsigned char k[32] = { 1, 2, 3, 4, 5, 6, 7, 8 , 9, 10, 11, 12, 13, 14, 15, 16 diff --git a/test/core5.c b/test/core5.c index 425d9ef8..d1dc331a 100644 --- a/test/core5.c +++ b/test/core5.c @@ -1,6 +1,9 @@ #include #include "crypto_core_hsalsa20.h" +#define TEST_NAME "core5" +#include "cmptest.h" + unsigned char k[32] = { 0xee,0x30,0x4f,0xca,0x27,0x00,0x8d,0x8c ,0x12,0x6f,0x90,0x02,0x79,0x01,0xd8,0x0f diff --git a/test/core6.c b/test/core6.c index 52f294e9..1e2962a5 100644 --- a/test/core6.c +++ b/test/core6.c @@ -1,6 +1,9 @@ #include #include "crypto_core_salsa20.h" +#define TEST_NAME "core6" +#include "cmptest.h" + unsigned char k[32] = { 0xee,0x30,0x4f,0xca,0x27,0x00,0x8d,0x8c ,0x12,0x6f,0x90,0x02,0x79,0x01,0xd8,0x0f diff --git a/test/hash.c b/test/hash.c index e477aec4..1b7b8df7 100644 --- a/test/hash.c +++ b/test/hash.c @@ -1,6 +1,9 @@ #include #include "crypto_hash.h" +#define TEST_NAME "hash" +#include "cmptest.h" + unsigned char x[8] = "testing\n"; unsigned char h[crypto_hash_BYTES]; diff --git a/test/hash3.c b/test/hash3.c index 2bc5beae..c0f66738 100644 --- a/test/hash3.c +++ b/test/hash3.c @@ -1,6 +1,9 @@ #include #include "crypto_hash_sha512.h" +#define TEST_NAME "hash3" +#include "cmptest.h" + unsigned char x[8] = "testing\n"; unsigned char h[crypto_hash_sha512_BYTES]; diff --git a/test/onetimeauth.c b/test/onetimeauth.c index 5d755bdf..29af33bf 100644 --- a/test/onetimeauth.c +++ b/test/onetimeauth.c @@ -1,6 +1,9 @@ #include #include "crypto_onetimeauth_poly1305.h" +#define TEST_NAME "onetimeauth" +#include "cmptest.h" + unsigned char rs[32] = { 0xee,0xa6,0xa7,0x25,0x1c,0x1e,0x72,0x91 ,0x6d,0x11,0xc2,0xcb,0x21,0x4d,0x3c,0x25 diff --git a/test/onetimeauth2.c b/test/onetimeauth2.c index 523ab13f..fbc1cff5 100644 --- a/test/onetimeauth2.c +++ b/test/onetimeauth2.c @@ -1,6 +1,9 @@ #include #include "crypto_onetimeauth_poly1305.h" +#define TEST_NAME "onetimeauth2" +#include "cmptest.h" + unsigned char rs[32] = { 0xee,0xa6,0xa7,0x25,0x1c,0x1e,0x72,0x91 ,0x6d,0x11,0xc2,0xcb,0x21,0x4d,0x3c,0x25 diff --git a/test/onetimeauth7.c b/test/onetimeauth7.c index 859b0380..8028eb09 100644 --- a/test/onetimeauth7.c +++ b/test/onetimeauth7.c @@ -4,6 +4,9 @@ #include "randombytes.h" #include "windows/windows-quirks.h" +#define TEST_NAME "onetimeauth7" +#include "cmptest.h" + unsigned char key[32]; unsigned char c[10000]; unsigned char a[16]; diff --git a/test/scalarmult.c b/test/scalarmult.c index 961f2fc1..ca1921d4 100644 --- a/test/scalarmult.c +++ b/test/scalarmult.c @@ -1,6 +1,9 @@ #include #include "crypto_scalarmult_curve25519.h" +#define TEST_NAME "scalarmult" +#include "cmptest.h" + unsigned char alicesk[32] = { 0x77,0x07,0x6d,0x0a,0x73,0x18,0xa5,0x7d ,0x3c,0x16,0xc1,0x72,0x51,0xb2,0x66,0x45 diff --git a/test/scalarmult2.c b/test/scalarmult2.c index addef3ee..45e2ab04 100644 --- a/test/scalarmult2.c +++ b/test/scalarmult2.c @@ -1,6 +1,9 @@ #include #include "crypto_scalarmult_curve25519.h" +#define TEST_NAME "scalarmult2" +#include "cmptest.h" + unsigned char bobsk[32] = { 0x5d,0xab,0x08,0x7e,0x62,0x4a,0x8a,0x4b ,0x79,0xe1,0x7f,0x8b,0x83,0x80,0x0e,0xe6 diff --git a/test/scalarmult5.c b/test/scalarmult5.c index 4433f669..21170ee1 100644 --- a/test/scalarmult5.c +++ b/test/scalarmult5.c @@ -1,6 +1,9 @@ #include #include "crypto_scalarmult_curve25519.h" +#define TEST_NAME "scalarmult5" +#include "cmptest.h" + unsigned char alicesk[32] = { 0x77,0x07,0x6d,0x0a,0x73,0x18,0xa5,0x7d ,0x3c,0x16,0xc1,0x72,0x51,0xb2,0x66,0x45 diff --git a/test/scalarmult6.c b/test/scalarmult6.c index 8500569e..51a05de4 100644 --- a/test/scalarmult6.c +++ b/test/scalarmult6.c @@ -1,6 +1,9 @@ #include #include "crypto_scalarmult_curve25519.h" +#define TEST_NAME "scalarmult6" +#include "cmptest.h" + unsigned char bobsk[32] = { 0x5d,0xab,0x08,0x7e,0x62,0x4a,0x8a,0x4b ,0x79,0xe1,0x7f,0x8b,0x83,0x80,0x0e,0xe6 diff --git a/test/secretbox.c b/test/secretbox.c index db1d0a52..29e2a28b 100644 --- a/test/secretbox.c +++ b/test/secretbox.c @@ -1,6 +1,9 @@ #include #include "crypto_secretbox_xsalsa20poly1305.h" +#define TEST_NAME "secretbox" +#include "cmptest.h" + unsigned char firstkey[32] = { 0x1b,0x27,0x55,0x64,0x73,0xe9,0x85,0xd4 ,0x62,0xcd,0x51,0x19,0x7a,0x9a,0x46,0xc7 diff --git a/test/secretbox2.c b/test/secretbox2.c index ae89ba9c..4676f280 100644 --- a/test/secretbox2.c +++ b/test/secretbox2.c @@ -1,6 +1,9 @@ #include #include "crypto_secretbox_xsalsa20poly1305.h" +#define TEST_NAME "secretbox2" +#include "cmptest.h" + unsigned char firstkey[32] = { 0x1b,0x27,0x55,0x64,0x73,0xe9,0x85,0xd4 ,0x62,0xcd,0x51,0x19,0x7a,0x9a,0x46,0xc7 diff --git a/test/secretbox7.c b/test/secretbox7.c index 45c9c68e..5731fb78 100644 --- a/test/secretbox7.c +++ b/test/secretbox7.c @@ -2,6 +2,9 @@ #include "crypto_secretbox.h" #include "randombytes.h" +#define TEST_NAME "secretbox7" +#include "cmptest.h" + unsigned char k[crypto_secretbox_KEYBYTES]; unsigned char n[crypto_secretbox_NONCEBYTES]; unsigned char m[10000]; diff --git a/test/secretbox8.c b/test/secretbox8.c index 9562c7c6..685d6870 100644 --- a/test/secretbox8.c +++ b/test/secretbox8.c @@ -4,6 +4,9 @@ #include "randombytes.h" #include "windows/windows-quirks.h" +#define TEST_NAME "secretbox8" +#include "cmptest.h" + unsigned char k[crypto_secretbox_KEYBYTES]; unsigned char n[crypto_secretbox_NONCEBYTES]; unsigned char m[10000]; diff --git a/test/stream.c b/test/stream.c index 9fbe1db3..5cf5d578 100644 --- a/test/stream.c +++ b/test/stream.c @@ -2,6 +2,9 @@ #include "crypto_stream_xsalsa20.h" #include "crypto_hash_sha256.h" +#define TEST_NAME "stream" +#include "cmptest.h" + unsigned char firstkey[32] = { 0x1b,0x27,0x55,0x64,0x73,0xe9,0x85,0xd4 ,0x62,0xcd,0x51,0x19,0x7a,0x9a,0x46,0xc7 diff --git a/test/stream2.c b/test/stream2.c index 945360e8..99f2327e 100644 --- a/test/stream2.c +++ b/test/stream2.c @@ -2,6 +2,9 @@ #include "crypto_stream_salsa20.h" #include "crypto_hash_sha256.h" +#define TEST_NAME "stream2" +#include "cmptest.h" + unsigned char secondkey[32] = { 0xdc,0x90,0x8d,0xda,0x0b,0x93,0x44,0xa9 ,0x53,0x62,0x9b,0x73,0x38,0x20,0x77,0x88 diff --git a/test/stream3.c b/test/stream3.c index 887caf01..b966c346 100644 --- a/test/stream3.c +++ b/test/stream3.c @@ -1,6 +1,9 @@ #include #include "crypto_stream_xsalsa20.h" +#define TEST_NAME "stream3" +#include "cmptest.h" + unsigned char firstkey[32] = { 0x1b,0x27,0x55,0x64,0x73,0xe9,0x85,0xd4 ,0x62,0xcd,0x51,0x19,0x7a,0x9a,0x46,0xc7 diff --git a/test/stream4.c b/test/stream4.c index f2771dd6..33bdc426 100644 --- a/test/stream4.c +++ b/test/stream4.c @@ -1,6 +1,9 @@ #include #include "crypto_stream_xsalsa20.h" +#define TEST_NAME "stream4" +#include "cmptest.h" + unsigned char firstkey[32] = { 0x1b,0x27,0x55,0x64,0x73,0xe9,0x85,0xd4 ,0x62,0xcd,0x51,0x19,0x7a,0x9a,0x46,0xc7