use of org.apereo.cas.pm.PasswordResetTokenCipherExecutor in project cas by apereo.
the class PasswordManagementConfiguration method passwordManagementCipherExecutor.
@ConditionalOnMissingBean(name = "passwordManagementCipherExecutor")
@RefreshScope
@Bean
public CipherExecutor passwordManagementCipherExecutor() {
final PasswordManagementProperties pm = casProperties.getAuthn().getPm();
final EncryptionJwtSigningJwtCryptographyProperties crypto = pm.getReset().getCrypto();
if (pm.isEnabled() && crypto.isEnabled()) {
return new PasswordResetTokenCipherExecutor(crypto.getEncryption().getKey(), crypto.getSigning().getKey(), crypto.getAlg());
}
return CipherExecutor.noOp();
}
Aggregations