Created
March 22, 2018 22:54
-
-
Save MrPrashantT/d1fae183c7e114edb69869309d5c91fc to your computer and use it in GitHub Desktop.
set OIDC conformant flag on context object
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function (user, context, callback) { | |
var oidcConformantClients = ['client_id_1', 'client_id_2']; //oidc conformant clients | |
var isOidcConformantClient = oidcConformantClients.some( | |
function (clientId) { | |
return context.clientID === clientId; | |
}); | |
if (isOidcConformantClient) { | |
context.isOidcConformant = true; | |
} else { | |
context.isOidcConformant = false; | |
} | |
return callback(null, user, context); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment