public OperationController( ISmsStoreFactory factory, ServiceConfiguration configuration, IReportManager reportManager, IInboundManager inboundManager, ICredentialManager credentialManager, MetricManager metricManager) { this.store = factory.GetStore(); this.configuration = configuration; this.reportManager = reportManager; this.inboundManager = inboundManager; this.credentialManager = credentialManager; this.metricManager = metricManager; this.random = new Random(); this.proxyFactory = new ServiceProxyFactory((c) => { return(new FabricTransportServiceRemotingClientFactory( serializationProvider: new ServiceRemotingJsonSerializationProvider())); }); if (this.configuration.SmsOpsInfo.IsValid()) { this.mailHelper = new MailHelper(this.configuration.SmsOpsInfo); } }
public ReportTelemetryManager( ISmsStoreFactory factory, ServiceConfiguration configuration, BillingAgent billingAgent, MetricManager metricManager, ICredentialManager credentialManager) { this.store = factory.GetStore(); var account = CloudStorageAccount.Parse(configuration.TelemetryStoreConnectionString); this.client = account.CreateCloudTableClient(); this.summaryTable = this.client.GetTableReference(MessageSummaryTableName); this.detailTable = this.client.GetTableReference(MessageDetailTableName); this.batchTable = this.client.GetTableReference(MessageBatchRecordTableName); this.idMappingTable = this.client.GetTableReference(MessageIdMappingTableName); this.summaryTable.CreateIfNotExists(); this.detailTable.CreateIfNotExists(); this.batchTable.CreateIfNotExists(); this.idMappingTable.CreateIfNotExists(); this.billingAgent = billingAgent; this.metricManager = metricManager; this.credentialManager = credentialManager; this.updateLock = new SemaphoreSlim(1, 1); }
public AccountManager( IDataAccessAuthorizer dataAuthorizer, IUserManager userManager, IContactDataManager contactManager, ICredentialManager credentialManager, ICooperativeManager cooperativeManager, IFarmerManager farmerManager, IUserIdentityManager userIdentityManager, IMultiFactorAuthenticator multiFactorAuthenticator, StoreProvider storeProvider) { ThrowNullArguments( () => dataAuthorizer, () => userManager, () => contactManager, () => credentialManager, () => cooperativeManager, () => farmerManager, () => userIdentityManager, () => multiFactorAuthenticator, () => storeProvider); _storeProvider = storeProvider; _dataAccessAuthorizer = dataAuthorizer; _userManager = userManager; _userIdentityManager = userIdentityManager; _credentialManager = credentialManager; _cooperativeManager = cooperativeManager; _contactManager = contactManager; _farmerManager = farmerManager; _multiFactorAuth = multiFactorAuthenticator; }
public OIDCAuthenticator(AuthenticationConfig authenticationConfig, KeycloakConfig keycloakConfig, ICredentialManager credentialManager, IHttpServiceModule httpServiceModule, ILogger logger) : base(authenticationConfig, keycloakConfig, credentialManager, httpServiceModule, logger) { }
public static IPackageRepository CreateRepository(string source, ICredentialManager credentialManager) { if (source == null) { throw new ArgumentNullException("source"); } Uri uri; try { uri = new Uri(source); } catch (UriFormatException) { return(null); } if (uri.IsFile) { return(new LocalPackageRepository(source)); } else { credentialManager.TryAddUriCredentials(uri); return(new DataServicePackageRepository(uri, credentialManager.Get(uri))); } }
public PackageChooserViewModel( MruPackageSourceManager packageSourceManager, ICredentialManager credentialManager, bool showPrereleasePackages, bool autoLoadPackages, string fixedPackageSource) { if (packageSourceManager == null) { throw new ArgumentNullException("packageSourceManager"); } if (credentialManager == null) { throw new ArgumentNullException("credentialManager"); } _showPrereleasePackages = showPrereleasePackages; _fixedPackageSource = fixedPackageSource; _autoLoadPackages = autoLoadPackages; Packages = new ObservableCollection <PackageInfoViewModel>(); SortCommand = new RelayCommand <string>(Sort, CanSort); SearchCommand = new RelayCommand <string>(Search, CanSearch); ClearSearchCommand = new RelayCommand(ClearSearch, CanClearSearch); NavigationCommand = new RelayCommand <string>(NavigationCommandExecute, NavigationCommandCanExecute); LoadedCommand = new RelayCommand(async() => await Sort("VersionDownloadCount", ListSortDirection.Descending)); ChangePackageSourceCommand = new RelayCommand <string>(ChangePackageSource); CancelCommand = new RelayCommand(CancelCommandExecute, CanCancelCommandExecute); _packageSourceManager = packageSourceManager; _credentialManager = credentialManager; }
// Constructor for tests. public GgpDebugQueryTarget(IFileSystem fileSystem, SdkConfig.Factory sdkConfigFactory, IGameletClientFactory gameletClientFactory, IApplicationClientFactory applicationClientFactory, CancelableTask.Factory cancelableTaskFactory, IDialogUtil dialogUtil, IRemoteDeploy remoteDeploy, DebugSessionMetrics metrics, ICredentialManager credentialManager, ITestAccountClientFactory testAccountClientFactory, IGameletSelectorFactory gameletSelectorFactory, ICloudRunner cloudRunner, Versions.SdkVersion sdkVersion, ChromeClientLaunchCommandFormatter launchCommandFormatter, DebugEngine.DebugEngine.Params.Factory paramsFactory, IYetiVSIService yetiVsiService, IGameLauncher gameLauncher) { _fileSystem = fileSystem; _sdkConfigFactory = sdkConfigFactory; _gameletClientFactory = gameletClientFactory; _applicationClientFactory = applicationClientFactory; _cancelableTaskFactory = cancelableTaskFactory; _dialogUtil = dialogUtil; _remoteDeploy = remoteDeploy; _metrics = metrics; _credentialManager = credentialManager; _testAccountClientFactory = testAccountClientFactory; _cloudRunner = cloudRunner; _yetiVsiService = yetiVsiService; _gameletSelectorFactory = gameletSelectorFactory; _sdkVersion = sdkVersion; _launchCommandFormatter = launchCommandFormatter; _paramsFactory = paramsFactory; _gameLauncher = gameLauncher; }
public AppLogic(IOutputProvider output, IInputProvider input, ICredentialManager credentialManager, IDataManager inventoryManager) { _output = output; _input = input; _credentialManager = credentialManager; _inventoryManager = inventoryManager; }
public async Task InitializeAsync(IServiceProvider services, DiscordClient client, CancellationToken cancellationToken = default) { _credentials = services.GetService <ICredentialManager>(); _logger = services.GetService <ILogger <DiscordConfigurationProvider> >(); _client = client; _guild = FindConfigurationGuild() ?? await CreateConfigurationGuild(cancellationToken); var watch = Stopwatch.StartNew(); foreach (var channel in await _guild.GetChannelsAsync()) { if (channel is IMessageChannel textChannel) { await ReloadAsync(textChannel, false, cancellationToken); } } NotifyReload(); // reload in bulk and notify once client.MessageReceived += e => ReloadAsync(e.Message.Channel, true, cancellationToken); client.MessageUpdated += e => ReloadAsync(e.Channel, true, cancellationToken); client.MessageDeleted += e => ReloadAsync(e.Channel, true, cancellationToken); client.MessagesBulkDeleted += e => ReloadAsync(e.Channel, true, cancellationToken); client.ChannelCreated += e => ReloadAsync(e.Channel, true, cancellationToken); client.ChannelDeleted += e => ReloadAsync(e.Channel, true, cancellationToken); client.ChannelUpdated += e => ReloadAsync(e.NewChannel, true, cancellationToken); _logger.LogInformation($"Loaded all configuration in {watch.Elapsed.TotalSeconds:F}s."); }
public EmailProvider(StatelessServiceContext context) : base(context) { var nodeContext = FabricRuntime.GetNodeContext(); this.configuration = new ServiceConfiguration(nodeContext, context.CodePackageActivationContext); this.storeFactory = new EmailStoreFactory(configuration.DefaultConnectionString); this.billingAgent = new BillingAgent(); this.metricManager = new MetricManager(configuration); this.credentialManager = new CredentialManager(this.storeFactory); this.reportManager = new ReportManager( nodeContext.NodeName, this.storeFactory, this.configuration, this.billingAgent, this.metricManager, this.credentialManager); this.engine = new EmailEngine( this.storeFactory, this.configuration, this.metricManager, this.credentialManager); }
public UpdateManager(ICredentialManager credentialManager) { this.fetcher = new Fetcher(credentialManager.Credential); this.keeper = new Keeper(); credentialManager.CredentialChanged += HandleCredentialChanged; }
/// <summary> /// Initializes a new instance of the <see cref="T:AeroGear.Mobile.Auth.Authenticator.AbstractAuthenticator"/> class. /// </summary> /// <param name="authenticationConfig">Authentication config.</param> /// <param name="keycloakConfig">Keycloak config.</param> /// <param name="credentialManager">Credential manager.</param> /// <param name="httpServiceModule">Http service module.</param> /// <param name="logger">Logger.</param> public AbstractAuthenticator(AuthenticationConfig authenticationConfig, KeycloakConfig keycloakConfig, ICredentialManager credentialManager, IHttpServiceModule httpServiceModule, ILogger logger) { this.authenticationConfig = NonNull(authenticationConfig, "authenticationConfig"); this.keycloakConfig = NonNull(keycloakConfig, "keycloakConfig"); this.credentialManager = NonNull(credentialManager, "credentialManager"); this.httpService = NonNull(httpServiceModule, "httpServiceModule"); this.logger = NonNull(logger, "logger"); }
public AzureManagement(AzureManagementContext context) { _logger = context.Logger; _scriptArgs = context.ScriptArgs; _configurationManager = new ConfigurationManager(_logger); _credentialManager = new CredentialManager(_logger); }
public DiscordClientService(IOptionsMonitor <GeneralOptions> options, ICredentialManager credentials, ILogger <DiscordClient> logger, IConfigurationRoot configuration, IServiceProvider services) { _options = options; _credentials = credentials; _logger = logger; _configuration = configuration; _services = services; }
public GitClient(IEnvironment environment, IProcessManager processManager, ICredentialManager credentialManager, ITaskManager taskManager) { this.environment = environment; this.processManager = processManager; this.credentialManager = credentialManager; this.taskManager = taskManager; this.cancellationToken = taskManager.Token; }
public MonitoringManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; _alerts = new Lazy<MonitoringManagementAlerts>(() => new MonitoringManagementAlerts(managementContext)); _autoscale = new Lazy<MonitoringManagementAutoscale>(() => new MonitoringManagementAutoscale(managementContext)); _metrics = new Lazy<MonitoringManagementMetrics>(() => new MonitoringManagementMetrics(managementContext)); }
public Keychain(IEnvironment environment, ICredentialManager credentialManager) { Guard.ArgumentNotNull(environment, nameof(environment)); Guard.ArgumentNotNull(credentialManager, nameof(credentialManager)); Guard.NotNull(environment, environment.UserCachePath, nameof(environment.UserCachePath)); cachePath = environment.UserCachePath.Combine(ConnectionFile); this.credentialManager = credentialManager; }
public MonitoringManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; _alerts = new Lazy <MonitoringManagementAlerts>(() => new MonitoringManagementAlerts(managementContext)); _autoscale = new Lazy <MonitoringManagementAutoscale>(() => new MonitoringManagementAutoscale(managementContext)); _metrics = new Lazy <MonitoringManagementMetrics>(() => new MonitoringManagementMetrics(managementContext)); }
public ShellViewModel(IJabbRContext jabbrContext, IEventAggregator eventAggregator, ICredentialManager credentialManager) { this.jabbrContext = jabbrContext; this.credentialManager = credentialManager; eventAggregator.Subscribe(this); }
public override void Initialize(IHostContext hostContext) { base.Initialize(hostContext); _term = HostContext.GetService <ITerminal>(); _runnerServer = HostContext.GetService <IRunnerServer>(); _credMgr = HostContext.GetService <ICredentialManager>(); _configStore = HostContext.GetService <IConfigurationStore>(); }
public RepoPanel(string repositoryCopyRoot, Dependency info, ICredentialManager credentials) { DependencyInfo = info; _credentialManager = credentials; _repositoryCopyRoot = repositoryCopyRoot; //Note if the hash gets too expensive we may have to cut this (maybe could be async?) _hasLocalChanges = HasLocalChanges(); }
public EmailEngine( IEmailStoreFactory factory, ServiceConfiguration configuration, MetricManager metricManager, ICredentialManager credentialManager) { this.store = factory.GetStore(); this.credentialManager = credentialManager; this.metricManager = metricManager; this.configuration = configuration; }
public CredentialsController( ICredentialRepository repository, IMembershipManager membershipManager, ApplicationIdentityUserManager userManager, ICredentialManager credentialManager, IConfiguration configuration, IHttpContextAccessor httpContextAccessor) : base(repository, userManager, httpContextAccessor, membershipManager, configuration) { this.httpContextAccessor = httpContextAccessor; this.credentialManager = credentialManager; this.credentialManager.SetContext(SecurityContext); }
public void SetUp() { authenticationConfig = AuthenticationConfig.Builder.RedirectUri("test://example.com").Build(); keycloakConfig = new KeycloakConfig(kcConfig); credentialManagerMock = new CredentialManagerMock(); IHttpResponse httpResponse = (HttpResponseMock)HttpResponseMock.newResponse().withStatusCode(200); var requestToBeExecuted = new HttpRequestToBeExecutedMock(Task.FromResult(httpResponse), null); IHttpRequest httpRequestMock = (HttpRequestMock)HttpRequestMock.newRequest().withGetResult(requestToBeExecuted); httpModuleMock = (HttpServiceModuleMock)HttpServiceModuleMock.newMock().withNewRequest(httpRequestMock); authenticatorToTest = new OIDCAuthenticator(authenticationConfig, keycloakConfig, credentialManagerMock, httpModuleMock, logger); }
public void Test(string url, string branch, string subFolder, ICredentialManager credentialManager, Action <bool, string> onComplete) { if (Testing) { throw new Exception("[RepositoryTester] Already busy testing."); } Testing = true; ThreadPool.QueueUserWorkItem(TestRepositoryValid, new TestState { Url = url, Branch = branch, SubFolder = subFolder, CredentialManager = credentialManager, OnComplete = onComplete }); }
public Repository(ICredentialManager credentials, string url, string localDestination, string copyDestination, string subFolder, string branch = "master", string tag = "") { _state = new RepoState { CredentialManager = credentials, Url = url, LocalDestination = localDestination, CopyDestination = copyDestination, SubFolder = subFolder, Branch = branch, Tag = tag }; }
public ApplicationLauncher( ILiveOptions <ApplicationConfiguration> liveOptions, ICredentialManager credentialManager, IMutexHandler mutexHandler, ILogger <ApplicationLauncher> logger, IPrivilegeManager privilegeManager) { this.logger = logger.ThrowIfNull(nameof(logger)); this.mutexHandler = mutexHandler.ThrowIfNull(nameof(mutexHandler)); this.credentialManager = credentialManager.ThrowIfNull(nameof(credentialManager)); this.liveOptions = liveOptions.ThrowIfNull(nameof(liveOptions)); this.privilegeManager = privilegeManager.ThrowIfNull(nameof(privilegeManager)); }
public LoginPage( ICredentialManager <DijnetCredential> credentialManager, IAuthClient <DijnetLoginResult> authClient, DijnetBrowserFactory dijnetBrowserFactory, InvoicePageFactory invoicePageFactory) { this.credentialManager = credentialManager ?? throw new ArgumentNullException(nameof(credentialManager)); this.authClient = authClient ?? throw new ArgumentNullException(nameof(authClient)); this.dijnetBrowserFactory = dijnetBrowserFactory ?? throw new ArgumentNullException(nameof(dijnetBrowserFactory)); this.invoicePageFactory = invoicePageFactory ?? throw new ArgumentNullException(nameof(invoicePageFactory)); InitializeComponent(); ViewModel.Status = "Loading..."; }
public void SetUp() { sdkConfigFactory = Substitute.For <SdkConfig.Factory>(); credentialManager = Substitute.For <ICredentialManager>(); cloudConnection = Substitute.For <ICloudConnection>(); funcToRun = Substitute.For <GrpcProjectFunction>(); // Since a channel doesn't initialize the connection until an API is called, and since // we don't call any APIs we can use a real channel object. Use an empty host - if // this behaviour changes in the future, the channel will fail to connect. var channel = new Channel("", ChannelCredentials.Insecure); cloudConnection.CreateChannel(Arg.Any <string>(), Arg.Any <string>()).Returns(channel); cloudRunner = new CloudRunner(sdkConfigFactory, credentialManager, cloudConnection, new GgpSDKUtil()); }
/// <summary> /// CredentialsController constructor /// </summary> /// <param name="repository"></param> /// <param name="membershipManager"></param> /// <param name="userManager"></param> /// <param name="credentialManager"></param> /// <param name="configuration"></param> /// <param name="httpContextAccessor"></param> /// <param name="webhookPublisher"></param> public CredentialsController( ICredentialRepository repository, IMembershipManager membershipManager, ApplicationIdentityUserManager userManager, ICredentialManager credentialManager, IConfiguration configuration, IHttpContextAccessor httpContextAccessor, IWebhookPublisher webhookPublisher, ICredentialRepository credentialRepository) : base(repository, userManager, httpContextAccessor, membershipManager, configuration) { _httpContextAccessor = httpContextAccessor; _credentialManager = credentialManager; _credentialManager.SetContext(SecurityContext); _webhookPublisher = webhookPublisher; _credentialRepository = credentialRepository; }
public TwitterMain(ICredentialManager credManager, ILoginManager loginManager, IFriendFinder friendFinder, IFriendConnector friendConnector, IConsole console, ITweetConfiguration configuration, IFollowerCache cache) { _credManager = credManager; _loginManager = loginManager; _friendFinder = friendFinder; _friendConnector = friendConnector; _console = console; _configuration = configuration; _cache = cache; _random = new Random(Environment.TickCount); }
public InboundManager( ISmsStoreFactory factory, ServiceConfiguration configuration, IReportManager reportManager, ICredentialManager credentialManager) { this.store = factory.GetStore(); this.telemetryManager = new InboundTelemetryManager(configuration); this.reportManager = reportManager; this.credentialManager = credentialManager; this.subscriber = Observable .Timer(TimeSpan.Zero, MessageCleanupPeriod) .Select(x => Observable.FromAsync(async() => await CleanupAsync())) .Concat() .Subscribe(); }
/// <summary> /// Initializes a new instance of the CredentialEditorViewModel class. /// </summary> public CredentialEditorViewModel(IDeployitServer server, ICredentialManager credentialManager, Uri uri = null) { if (server == null) throw new ArgumentNullException("server", "server is null."); if (credentialManager == null) throw new ArgumentNullException("credentialManager", "credentialManager is null."); _server = server; _credentialManager = credentialManager; ErrorMessage = _server.LastConnectionStatus == ConnectionStatus.Connected ? "Connected" : "Not connected"; if (uri != null) { _url = uri.ToString(); } CheckConnectionCommand = new DelegateCommand<PasswordBox>(DoCheckConnection); }
public MainWindowVM(IDeployitServer server, ICredentialManager credentialManager) { if (credentialManager == null) { throw new ArgumentNullException("credentialManager", @"credentialManager is null."); } if (server == null) { throw new ArgumentNullException("server", @"server is null."); } _credentialManager = credentialManager; _server = server; _server.ConnectionChanged += (_, __) => ServerConnectionChanged(); TryConnect(); ConnectToDeployitCommand = new DelegateCommand(DoConnectToDeployit); NewManifestCommand = new DelegateCommand(DoNewManifest); OpenManifestCommand = new DelegateCommand(DoOpenManifest); SaveManifestCommand = new DelegateCommand(() => DoSaveManifest()); UploadPackageCommand = new DelegateCommand(DoUploadPackage); QuitCommand = new DelegateCommand(() => DoQuit()); Application.Current.MainWindow.Closing += DoQuit; if (_server.LastConnectionStatus != ConnectionStatus.Connected) { DoConnectToDeployit(); } if (_server.LastConnectionStatus != ConnectionStatus.Connected) { Application.Current.MainWindow.Close(); } else { DoNewManifest(); } }
public SchedulerManagement() { //_logger = managementContext.Logger; _credentialManager = new CredentialManager(); }
public SchedulerManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }
public InfrastructureManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }
public VirtualNetworkManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }
public WebSiteManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }
public CredentialDialogViewModel(IDeployitServer server, ICredentialManager credentialManager = null, Uri uri = null) { Editor = new CredentialEditorViewModel(server, credentialManager, uri); Editor.IsConnectedChanged += OnIsConnectedChanged; }
private void CreateManifestEditorDataContext(IDeployitServer server, ICredentialManager credentialManager) { DataContext = new MainWindowVM(server, credentialManager); }
public MonitoringManagementMetrics(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }
public ScheduleJob() { _credentialManager = new CredentialManager(); _scheduleManagement = new SchedulerManagement(); }
public MediaManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }
public MonitoringManagementAutoscale(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }
public ServiceBusManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }
public StorageManagement(ManagementContext managementContext) { _logger = managementContext.Logger; _credentialManager = managementContext.CredentialManager; }