@ConditionalOnMissingBean(name = "amazonCognitoPrincipalFactory")
    @Bean
    @RefreshScope(proxyMode = ScopedProxyMode.DEFAULT)
    public PrincipalFactory amazonCognitoPrincipalFactory() {
        return PrincipalFactoryUtils.newPrincipalFactory();
    }
This is {@link CasAmazonCognitoAuthenticationAutoConfiguration}.

@author Misagh Moayyed
@since 6.0.0
support/cas-server-support-aws-cognito-authentication/src/main/java/org/apereo/cas/config/CasAmazonCognitoAuthenticationAutoConfiguration.java