document where we got the schema from
authorArt Cancro <ajc@uncensored.citadel.org>
Thu, 1 Dec 2011 17:09:42 +0000 (12:09 -0500)
committerArt Cancro <ajc@uncensored.citadel.org>
Thu, 1 Dec 2011 17:09:42 +0000 (12:09 -0500)
citadel/modules/openid/serv_openid_rp.c

index 57dfb10f3cca969ff6f32af691b9143028146be8..da0b7b42e8b05466e0c2f721b8115b01caad8e19 100644 (file)
@@ -926,7 +926,17 @@ void cmd_oids(char *argbuf) {
                StrBufAppendBufPlain(RedirectUrl, HKEY("&openid.identity="), 0);
                StrBufUrlescAppend(RedirectUrl, oiddata->claimed_id, NULL);
 
-               /* Attribute Exchange */
+               /* return_to completes the round trip */
+               StrBufAppendBufPlain(RedirectUrl, HKEY("&openid.return_to="), 0);
+               StrBufUrlescAppend(RedirectUrl, return_to, NULL);
+
+               /* Attribute Exchange
+                * See:
+                *      http://openid.net/specs/openid-attribute-exchange-1_0.html
+                *      http://code.google.com/apis/accounts/docs/OpenID.html#endpoint
+                *      http://test-id.net/OP/AXFetch.aspx
+                */
+
                StrBufAppendBufPlain(RedirectUrl, HKEY("&openid.ns.ax="), 0);
                StrBufUrlescAppend(RedirectUrl, NULL, "http://openid.net/srv/ax/1.0");
 
@@ -946,10 +956,6 @@ void cmd_oids(char *argbuf) {
                StrBufAppendBufPlain(RedirectUrl, HKEY("&openid.ax.type.nickname="), 0);
                StrBufUrlescAppend(RedirectUrl, NULL, "http://axschema.org/namePerson/nickname");
 
-               /* return_to completes the round trip */
-               StrBufAppendBufPlain(RedirectUrl, HKEY("&openid.return_to="), 0);
-               StrBufUrlescAppend(RedirectUrl, return_to, NULL);
-
                syslog(LOG_DEBUG, "OpenID: redirecting client to %s", ChrPtr(RedirectUrl));
                cprintf("%d %s\n", CIT_OK, ChrPtr(RedirectUrl));
        }