Implemented Auth0 functionality to handler authentication. Not complete, will add to it some more. #15

This commit is contained in:
amazing-username
2019-04-21 21:07:13 -04:00
parent 4ba342b625
commit a161d2277a
14 changed files with 351 additions and 5 deletions
+19
View File
@@ -0,0 +1,19 @@
using System;
using Microsoft.AspNetCore.Authorization;
namespace Icarus.Authorization
{
public class HasScopeRequirement : IAuthorizationRequirement
{
public string Issuer { get; }
public string Scope { get; }
public HasScopeRequirement(string scope, string issuer)
{
Scope = scope ?? throw new ArgumentNullException(nameof(scope));
Issuer = issuer ?? throw new ArgumentNullException(nameof(issuer));
}
}
}