Skip to content

nonce parameter is not accessible #7

Description

@nicokaiser
// 'id_token' grant type (Implicit Flow)
server.grant(oauth2orizeOpenid.grant.idToken(issueIDToken));

...

function issueIDToken(client, user, done) {
    debug('Issuing ID Token');
    done(null, jwt.encode({
        'iss': config.baseUrl,
        'sub': user.id,
        'aud': client.clientId,
        'exp': now() + config.idTokenTTL,
        'iat': now(),
        'nonce': ...
        'auth_time': now()
    }, config.key, config.idTokenAlg));
}

http://openid.net/specs/openid-connect-core-1_0-17.html

In issueIDToken I have to include the nonce value from the request parameter, but I have no chance to access the request. Even with server.grant(oauth2orizeOpenid.extensions()); there seems to be no interface to get the nonce value (despite the extensions function extracting it from the request somehow).

What's the prefered way to solve this? OpenID consumers seem to rely on the nonce being correctly returned.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions