libpurple/tests/test_jabber_scram.c

Mon, 12 Aug 2013 00:26:10 +0530

author
Ankit Vani <a@nevitus.org>
date
Mon, 12 Aug 2013 00:26:10 +0530
branch
soc.2013.gobjectification.plugins
changeset 36519
8afeafb200c1
parent 34567
ea5103f66b0e
permissions
-rw-r--r--

Cancel pending dialogs and disconnect signals when removing a protocol

28863
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
1 #include <string.h>
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
2
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
3 #include "tests.h"
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
4 #include "../util.h"
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
5 #include "../protocols/jabber/auth_scram.h"
29083
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
6 #include "../protocols/jabber/jutil.h"
34567
ea5103f66b0e Refactor the codebase to use PurpleHash
Ankit Vani <a@nevitus.org>
parents: 34564
diff changeset
7 #include "../ciphers/sha1hash.h"
28863
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
8
34567
ea5103f66b0e Refactor the codebase to use PurpleHash
Ankit Vani <a@nevitus.org>
parents: 34564
diff changeset
9 static JabberScramHash sha1_mech = { "-SHA-1", purple_sha1_hash_new, 20 };
29081
ce668db953aa jabber: Clean up the SCRAM code a little.
Paul Aurich <darkrain42@pidgin.im>
parents: 29027
diff changeset
10
28863
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
11 #define assert_pbkdf2_equal(password, salt, count, expected) { \
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
12 GString *p = g_string_new(password); \
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
13 GString *s = g_string_new(salt); \
29081
ce668db953aa jabber: Clean up the SCRAM code a little.
Paul Aurich <darkrain42@pidgin.im>
parents: 29027
diff changeset
14 guchar *result = jabber_scram_hi(&sha1_mech, p, s, count); \
28863
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
15 fail_if(result == NULL, "Hi() returned NULL"); \
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
16 fail_if(0 != memcmp(result, expected, 20), "Hi() returned invalid result"); \
28863
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
17 g_string_free(s, TRUE); \
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
18 g_string_free(p, TRUE); \
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
19 }
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
20
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
21 START_TEST(test_pbkdf2)
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
22 {
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
23 assert_pbkdf2_equal("password", "salt", 1, "\x0c\x60\xc8\x0f\x96\x1f\x0e\x71\xf3\xa9\xb5\x24\xaf\x60\x12\x06\x2f\xe0\x37\xa6");
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
24 assert_pbkdf2_equal("password", "salt", 2, "\xea\x6c\x01\x4d\xc7\x2d\x6f\x8c\xcd\x1e\xd9\x2a\xce\x1d\x41\xf0\xd8\xde\x89\x57");
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
25 assert_pbkdf2_equal("password", "salt", 4096, "\x4b\x00\x79\x01\xb7\x65\x48\x9a\xbe\xad\x49\xd9\x26\xf7\x21\xd0\x65\xa4\x29\xc1");
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
26
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
27 #if 0
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
28 /* This causes libcheck to time out :-D */
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
29 assert_pbkdf2_equal("password", "salt", 16777216, "\xee\xfe\x3d\x61\xcd\x4d\xa4\xe4\xe9\x94\x5b\x3d\x6b\xa2\x15\x8c\x26\x34\xe9\x84");
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
30 #endif
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
31 }
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
32 END_TEST
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
33
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
34 START_TEST(test_proofs)
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
35 {
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
36 JabberScramData *data = g_new0(JabberScramData, 1);
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
37 gboolean ret;
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
38 GString *salt;
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
39 const char *client_proof;
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
40 /* const char *server_signature; */
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
41
29081
ce668db953aa jabber: Clean up the SCRAM code a little.
Paul Aurich <darkrain42@pidgin.im>
parents: 29027
diff changeset
42 data->hash = &sha1_mech;
29027
6af29b140195 jabber: Add SASLprep and the username substitution called for in draft-ietf-sasl-scram-10 5.1.
Paul Aurich <darkrain42@pidgin.im>
parents: 28926
diff changeset
43 data->password = g_strdup("password");
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
44 data->auth_message = g_string_new("n=username@jabber.org,r=8jLxB5515dhFxBil5A0xSXMH,"
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
45 "r=8jLxB5515dhFxBil5A0xSXMHabc,s=c2FsdA==,i=1,"
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
46 "c=biws,r=8jLxB5515dhFxBil5A0xSXMHabc");
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
47 client_proof = "\x48\x61\x30\xa5\x61\x0b\xae\xb9\xe4\x11\xa8\xfd\xa5\xcd\x34\x1d\x8a\x3c\x28\x17";
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
48
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
49 salt = g_string_new("salt");
28868
7415cb6c4587 jabber: Handle the case where the server success-with-data is sent as a challenge/response pair.
Paul Aurich <darkrain42@pidgin.im>
parents: 28866
diff changeset
50 ret = jabber_scram_calc_proofs(data, salt, 1);
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
51 fail_if(ret == FALSE, "Failed to calculate SCRAM proofs!");
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
52
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
53 fail_unless(0 == memcmp(client_proof, data->client_proof->str, 20));
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
54 g_string_free(salt, TRUE);
29027
6af29b140195 jabber: Add SASLprep and the username substitution called for in draft-ietf-sasl-scram-10 5.1.
Paul Aurich <darkrain42@pidgin.im>
parents: 28926
diff changeset
55
6af29b140195 jabber: Add SASLprep and the username substitution called for in draft-ietf-sasl-scram-10 5.1.
Paul Aurich <darkrain42@pidgin.im>
parents: 28926
diff changeset
56 jabber_scram_data_destroy(data);
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
57 }
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
58 END_TEST
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
59
29083
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
60 #define assert_successful_exchange(pw, nonce, start_data, challenge1, response1, success) { \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
61 JabberScramData *data = g_new0(JabberScramData, 1); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
62 gboolean ret; \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
63 gchar *out; \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
64 \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
65 data->step = 1; \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
66 data->hash = &sha1_mech; \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
67 data->password = jabber_saslprep(pw); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
68 fail_if(data->password == NULL); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
69 data->cnonce = g_strdup(nonce); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
70 data->auth_message = g_string_new(start_data); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
71 \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
72 ret = jabber_scram_feed_parser(data, challenge1, &out); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
73 fail_unless(ret == TRUE); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
74 fail_unless(g_str_equal(out, response1), "Got unexpected response to challenge. Expected %s, got %s", response1, out); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
75 g_free(out); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
76 \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
77 data->step = 2; \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
78 ret = jabber_scram_feed_parser(data, success, &out); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
79 fail_unless(ret == TRUE); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
80 fail_unless(out == NULL); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
81 \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
82 jabber_scram_data_destroy(data); \
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
83 }
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
84
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
85 START_TEST(test_mech)
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
86 {
29083
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
87 assert_successful_exchange("password", "H7yDYKAWBCrM2Fa5SxGa4iez",
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
88 "n=paul,r=H7yDYKAWBCrM2Fa5SxGa4iez",
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
89 "r=H7yDYKAWBCrM2Fa5SxGa4iezFPVDPpDUcGxPkH3RzP,s=3rXeErP/os7jUNqU,i=4096",
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
90 "c=biws,r=H7yDYKAWBCrM2Fa5SxGa4iezFPVDPpDUcGxPkH3RzP,p=pXkak78EuwwOEwk2/h/OzD7NkEI=",
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
91 "v=ldX4EBNnOgDnNTOCmbSfBHAUCOs=");
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
92
30455
8fa81888c974 jabber: Exclude ASCII 127 (Delete) from allowed SASLprep characters
Paul Aurich <darkrain42@pidgin.im>
parents: 29083
diff changeset
93 #ifdef USE_IDN
29083
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
94 assert_successful_exchange("pass½word", "GNb2HsNI7VnTv8ABsE5AnY8W",
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
95 "n=paul,r=GNb2HsNI7VnTv8ABsE5AnY8W",
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
96 "r=GNb2HsNI7VnTv8ABsE5AnY8W/w/I3eRKM0I7jxFWOH,s=ysAriUjPzFqOXnMQ,i=4096",
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
97 "c=biws,r=GNb2HsNI7VnTv8ABsE5AnY8W/w/I3eRKM0I7jxFWOH,p=n/CtgdWjOYnLQ4m9Na+wPn9D2uY=",
cc7d90ec7a52 Add a second SCRAM test with one of the suggested test characters from the I-D.
Paul Aurich <darkrain42@pidgin.im>
parents: 29081
diff changeset
98 "v=4TkZwKWy6JHNmrUbU2+IdAaXtos=");
30455
8fa81888c974 jabber: Exclude ASCII 127 (Delete) from allowed SASLprep characters
Paul Aurich <darkrain42@pidgin.im>
parents: 29083
diff changeset
99 #endif
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
100 }
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
101 END_TEST
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
102
28863
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
103 Suite *
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
104 jabber_scram_suite(void)
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
105 {
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
106 Suite *s = suite_create("Jabber SASL SCRAM functions");
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
107
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
108 TCase *tc = tcase_create("PBKDF2 Functionality");
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
109 tcase_add_test(tc, test_pbkdf2);
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
110 suite_add_tcase(s, tc);
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
111
28866
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
112 tc = tcase_create("SCRAM Proofs");
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
113 tcase_add_test(tc, test_proofs);
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
114 suite_add_tcase(s, tc);
e3d867ce000b jabber: Complete (though untested) SCRAM implementation.
Paul Aurich <darkrain42@pidgin.im>
parents: 28863
diff changeset
115
28926
a737800d1445 jabber: Fix up the remaining issues and add a test case that interoperates with gsasl. Woot.
Paul Aurich <darkrain42@pidgin.im>
parents: 28868
diff changeset
116 tc = tcase_create("SCRAM exchange");
a737800d1445 jabber: Fix up the remaining issues and add a test case that interoperates with gsasl. Woot.
Paul Aurich <darkrain42@pidgin.im>
parents: 28868
diff changeset
117 tcase_add_test(tc, test_mech);
a737800d1445 jabber: Fix up the remaining issues and add a test case that interoperates with gsasl. Woot.
Paul Aurich <darkrain42@pidgin.im>
parents: 28868
diff changeset
118 suite_add_tcase(s, tc);
28863
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
119 return s;
b4e8c372e06b Fix the Hi() function and actually 'mtn add' the test file.
Paul Aurich <darkrain42@pidgin.im>
parents:
diff changeset
120 }

mercurial