Mercurial > openid
diff src/c/openid.c @ 13:de04a3fc6b72
Stateless verification worked
author | Adam Chlipala <adam@chlipala.net> |
---|---|
date | Sun, 02 Jan 2011 10:11:38 -0500 |
parents | c778455fe570 |
children | 6b2a44da71b0 |
line wrap: on
line diff
--- a/src/c/openid.c Sat Jan 01 14:00:52 2011 -0500 +++ b/src/c/openid.c Sun Jan 02 10:11:38 2011 -0500 @@ -446,3 +446,16 @@ return base64(ctx, bufO, len1); } + +uw_OpenidFfi_inputs uw_OpenidFfi_remode(uw_context ctx, uw_OpenidFfi_outputs out, uw_Basis_string mode) { + uw_OpenidFfi_inputs in = uw_OpenidFfi_createInputs(ctx); + char *s; + + for (s = out->start; *s; s = strchr(strchr(s, 0)+1, 0)+1) + if (!strcmp("openid.mode", s)) + uw_OpenidFfi_addInput(ctx, in, "openid.mode", mode); + else + uw_OpenidFfi_addInput(ctx, in, s, strchr(s, 0)+1); + + return in; +}