Skip to content

Instantly share code, notes, and snippets.

@softwarejc
Last active January 31, 2016 07:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save softwarejc/ca37170d678429a5d609 to your computer and use it in GitHub Desktop.
Save softwarejc/ca37170d678429a5d609 to your computer and use it in GitHub Desktop.
// Configure authorization
services.AddAuthorization(options => options.AddPolicy(CookieMonsterSecurity.OnlyGoodMonstersPolicy, policy =>
{
policy.AuthenticationSchemes.Add(CookieMonsterSecurity.CookieMonsterAuthenticationSchema);
// Our own requirement logic...
policy.AddRequirements(new IsGoodMonsterRequirement());
}));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment