use of uk.gov.ida.common.shared.security.verification.PKIXParametersProvider in project verify-hub by alphagov.
the class SamlProxyModule method configure.
@Override
protected void configure() {
bind(TrustStoreConfiguration.class).to(SamlProxyConfiguration.class);
bind(RestfulClientConfiguration.class).to(SamlProxyConfiguration.class);
bind(PublicKeyInputStreamFactory.class).toInstance(new PublicKeyFileInputStreamFactory());
bind(SigningKeyStore.class).to(AuthnRequestKeyStore.class);
bind(Client.class).toProvider(DefaultClientProvider.class).in(Scopes.SINGLETON);
bind(EventSinkProxy.class).to(EventSinkHttpProxy.class);
bind(KeyStore.class).toProvider(KeyStoreProvider.class).in(Scopes.SINGLETON);
bind(ConfigServiceKeyStore.class).asEagerSingleton();
bind(KeyStoreLoader.class).toInstance(new KeyStoreLoader());
bind(ResponseMaxSizeValidator.class);
bind(ExpiredCertificateMetadataFilter.class).toInstance(new ExpiredCertificateMetadataFilter());
bind(X509CertificateFactory.class).toInstance(new X509CertificateFactory());
bind(CertificateChainValidator.class);
bind(CertificatesConfigProxy.class);
bind(TrustStoreForCertificateProvider.class);
bind(StringSizeValidator.class).toInstance(new StringSizeValidator());
bind(JsonResponseProcessor.class);
bind(ObjectMapper.class).toInstance(new ObjectMapper());
bind(PKIXParametersProvider.class).toInstance(new PKIXParametersProvider());
bind(RelayStateValidator.class).toInstance(new RelayStateValidator());
bind(ProtectiveMonitoringLogFormatter.class).toInstance(new ProtectiveMonitoringLogFormatter());
bind(KeyStoreCache.class);
bind(EventSinkMessageSender.class);
bind(ExceptionAuditor.class);
bind(ProtectiveMonitoringLogger.class);
bind(SessionProxy.class);
bind(new TypeLiteral<LevelLoggerFactory<SamlProxySamlTransformationErrorExceptionMapper>>() {
}).toInstance(new LevelLoggerFactory<>());
bind(new TypeLiteral<LevelLoggerFactory<NoKeyConfiguredForEntityExceptionMapper>>() {
}).toInstance(new LevelLoggerFactory<>());
bind(new TypeLiteral<LevelLoggerFactory<SamlProxyApplicationExceptionMapper>>() {
}).toInstance(new LevelLoggerFactory<>());
bind(new TypeLiteral<LevelLoggerFactory<SamlProxyExceptionMapper>>() {
}).toInstance(new LevelLoggerFactory<>());
bind(SamlMessageSenderHandler.class);
bind(ExternalCommunicationEventLogger.class);
bind(IpAddressResolver.class).toInstance(new IpAddressResolver());
}
use of uk.gov.ida.common.shared.security.verification.PKIXParametersProvider in project verify-hub by alphagov.
the class CryptoModule method configure.
@Override
protected void configure() {
bind(EncryptionKeyStore.class).to(HubEncryptionKeyStore.class).asEagerSingleton();
bind(SigningKeyStore.class).annotatedWith(Names.named("authnRequestKeyStore")).to(AuthnRequestKeyStore.class).asEagerSingleton();
bind(SigningKeyStore.class).annotatedWith(Names.named("samlResponseFromMatchingServiceKeyStore")).to(SamlResponseFromMatchingServiceKeyStore.class).asEagerSingleton();
bind(X509CertificateFactory.class).toInstance(new X509CertificateFactory());
bind(CertificateChainValidator.class);
bind(PKIXParametersProvider.class).toInstance(new PKIXParametersProvider());
bind(CertificatesConfigProxy.class);
bind(TrustStoreForCertificateProvider.class);
bind(EncryptionCredentialFactory.class);
bind(KeyStoreCache.class);
bind(KeyStoreLoader.class).toInstance(new KeyStoreLoader());
bind(SignatureFactory.class);
bind(IdaKeyStoreCredentialRetriever.class);
bind(SamlResponseAssertionEncrypter.class);
bind(AssertionBlobEncrypter.class);
bind(EncrypterFactory.class).toInstance(new EncrypterFactory());
bind(SignatureAlgorithm.class).toInstance(new SignatureRSASHA1());
bind(DigestAlgorithm.class).toInstance(new DigestSHA256());
}
use of uk.gov.ida.common.shared.security.verification.PKIXParametersProvider in project verify-hub by alphagov.
the class ConfigModule method configure.
@Override
protected void configure() {
bind(ConfigHealthCheck.class).asEagerSingleton();
bind(ConfigDataBootstrap.class).asEagerSingleton();
bind(CertificateChainConfigValidator.class).annotatedWith(CertificateConfigValidator.class).to(LoggingCertificateChainConfigValidator.class);
bind(TrustStoreConfiguration.class).to(ConfigConfiguration.class);
bind(new TypeLiteral<ConfigurationFactoryFactory<IdentityProviderConfigEntityData>>() {
}).toInstance(new DefaultConfigurationFactoryFactory<IdentityProviderConfigEntityData>());
bind(new TypeLiteral<ConfigurationFactoryFactory<TransactionConfigEntityData>>() {
}).toInstance(new DefaultConfigurationFactoryFactory<TransactionConfigEntityData>());
bind(new TypeLiteral<ConfigurationFactoryFactory<MatchingServiceConfigEntityData>>() {
}).toInstance(new DefaultConfigurationFactoryFactory<MatchingServiceConfigEntityData>());
bind(new TypeLiteral<ConfigurationFactoryFactory<CountriesConfigEntityData>>() {
}).toInstance(new DefaultConfigurationFactoryFactory<CountriesConfigEntityData>());
bind(new TypeLiteral<ConfigDataSource<TransactionConfigEntityData>>() {
}).to(FileBackedTransactionConfigDataSource.class).asEagerSingleton();
bind(new TypeLiteral<ConfigDataSource<MatchingServiceConfigEntityData>>() {
}).to(FileBackedMatchingServiceConfigDataSource.class).asEagerSingleton();
bind(new TypeLiteral<ConfigDataSource<IdentityProviderConfigEntityData>>() {
}).to(FileBackedIdentityProviderConfigDataSource.class).asEagerSingleton();
bind(new TypeLiteral<ConfigDataSource<CountriesConfigEntityData>>() {
}).to(FileBackedCountriesConfigDataSource.class).asEagerSingleton();
bind(new TypeLiteral<ConfigEntityDataRepository<TransactionConfigEntityData>>() {
}).asEagerSingleton();
bind(new TypeLiteral<ConfigEntityDataRepository<CountriesConfigEntityData>>() {
}).asEagerSingleton();
bind(new TypeLiteral<ConfigEntityDataRepository<MatchingServiceConfigEntityData>>() {
}).asEagerSingleton();
bind(new TypeLiteral<ConfigEntityDataRepository<IdentityProviderConfigEntityData>>() {
}).asEagerSingleton();
bind(ObjectMapper.class).toInstance(new ObjectMapper().registerModule(new GuavaModule()));
bind(LevelsOfAssuranceConfigValidator.class).toInstance(new LevelsOfAssuranceConfigValidator());
bind(CertificateChainValidator.class);
bind(TrustStoreForCertificateProvider.class);
bind(X509CertificateFactory.class).toInstance(new X509CertificateFactory());
bind(KeyStoreCache.class);
bind(ExceptionFactory.class);
bind(OCSPCertificateChainValidityChecker.class);
bind(EntityConfigDataToCertificateDtoTransformer.class);
bind(OCSPCertificateChainValidator.class);
bind(IdpPredicateFactory.class);
bind(KeyStoreLoader.class).toInstance(new KeyStoreLoader());
bind(OCSPPKIXParametersProvider.class).toInstance(new OCSPPKIXParametersProvider());
bind(PKIXParametersProvider.class).toInstance(new PKIXParametersProvider());
bind(CertificateService.class);
}
use of uk.gov.ida.common.shared.security.verification.PKIXParametersProvider in project verify-hub by alphagov.
the class SamlSoapProxyModule method configure.
@Override
protected void configure() {
bind(TrustStoreConfiguration.class).to(SamlSoapProxyConfiguration.class);
bind(EventSinkProxy.class).to(EventSinkHttpProxy.class);
bind(PublicKeyInputStreamFactory.class).toInstance(new PublicKeyFileInputStreamFactory());
bind(InternalPublicKeyStore.class).to(HubMetadataPublicKeyStore.class);
bind(RestfulClientConfiguration.class).to(SamlSoapProxyConfiguration.class);
bind(Client.class).toProvider(DefaultClientProvider.class).asEagerSingleton();
bind(new TypeLiteral<ConfigurationFactoryFactory<SupportedMsaVersions>>() {
}).toInstance(new DefaultConfigurationFactoryFactory<SupportedMsaVersions>() {
});
bind(new TypeLiteral<SupportedMsaVersionsRepository>() {
}).asEagerSingleton();
bind(SupportedMsaVersionsBootstrap.class).asEagerSingleton();
bind(SupportedMsaVersionsLoader.class).asEagerSingleton();
bind(MetadataRefreshTask.class).asEagerSingleton();
bind(ConfigServiceKeyStore.class).asEagerSingleton();
bind(ExpiredCertificateMetadataFilter.class).toInstance(new ExpiredCertificateMetadataFilter());
bind(UrlConfigurationSourceProvider.class).toInstance(new UrlConfigurationSourceProvider());
bind(TrustStoreForCertificateProvider.class);
bind(JsonResponseProcessor.class);
bind(ObjectMapper.class).toInstance(new ObjectMapper());
bind(X509CertificateFactory.class).toInstance(new X509CertificateFactory());
bind(CertificateChainValidator.class);
bind(CertificatesConfigProxy.class);
bind(PKIXParametersProvider.class).toInstance(new PKIXParametersProvider());
bind(KeyStoreCache.class);
bind(KeyStoreLoader.class).toInstance(new KeyStoreLoader());
bind(MatchingServiceHealthCheckHandler.class);
bind(MatchingServiceHealthChecker.class);
bind(MatchingServiceConfigProxy.class);
bind(MatchingServiceHealthCheckClient.class);
bind(HealthCheckEventLogger.class);
bind(SamlEngineProxy.class);
bind(HealthCheckSoapRequestClient.class);
bind(AttributeQueryRequestRunnableFactory.class);
bind(ExecuteAttributeQueryRequest.class);
bind(AttributeQueryRequestClient.class);
bind(ProtectiveMonitoringLogger.class).toInstance(new ProtectiveMonitoringLogger());
bind(SoapRequestClient.class);
bind(HubMatchingServiceResponseReceiverProxy.class);
bind(ExternalCommunicationEventLogger.class);
bind(SoapMessageManager.class).toInstance(new SoapMessageManager());
bind(IpAddressResolver.class).toInstance(new IpAddressResolver());
bind(TimeoutEvaluator.class).toInstance(new TimeoutEvaluator());
bind(MetadataHealthCheckRegistry.class).asEagerSingleton();
}
Aggregations