예제 #1
0
        public BrokerBase(string clientId, string clientSecret, string scope, IAuthorizationUriAcquirer authUriAcquirer)
        {
            ClientId     = clientId;
            ClientSecret = clientSecret;
            Scope        = scope;

            AuthUriAcquirer = authUriAcquirer;
            var storageKey = (clientId + clientSecret + scope).Sha1();

            SecureCache = new SecureTokenCache(storageKey);
        }
예제 #2
0
 public GithubBroker(string clientId, string clientSecret, string scope, IAuthorizationUriAcquirer authUriAcquirer) : base(clientId, clientSecret, scope, authUriAcquirer)
 {
 }
예제 #3
0
        internal OpenIdConnectBroker(string authority, string clientId, string clientSecret, string scope, IAuthorizationUriAcquirer authUriAcquirer, DiscoveryPolicy discoveryPolicy) :
            base(clientId, clientSecret, scope, authUriAcquirer)
        {
            Authority = authority;
            var client = new DiscoveryClient(authority);

            if (discoveryPolicy != null)
            {
                client.Policy = discoveryPolicy;
            }

            Discovery = new DiscoveryCache(client);
        }
예제 #4
0
 public OpenIdConnectBroker(string authority, string clientId, string clientSecret, string scope, IAuthorizationUriAcquirer authUriAcquirer) :
     this(authority, clientId, clientSecret, scope, authUriAcquirer, null)
 {
 }