use of keywhiz.auth.cookie.CookieModule in project keywhiz by square.
the class ServiceModule method configure.
@Override
protected void configure() {
// Initialize the BouncyCastle security provider for cryptography support.
BouncyCastle.require();
bind(Clock.class).toInstance(Clock.systemUTC());
install(new CookieModule(config.getCookieKey()));
install(new CryptoModule(config.getDerivationProviderClass(), config.getContentKeyStore()));
bind(CookieConfig.class).annotatedWith(SessionCookie.class).toInstance(config.getSessionCookieConfig());
bind(CookieConfig.class).annotatedWith(Xsrf.class).toInstance(config.getXsrfCookieConfig());
// TODO(justin): Consider https://github.com/HubSpot/dropwizard-guice.
bind(Environment.class).toInstance(environment);
bind(Configuration.class).toInstance(config);
bind(KeywhizConfig.class).toInstance(config);
}
Aggregations