This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "GNU gsasl".
http://git.savannah.gnu.org/cgit/gsasl.git/commit/?id=0b3336f0900c51a2a93911d862f79970c43744bb The branch, master has been updated via 0b3336f0900c51a2a93911d862f79970c43744bb (commit) via 2a0f09046274a510db9bc4e6874aecf2be6df0d9 (commit) from 9e06f8bfb61e28d5360051855840b0c94e120b3d (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 0b3336f0900c51a2a93911d862f79970c43744bb Author: Simon Josefsson <[email protected]> Date: Wed Sep 16 17:16:01 2009 +0200 SCRAM: Store username property in server. commit 2a0f09046274a510db9bc4e6874aecf2be6df0d9 Author: Simon Josefsson <[email protected]> Date: Wed Sep 16 17:14:50 2009 +0200 Also check that AUTHID is set and correct in callback. ----------------------------------------------------------------------- Summary of changes: lib/scram/server.c | 2 ++ tests/scram.c | 7 +++++++ 2 files changed, 9 insertions(+), 0 deletions(-) diff --git a/lib/scram/server.c b/lib/scram/server.c index 931966f..e162429 100644 --- a/lib/scram/server.c +++ b/lib/scram/server.c @@ -176,6 +176,8 @@ _gsasl_scram_sha1_server_step (Gsasl_session * sctx, state->sf.nonce[cnlen + SNONCE_ENTROPY_BYTES] = '\0'; } + gsasl_property_set (sctx, GSASL_AUTHID, state->cf.username); + { const char *p = gsasl_property_get (sctx, GSASL_SCRAM_ITER); if (p) diff --git a/tests/scram.c b/tests/scram.c index ef96c34..ceab6c8 100644 --- a/tests/scram.c +++ b/tests/scram.c @@ -35,6 +35,8 @@ /* "Al\xC2\xAA""dd\xC2\xAD""in\xC2\xAE" */ #define AUTHZID "joe" +#define EXPECTED_USERNAME "Ali Baba" + size_t i; static int @@ -65,6 +67,10 @@ callback (Gsasl * ctx, Gsasl_session * sctx, Gsasl_property prop) break; case GSASL_SCRAM_ITER: + if (strcmp (gsasl_property_fast (sctx, GSASL_AUTHID), + EXPECTED_USERNAME) != 0) + fail ("Username mismatch: %s", + gsasl_property_fast (sctx, GSASL_AUTHID)); if (i & 0x02) { gsasl_property_set (sctx, prop, "1234"); @@ -81,6 +87,7 @@ callback (Gsasl * ctx, Gsasl_session * sctx, Gsasl_property prop) break; case GSASL_SCRAM_SALTED_PASSWORD: + /* No support for this yet. */ break; default: hooks/post-receive -- GNU gsasl _______________________________________________ Gsasl-commit mailing list [email protected] http://lists.gnu.org/mailman/listinfo/gsasl-commit
