use of org.apereo.cas.adaptors.x509.authentication.principal.X509SubjectAlternativeNameUPNPrincipalResolver in project cas by apereo.
the class X509AuthenticationConfiguration method x509SubjectAlternativeNameUPNPrincipalResolver.
@Bean
@RefreshScope
public PrincipalResolver x509SubjectAlternativeNameUPNPrincipalResolver() {
final X509Properties x509 = casProperties.getAuthn().getX509();
final X509SubjectAlternativeNameUPNPrincipalResolver r = new X509SubjectAlternativeNameUPNPrincipalResolver();
r.setAttributeRepository(attributeRepository);
r.setPrincipalAttributeName(x509.getPrincipal().getPrincipalAttribute());
r.setReturnNullIfNoAttributes(x509.getPrincipal().isReturnNull());
r.setPrincipalFactory(x509PrincipalFactory());
return r;
}
Aggregations