Exemple #1
0
 public CasGoogleId(
     ILogger <CasGoogleId> logger,
     CasTokenIssuer tokenIssuer,
     ICasClaimsBuilder claimsBuilder       = null,
     ICasAuthCodeReceiver authCodeReceiver = null
     ) : base(logger, tokenIssuer, claimsBuilder, authCodeReceiver)
 {
     this.ConfigManager = new ConfigurationManager <OpenIdConnectConfiguration>("https://accounts.google.com/.well-known/openid-configuration", new OpenIdConnectConfigurationRetriever());
 }
Exemple #2
0
 public CasIdp(
     ILogger logger,
     CasTokenIssuer tokenIssuer,
     ICasClaimsBuilder claimsBuilder       = null,
     ICasAuthCodeReceiver authCodeReceiver = null
     )
 {
     this.Logger           = logger;
     this.TokenIssuer      = tokenIssuer;
     this.ClaimsBuilder    = claimsBuilder;
     this.AuthCodeReceiver = authCodeReceiver;
 }
Exemple #3
0
 public CasAzureAd(
     ILogger <CasAzureAd> logger,
     IConfig config,
     CasTokenIssuer tokenIssuer,
     IHttpClientFactory httpClientFactory,
     IAccessTokenFetcher accessTokenFetcher,
     ICasClaimsBuilder claimsBuilder       = null,
     ICasAuthCodeReceiver authCodeReceiver = null
     ) : base(logger, tokenIssuer, claimsBuilder, authCodeReceiver)
 {
     this.ConfigManager      = new ConfigurationManager <OpenIdConnectConfiguration>($"{CasConfig.AzureAuthority}/.well-known/openid-configuration", new OpenIdConnectConfigurationRetriever());
     this.HttpClient         = httpClientFactory.CreateClient("cas");
     this.AccessTokenFetcher = accessTokenFetcher;
     this.Config             = config as CasConfig;
     if (this.Config == null)
     {
         throw new Exception("CasAzureAd: CasConfig was not found in the IServiceCollection.");
     }
 }