Skip to content

Instantly share code, notes, and snippets.

View gregorycfrank's full-sized avatar

Gregory gregorycfrank

View GitHub Profile
@gregorycfrank
gregorycfrank / scoperule.js
Created May 22, 2017 17:12
This will filter OIDC scope values based on OIDC standard scopes and a filter for a custom word.
function (user, context, callback) {
var oidcScopes = ['openid','profile','email','address','phone'];
var clientScope;
if (context.clientID === '<clientID>') {
clientScope = '<custom filter keyword>';
}
// The currently requested scopes can be accessed as follows: