]> git.ipfire.org Git - thirdparty/openssl.git/blame - ssl/tls_srp.c
In apps, malloc or die
[thirdparty/openssl.git] / ssl / tls_srp.c
CommitLineData
edc032b5 1/* ssl/tls_srp.c */
0f113f3e
MC
2/*
3 * Written by Christophe Renou (christophe.renou@edelweb.fr) with the
4 * precious help of Peter Sylvester (peter.sylvester@edelweb.fr) for the
5 * EdelKey project and contributed to the OpenSSL project 2004.
edc032b5
BL
6 */
7/* ====================================================================
f2fc3075 8 * Copyright (c) 2004-2011 The OpenSSL Project. All rights reserved.
edc032b5
BL
9 *
10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions
12 * are met:
13 *
14 * 1. Redistributions of source code must retain the above copyright
0f113f3e 15 * notice, this list of conditions and the following disclaimer.
edc032b5
BL
16 *
17 * 2. Redistributions in binary form must reproduce the above copyright
18 * notice, this list of conditions and the following disclaimer in
19 * the documentation and/or other materials provided with the
20 * distribution.
21 *
22 * 3. All advertising materials mentioning features or use of this
23 * software must display the following acknowledgment:
24 * "This product includes software developed by the OpenSSL Project
25 * for use in the OpenSSL Toolkit. (http://www.OpenSSL.org/)"
26 *
27 * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
28 * endorse or promote products derived from this software without
29 * prior written permission. For written permission, please contact
30 * licensing@OpenSSL.org.
31 *
32 * 5. Products derived from this software may not be called "OpenSSL"
33 * nor may "OpenSSL" appear in their names without prior written
34 * permission of the OpenSSL Project.
35 *
36 * 6. Redistributions of any form whatsoever must retain the following
37 * acknowledgment:
38 * "This product includes software developed by the OpenSSL Project
39 * for use in the OpenSSL Toolkit (http://www.OpenSSL.org/)"
40 *
41 * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
42 * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
43 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
44 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR
45 * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
46 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
47 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
48 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
49 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
50 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
51 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
52 * OF THE POSSIBILITY OF SUCH DAMAGE.
53 * ====================================================================
54 *
55 * This product includes cryptographic software written by Eric Young
56 * (eay@cryptsoft.com). This product includes software written by Tim
57 * Hudson (tjh@cryptsoft.com).
58 *
59 */
edc032b5 60
b93e331b 61#include <openssl/crypto.h>
edc032b5
BL
62#include <openssl/rand.h>
63#include <openssl/srp.h>
64#include <openssl/err.h>
b93e331b
DSH
65#include "ssl_locl.h"
66
67#ifndef OPENSSL_NO_SRP
edc032b5
BL
68
69int SSL_CTX_SRP_CTX_free(struct ssl_ctx_st *ctx)
0f113f3e
MC
70{
71 if (ctx == NULL)
72 return 0;
73 OPENSSL_free(ctx->srp_ctx.login);
74 BN_free(ctx->srp_ctx.N);
75 BN_free(ctx->srp_ctx.g);
76 BN_free(ctx->srp_ctx.s);
77 BN_free(ctx->srp_ctx.B);
78 BN_free(ctx->srp_ctx.A);
79 BN_free(ctx->srp_ctx.a);
80 BN_free(ctx->srp_ctx.b);
81 BN_free(ctx->srp_ctx.v);
82 ctx->srp_ctx.TLS_ext_srp_username_callback = NULL;
83 ctx->srp_ctx.SRP_cb_arg = NULL;
84 ctx->srp_ctx.SRP_verify_param_callback = NULL;
85 ctx->srp_ctx.SRP_give_srp_client_pwd_callback = NULL;
86 ctx->srp_ctx.N = NULL;
87 ctx->srp_ctx.g = NULL;
88 ctx->srp_ctx.s = NULL;
89 ctx->srp_ctx.B = NULL;
90 ctx->srp_ctx.A = NULL;
91 ctx->srp_ctx.a = NULL;
92 ctx->srp_ctx.b = NULL;
93 ctx->srp_ctx.v = NULL;
94 ctx->srp_ctx.login = NULL;
95 ctx->srp_ctx.info = NULL;
96 ctx->srp_ctx.strength = SRP_MINIMAL_N;
97 ctx->srp_ctx.srp_Mask = 0;
98 return (1);
99}
edc032b5
BL
100
101int SSL_SRP_CTX_free(struct ssl_st *s)
0f113f3e
MC
102{
103 if (s == NULL)
104 return 0;
105 OPENSSL_free(s->srp_ctx.login);
106 BN_free(s->srp_ctx.N);
107 BN_free(s->srp_ctx.g);
108 BN_free(s->srp_ctx.s);
109 BN_free(s->srp_ctx.B);
110 BN_free(s->srp_ctx.A);
111 BN_free(s->srp_ctx.a);
112 BN_free(s->srp_ctx.b);
113 BN_free(s->srp_ctx.v);
114 s->srp_ctx.TLS_ext_srp_username_callback = NULL;
115 s->srp_ctx.SRP_cb_arg = NULL;
116 s->srp_ctx.SRP_verify_param_callback = NULL;
117 s->srp_ctx.SRP_give_srp_client_pwd_callback = NULL;
118 s->srp_ctx.N = NULL;
119 s->srp_ctx.g = NULL;
120 s->srp_ctx.s = NULL;
121 s->srp_ctx.B = NULL;
122 s->srp_ctx.A = NULL;
123 s->srp_ctx.a = NULL;
124 s->srp_ctx.b = NULL;
125 s->srp_ctx.v = NULL;
126 s->srp_ctx.login = NULL;
127 s->srp_ctx.info = NULL;
128 s->srp_ctx.strength = SRP_MINIMAL_N;
129 s->srp_ctx.srp_Mask = 0;
130 return (1);
131}
edc032b5
BL
132
133int SSL_SRP_CTX_init(struct ssl_st *s)
0f113f3e
MC
134{
135 SSL_CTX *ctx;
136
137 if ((s == NULL) || ((ctx = s->ctx) == NULL))
138 return 0;
139 s->srp_ctx.SRP_cb_arg = ctx->srp_ctx.SRP_cb_arg;
140 /* set client Hello login callback */
141 s->srp_ctx.TLS_ext_srp_username_callback =
142 ctx->srp_ctx.TLS_ext_srp_username_callback;
143 /* set SRP N/g param callback for verification */
144 s->srp_ctx.SRP_verify_param_callback =
145 ctx->srp_ctx.SRP_verify_param_callback;
146 /* set SRP client passwd callback */
147 s->srp_ctx.SRP_give_srp_client_pwd_callback =
148 ctx->srp_ctx.SRP_give_srp_client_pwd_callback;
149
150 s->srp_ctx.N = NULL;
151 s->srp_ctx.g = NULL;
152 s->srp_ctx.s = NULL;
153 s->srp_ctx.B = NULL;
154 s->srp_ctx.A = NULL;
155 s->srp_ctx.a = NULL;
156 s->srp_ctx.b = NULL;
157 s->srp_ctx.v = NULL;
158 s->srp_ctx.login = NULL;
159 s->srp_ctx.info = ctx->srp_ctx.info;
160 s->srp_ctx.strength = ctx->srp_ctx.strength;
161
162 if (((ctx->srp_ctx.N != NULL) &&
163 ((s->srp_ctx.N = BN_dup(ctx->srp_ctx.N)) == NULL)) ||
164 ((ctx->srp_ctx.g != NULL) &&
165 ((s->srp_ctx.g = BN_dup(ctx->srp_ctx.g)) == NULL)) ||
166 ((ctx->srp_ctx.s != NULL) &&
167 ((s->srp_ctx.s = BN_dup(ctx->srp_ctx.s)) == NULL)) ||
168 ((ctx->srp_ctx.B != NULL) &&
169 ((s->srp_ctx.B = BN_dup(ctx->srp_ctx.B)) == NULL)) ||
170 ((ctx->srp_ctx.A != NULL) &&
171 ((s->srp_ctx.A = BN_dup(ctx->srp_ctx.A)) == NULL)) ||
172 ((ctx->srp_ctx.a != NULL) &&
173 ((s->srp_ctx.a = BN_dup(ctx->srp_ctx.a)) == NULL)) ||
174 ((ctx->srp_ctx.v != NULL) &&
175 ((s->srp_ctx.v = BN_dup(ctx->srp_ctx.v)) == NULL)) ||
176 ((ctx->srp_ctx.b != NULL) &&
177 ((s->srp_ctx.b = BN_dup(ctx->srp_ctx.b)) == NULL))) {
178 SSLerr(SSL_F_SSL_SRP_CTX_INIT, ERR_R_BN_LIB);
179 goto err;
180 }
181 if ((ctx->srp_ctx.login != NULL) &&
182 ((s->srp_ctx.login = BUF_strdup(ctx->srp_ctx.login)) == NULL)) {
183 SSLerr(SSL_F_SSL_SRP_CTX_INIT, ERR_R_INTERNAL_ERROR);
184 goto err;
185 }
186 s->srp_ctx.srp_Mask = ctx->srp_ctx.srp_Mask;
187
188 return (1);
189 err:
190 OPENSSL_free(s->srp_ctx.login);
191 BN_free(s->srp_ctx.N);
192 BN_free(s->srp_ctx.g);
193 BN_free(s->srp_ctx.s);
194 BN_free(s->srp_ctx.B);
195 BN_free(s->srp_ctx.A);
196 BN_free(s->srp_ctx.a);
197 BN_free(s->srp_ctx.b);
198 BN_free(s->srp_ctx.v);
199 return (0);
200}
edc032b5
BL
201
202int SSL_CTX_SRP_CTX_init(struct ssl_ctx_st *ctx)
0f113f3e
MC
203{
204 if (ctx == NULL)
205 return 0;
206
207 ctx->srp_ctx.SRP_cb_arg = NULL;
208 /* set client Hello login callback */
209 ctx->srp_ctx.TLS_ext_srp_username_callback = NULL;
210 /* set SRP N/g param callback for verification */
211 ctx->srp_ctx.SRP_verify_param_callback = NULL;
212 /* set SRP client passwd callback */
213 ctx->srp_ctx.SRP_give_srp_client_pwd_callback = NULL;
214
215 ctx->srp_ctx.N = NULL;
216 ctx->srp_ctx.g = NULL;
217 ctx->srp_ctx.s = NULL;
218 ctx->srp_ctx.B = NULL;
219 ctx->srp_ctx.A = NULL;
220 ctx->srp_ctx.a = NULL;
221 ctx->srp_ctx.b = NULL;
222 ctx->srp_ctx.v = NULL;
223 ctx->srp_ctx.login = NULL;
224 ctx->srp_ctx.srp_Mask = 0;
225 ctx->srp_ctx.info = NULL;
226 ctx->srp_ctx.strength = SRP_MINIMAL_N;
227
228 return (1);
229}
edc032b5
BL
230
231/* server side */
232int SSL_srp_server_param_with_username(SSL *s, int *ad)
0f113f3e
MC
233{
234 unsigned char b[SSL_MAX_MASTER_KEY_LENGTH];
235 int al;
236
237 *ad = SSL_AD_UNKNOWN_PSK_IDENTITY;
238 if ((s->srp_ctx.TLS_ext_srp_username_callback != NULL) &&
239 ((al =
240 s->srp_ctx.TLS_ext_srp_username_callback(s, ad,
241 s->srp_ctx.SRP_cb_arg)) !=
242 SSL_ERROR_NONE))
243 return al;
244
245 *ad = SSL_AD_INTERNAL_ERROR;
246 if ((s->srp_ctx.N == NULL) ||
247 (s->srp_ctx.g == NULL) ||
248 (s->srp_ctx.s == NULL) || (s->srp_ctx.v == NULL))
249 return SSL3_AL_FATAL;
250
251 if (RAND_bytes(b, sizeof(b)) <= 0)
252 return SSL3_AL_FATAL;
253 s->srp_ctx.b = BN_bin2bn(b, sizeof(b), NULL);
254 OPENSSL_cleanse(b, sizeof(b));
255
256 /* Calculate: B = (kv + g^b) % N */
257
258 return ((s->srp_ctx.B =
259 SRP_Calc_B(s->srp_ctx.b, s->srp_ctx.N, s->srp_ctx.g,
260 s->srp_ctx.v)) !=
261 NULL) ? SSL_ERROR_NONE : SSL3_AL_FATAL;
262}
263
264/*
265 * If the server just has the raw password, make up a verifier entry on the
266 * fly
267 */
268int SSL_set_srp_server_param_pw(SSL *s, const char *user, const char *pass,
269 const char *grp)
270{
271 SRP_gN *GN = SRP_get_default_gN(grp);
272 if (GN == NULL)
273 return -1;
274 s->srp_ctx.N = BN_dup(GN->N);
275 s->srp_ctx.g = BN_dup(GN->g);
276 if (s->srp_ctx.v != NULL) {
277 BN_clear_free(s->srp_ctx.v);
278 s->srp_ctx.v = NULL;
279 }
280 if (s->srp_ctx.s != NULL) {
281 BN_clear_free(s->srp_ctx.s);
282 s->srp_ctx.s = NULL;
283 }
284 if (!SRP_create_verifier_BN
285 (user, pass, &s->srp_ctx.s, &s->srp_ctx.v, GN->N, GN->g))
286 return -1;
287
288 return 1;
289}
edc032b5
BL
290
291int SSL_set_srp_server_param(SSL *s, const BIGNUM *N, const BIGNUM *g,
0f113f3e
MC
292 BIGNUM *sa, BIGNUM *v, char *info)
293{
294 if (N != NULL) {
295 if (s->srp_ctx.N != NULL) {
296 if (!BN_copy(s->srp_ctx.N, N)) {
297 BN_free(s->srp_ctx.N);
298 s->srp_ctx.N = NULL;
299 }
300 } else
301 s->srp_ctx.N = BN_dup(N);
302 }
303 if (g != NULL) {
304 if (s->srp_ctx.g != NULL) {
305 if (!BN_copy(s->srp_ctx.g, g)) {
306 BN_free(s->srp_ctx.g);
307 s->srp_ctx.g = NULL;
308 }
309 } else
310 s->srp_ctx.g = BN_dup(g);
311 }
312 if (sa != NULL) {
313 if (s->srp_ctx.s != NULL) {
314 if (!BN_copy(s->srp_ctx.s, sa)) {
315 BN_free(s->srp_ctx.s);
316 s->srp_ctx.s = NULL;
317 }
318 } else
319 s->srp_ctx.s = BN_dup(sa);
320 }
321 if (v != NULL) {
322 if (s->srp_ctx.v != NULL) {
323 if (!BN_copy(s->srp_ctx.v, v)) {
324 BN_free(s->srp_ctx.v);
325 s->srp_ctx.v = NULL;
326 }
327 } else
328 s->srp_ctx.v = BN_dup(v);
329 }
330 s->srp_ctx.info = info;
331
332 if (!(s->srp_ctx.N) ||
333 !(s->srp_ctx.g) || !(s->srp_ctx.s) || !(s->srp_ctx.v))
334 return -1;
335
336 return 1;
337}
338
339int SRP_generate_server_master_secret(SSL *s, unsigned char *master_key)
340{
341 BIGNUM *K = NULL, *u = NULL;
342 int ret = -1, tmp_len;
343 unsigned char *tmp = NULL;
344
345 if (!SRP_Verify_A_mod_N(s->srp_ctx.A, s->srp_ctx.N))
346 goto err;
347 if (!(u = SRP_Calc_u(s->srp_ctx.A, s->srp_ctx.B, s->srp_ctx.N)))
348 goto err;
349 if (!
350 (K =
351 SRP_Calc_server_key(s->srp_ctx.A, s->srp_ctx.v, u, s->srp_ctx.b,
352 s->srp_ctx.N)))
353 goto err;
354
355 tmp_len = BN_num_bytes(K);
356 if ((tmp = OPENSSL_malloc(tmp_len)) == NULL)
357 goto err;
358 BN_bn2bin(K, tmp);
359 ret =
360 s->method->ssl3_enc->generate_master_secret(s, master_key, tmp,
361 tmp_len);
362 err:
363 if (tmp) {
364 OPENSSL_cleanse(tmp, tmp_len);
365 OPENSSL_free(tmp);
366 }
367 BN_clear_free(K);
368 BN_clear_free(u);
369 return ret;
370}
edc032b5
BL
371
372/* client side */
0f113f3e
MC
373int SRP_generate_client_master_secret(SSL *s, unsigned char *master_key)
374{
375 BIGNUM *x = NULL, *u = NULL, *K = NULL;
376 int ret = -1, tmp_len;
377 char *passwd = NULL;
378 unsigned char *tmp = NULL;
379
380 /*
381 * Checks if b % n == 0
382 */
383 if (SRP_Verify_B_mod_N(s->srp_ctx.B, s->srp_ctx.N) == 0)
384 goto err;
385 if (!(u = SRP_Calc_u(s->srp_ctx.A, s->srp_ctx.B, s->srp_ctx.N)))
386 goto err;
387 if (s->srp_ctx.SRP_give_srp_client_pwd_callback == NULL)
388 goto err;
389 if (!
390 (passwd =
391 s->srp_ctx.SRP_give_srp_client_pwd_callback(s,
392 s->srp_ctx.SRP_cb_arg)))
393 goto err;
394 if (!(x = SRP_Calc_x(s->srp_ctx.s, s->srp_ctx.login, passwd)))
395 goto err;
396 if (!
397 (K =
398 SRP_Calc_client_key(s->srp_ctx.N, s->srp_ctx.B, s->srp_ctx.g, x,
399 s->srp_ctx.a, u)))
400 goto err;
401
402 tmp_len = BN_num_bytes(K);
403 if ((tmp = OPENSSL_malloc(tmp_len)) == NULL)
404 goto err;
405 BN_bn2bin(K, tmp);
406 ret =
407 s->method->ssl3_enc->generate_master_secret(s, master_key, tmp,
408 tmp_len);
409 err:
410 if (tmp) {
411 OPENSSL_cleanse(tmp, tmp_len);
412 OPENSSL_free(tmp);
413 }
414 BN_clear_free(K);
415 BN_clear_free(x);
416 if (passwd) {
417 OPENSSL_cleanse(passwd, strlen(passwd));
418 OPENSSL_free(passwd);
419 }
420 BN_clear_free(u);
421 return ret;
422}
edc032b5 423
0989790b 424int srp_verify_server_param(SSL *s, int *al)
0f113f3e
MC
425{
426 SRP_CTX *srp = &s->srp_ctx;
427 /*
428 * Sanity check parameters: we can quickly check B % N == 0 by checking B
429 * != 0 since B < N
430 */
431 if (BN_ucmp(srp->g, srp->N) >= 0 || BN_ucmp(srp->B, srp->N) >= 0
432 || BN_is_zero(srp->B)) {
433 *al = SSL3_AD_ILLEGAL_PARAMETER;
434 return 0;
435 }
436
437 if (BN_num_bits(srp->N) < srp->strength) {
438 *al = TLS1_AD_INSUFFICIENT_SECURITY;
439 return 0;
440 }
441
442 if (srp->SRP_verify_param_callback) {
443 if (srp->SRP_verify_param_callback(s, srp->SRP_cb_arg) <= 0) {
444 *al = TLS1_AD_INSUFFICIENT_SECURITY;
445 return 0;
446 }
447 } else if (!SRP_check_known_gN_param(srp->g, srp->N)) {
448 *al = TLS1_AD_INSUFFICIENT_SECURITY;
449 return 0;
450 }
451
452 return 1;
453}
0989790b
DSH
454
455int SRP_Calc_A_param(SSL *s)
0f113f3e
MC
456{
457 unsigned char rnd[SSL_MAX_MASTER_KEY_LENGTH];
edc032b5 458
0f113f3e
MC
459 if (RAND_bytes(rnd, sizeof(rnd)) <= 0)
460 return 0;
461 s->srp_ctx.a = BN_bin2bn(rnd, sizeof(rnd), s->srp_ctx.a);
462 OPENSSL_cleanse(rnd, sizeof(rnd));
edc032b5 463
0f113f3e
MC
464 if (!
465 (s->srp_ctx.A = SRP_Calc_A(s->srp_ctx.a, s->srp_ctx.N, s->srp_ctx.g)))
466 return 0;
edc032b5 467
0f113f3e
MC
468 return 1;
469}
edc032b5 470
edc032b5 471BIGNUM *SSL_get_srp_g(SSL *s)
0f113f3e
MC
472{
473 if (s->srp_ctx.g != NULL)
474 return s->srp_ctx.g;
475 return s->ctx->srp_ctx.g;
476}
edc032b5
BL
477
478BIGNUM *SSL_get_srp_N(SSL *s)
0f113f3e
MC
479{
480 if (s->srp_ctx.N != NULL)
481 return s->srp_ctx.N;
482 return s->ctx->srp_ctx.N;
483}
edc032b5
BL
484
485char *SSL_get_srp_username(SSL *s)
0f113f3e
MC
486{
487 if (s->srp_ctx.login != NULL)
488 return s->srp_ctx.login;
489 return s->ctx->srp_ctx.login;
490}
edc032b5
BL
491
492char *SSL_get_srp_userinfo(SSL *s)
0f113f3e
MC
493{
494 if (s->srp_ctx.info != NULL)
495 return s->srp_ctx.info;
496 return s->ctx->srp_ctx.info;
497}
edc032b5 498
0f113f3e
MC
499# define tls1_ctx_ctrl ssl3_ctx_ctrl
500# define tls1_ctx_callback_ctrl ssl3_ctx_callback_ctrl
edc032b5 501
0f113f3e
MC
502int SSL_CTX_set_srp_username(SSL_CTX *ctx, char *name)
503{
504 return tls1_ctx_ctrl(ctx, SSL_CTRL_SET_TLS_EXT_SRP_USERNAME, 0, name);
505}
edc032b5 506
0f113f3e
MC
507int SSL_CTX_set_srp_password(SSL_CTX *ctx, char *password)
508{
509 return tls1_ctx_ctrl(ctx, SSL_CTRL_SET_TLS_EXT_SRP_PASSWORD, 0, password);
510}
edc032b5
BL
511
512int SSL_CTX_set_srp_strength(SSL_CTX *ctx, int strength)
0f113f3e
MC
513{
514 return tls1_ctx_ctrl(ctx, SSL_CTRL_SET_TLS_EXT_SRP_STRENGTH, strength,
515 NULL);
516}
517
518int SSL_CTX_set_srp_verify_param_callback(SSL_CTX *ctx,
519 int (*cb) (SSL *, void *))
520{
521 return tls1_ctx_callback_ctrl(ctx, SSL_CTRL_SET_SRP_VERIFY_PARAM_CB,
522 (void (*)(void))cb);
523}
edc032b5
BL
524
525int SSL_CTX_set_srp_cb_arg(SSL_CTX *ctx, void *arg)
0f113f3e
MC
526{
527 return tls1_ctx_ctrl(ctx, SSL_CTRL_SET_SRP_ARG, 0, arg);
528}
edc032b5
BL
529
530int SSL_CTX_set_srp_username_callback(SSL_CTX *ctx,
0f113f3e
MC
531 int (*cb) (SSL *, int *, void *))
532{
533 return tls1_ctx_callback_ctrl(ctx, SSL_CTRL_SET_TLS_EXT_SRP_USERNAME_CB,
534 (void (*)(void))cb);
535}
536
537int SSL_CTX_set_srp_client_pwd_callback(SSL_CTX *ctx,
538 char *(*cb) (SSL *, void *))
539{
540 return tls1_ctx_callback_ctrl(ctx, SSL_CTRL_SET_SRP_GIVE_CLIENT_PWD_CB,
541 (void (*)(void))cb);
542}
edc032b5 543
edc032b5 544#endif