3.11 library(http/http_openid): OpenID consumer and server library
AllApplicationManualNameSummaryHelp

  • Documentation
    • Reference manual
    • Packages
      • SWI-Prolog HTTP support
        • The HTTP server libraries
          • library(http/http_openid): OpenID consumer and server library
            • openid_hook/1
            • openid_login/1
            • openid_logout/1
            • openid_logged_in/1
            • openid_user/3
            • openid_login_form//2
            • openid_verify/2
            • openid_server/3
            • openid_current_url/2
            • openid_current_host/3
            • ssl_verify/5
            • openid_authenticate/4
            • openid_server/2
            • openid_grant/1
            • openid_associate/3
            • openid_associate/4
Availability::- use_module(library(http/http_openid)).
Source[semidet]openid_authenticate(+Request, -Server:url, -OpenID:url, -ReturnTo:url)
Succeeds if Request comes from the OpenID server and confirms that User is a verified OpenID user. ReturnTo provides the URL to return to.

After openid_verify/2 has redirected the browser to the OpenID server, and the OpenID server did its magic, it redirects the browser back to this address. The work is fairly trivial. If mode is cancel, the OpenId server denied. If id_res, the OpenId server replied positive, but we must verify what the server told us by checking the HMAC-SHA signature.

This call fails silently if their is no openid.mode field in the request.

throws
- openid(cancel) if request was cancelled by the OpenId server
- openid(signature_mismatch) if the HMAC signature check failed