public PlexMembershipProvider() { _userService = EngineContext.Current.Resolve <IUserService>(); _oauthService = EngineContext.Current.Resolve <IOAuthService>(); _oauthTokenService = EngineContext.Current.Resolve <IOAuthTokenService>(); _membershipService = EngineContext.Current.Resolve <IMembershipService>(); }
public PlexMembershipProvider(IUserService userService, IOAuthService oauthService, IOAuthTokenService oauthTokenService, IMembershipService membershipService) { _userService = userService; _oauthService = oauthService; _oauthTokenService = oauthTokenService; _membershipService = membershipService; }
public CachingOAuthTokenServiceDecorator(IOAuthTokenService oAuthTokenService) { if (oAuthTokenService == null) { throw new ArgumentNullException("oAuthTokenService"); } _oAuthTokenService = oAuthTokenService; }
internal OAuthServicesContext(IOAuthUserService userService, IOAuthClientStore clientStore, IOAuthRefreshTokenStore refreshTokenStore, IOAuthTokenService tokenService) { UserService = userService; ClientStore = clientStore; RefreshTokenStore = refreshTokenStore; TokenService = tokenService; }
public ReliableOAuthTokenServiceDecorator(IOAuthTokenService oAuthTokenService) { if (oAuthTokenService == null) { throw new ArgumentNullException("oAuthTokenService"); } _oAuthTokenService = oAuthTokenService; _circuitBreakerPolicy = CreateCircuitBreakerPolicy(); _retryPolicy = CreateWaitAndRetryPolicy(); }
public PrivilegedAccessQueryHandler(ISecretRepository secretRepository, ITotpService totpService, IOAuthTokenService tokenService, ICacheProvider cacheProvider, ILogger logger) { _secretRepository = secretRepository; _totpService = totpService; _tokenService = tokenService; _cacheProvider = cacheProvider; _logger = logger; }
static HomeController() { // This stuff should come from config and get set up // as part of the app start-up (IoC config, etc...) _httpClientGovernor = new HttpClientGovernor(); var clientId = @"362b88659454lt0g8b3ontlr7e"; var clientSecret = @""; // Ask me for this. var scope = @"Default/STS"; var tokenEndpoint = @"https://95be0fd7-c5a6-4581-967e-27a82f7abdc1.auth.us-east-1.amazoncognito.com/oauth2/token"; _oAuthTokenService = new CachingOAuthTokenServiceDecorator( new ReliableOAuthTokenServiceDecorator( new OAuthTokenService(_httpClientGovernor, clientId, clientSecret, scope, tokenEndpoint))); }
public HmrcAuthTokenBroker( [RequiredPolicy(HmrcExecutionPolicy.Name)] ExecutionPolicy executionPolicy, ILogger logger, IOAuthTokenService tokenService, ISecretRepository secretRepository, ITotpService totpService, ITokenRefresher tokenRefresher, IHmrcAuthTokenBrokerConfig hmrcAuthTokenBrokerConfig) { _secretRepository = secretRepository; _totpService = totpService; _tokenService = tokenService; _logger = logger; _executionPolicy = executionPolicy; _tokenRefresher = tokenRefresher; _hmrcAuthTokenBrokerConfig = hmrcAuthTokenBrokerConfig; _initialiseTask = InitialiseToken(); }
public TokenService(IOAuthTokenService tokenClient) { _tokenClient = tokenClient; }