Search in sources :

Example 96 with RefreshScope

use of org.springframework.cloud.context.config.annotation.RefreshScope in project cas by apereo.

the class CoreWsSecuritySecurityTokenServiceConfiguration method transportValidateDelegate.

@RefreshScope
@Bean
public ValidateOperation transportValidateDelegate() {
    final TokenValidateOperation op = new TokenValidateOperation();
    op.setTokenValidators(transportTokenValidators());
    op.setStsProperties(transportSTSProperties());
    op.setEventListener(loggerListener());
    return op;
}
Also used : TokenValidateOperation(org.apache.cxf.sts.operation.TokenValidateOperation) RefreshScope(org.springframework.cloud.context.config.annotation.RefreshScope) ConditionalOnMissingBean(org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean) STSPropertiesMBean(org.apache.cxf.sts.STSPropertiesMBean) ServletRegistrationBean(org.springframework.boot.web.servlet.ServletRegistrationBean) Bean(org.springframework.context.annotation.Bean)

Example 97 with RefreshScope

use of org.springframework.cloud.context.config.annotation.RefreshScope in project cas by apereo.

the class TrustedAuthenticationConfiguration method trustedPrincipalResolver.

@Bean
@RefreshScope
public PrincipalResolver trustedPrincipalResolver() {
    final PrincipalBearingPrincipalResolver r = new PrincipalBearingPrincipalResolver();
    r.setAttributeRepository(this.attributeRepository);
    r.setPrincipalAttributeName(casProperties.getAuthn().getTrusted().getPrincipalAttribute());
    r.setReturnNullIfNoAttributes(casProperties.getAuthn().getTrusted().isReturnNull());
    r.setPrincipalFactory(trustedPrincipalFactory());
    return r;
}
Also used : PrincipalBearingPrincipalResolver(org.apereo.cas.adaptors.trusted.authentication.principal.PrincipalBearingPrincipalResolver) RefreshScope(org.springframework.cloud.context.config.annotation.RefreshScope) ConditionalOnMissingBean(org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean) Bean(org.springframework.context.annotation.Bean)

Aggregations

RefreshScope (org.springframework.cloud.context.config.annotation.RefreshScope)97 Bean (org.springframework.context.annotation.Bean)97 ConditionalOnMissingBean (org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean)68 STSPropertiesMBean (org.apache.cxf.sts.STSPropertiesMBean)11 ServletRegistrationBean (org.springframework.boot.web.servlet.ServletRegistrationBean)11 ArrayList (java.util.ArrayList)10 Autowired (org.springframework.beans.factory.annotation.Autowired)6 CipherBean (org.cryptacular.bean.CipherBean)5 MultifactorAuthenticationProperties (org.apereo.cas.configuration.model.support.mfa.MultifactorAuthenticationProperties)4 SpnegoProperties (org.apereo.cas.configuration.model.support.spnego.SpnegoProperties)4 WsFederationProperties (org.apereo.cas.configuration.model.support.wsfed.WsFederationProperties)4 X509Properties (org.apereo.cas.configuration.model.support.x509.X509Properties)4 IPersonAttributeDao (org.apereo.services.persondir.IPersonAttributeDao)4 HashMap (java.util.HashMap)3 List (java.util.List)3 Properties (java.util.Properties)3 CasConfigurationProperties (org.apereo.cas.configuration.CasConfigurationProperties)3 ConnectionFactory (org.ldaptive.ConnectionFactory)3 EnableConfigurationProperties (org.springframework.boot.context.properties.EnableConfigurationProperties)3 FilterRegistrationBean (org.springframework.boot.web.servlet.FilterRegistrationBean)3