Potential to get the email address associated with a Google Account

  • Ray Brunsting
    Ray Brunsting

    I noticed that this alternative project (http://findingscience.com/mod_auth_openid/) has a way to fetch the email address associated with the Google account being authenticated against. Is this also possible with mod_auth_oid?

    By the way, thanks a lot for creating and supporting this project. I've managed to get it working, and am now trying to streamline the 'registration' process, which will require mapping the Google OpenID to an email address. Here is my current/poor registration page so far: https://data.kawok.net/register/register.shtml.

    Thanks, Ray

    Ray Brunsting, CTO, Tula Foundation / www.tula.org

  • Yes, the auth-oid-info handler may be used to determine a user's OpenID associated for the specific server.


    Apache config:

    # viewer to determine your OpenID
    <Location /register>
       SetHandler             auth-oid-info      
       SetEnvIf               Request_Method GET  parp
       Options                Includes
       AddType                text/html .shtml
       AddOutputFilter        INCLUDES .shtml

    Sample link:

    <a href="/register/index.shtml?get_openid_identifier=https%3A%2F%2Fwww.google.com%2Faccounts%2Fo8%2Fid">view your openid</a>

    Sample page (stored at /register/index.shtml):

    <p><a href="/">back</a></a></p>
    <p>your openid: <input readonly size="70" value="<!--#echo var="get_openid_identifier"-->" /> </p>
    Last edit: Pascal Buchbinder 2014-04-26