Example usage for org.springframework.security.cas.userdetails AbstractCasAssertionUserDetailsService AbstractCasAssertionUserDetailsService

List of usage examples for org.springframework.security.cas.userdetails AbstractCasAssertionUserDetailsService AbstractCasAssertionUserDetailsService

Introduction

In this page you can find the example usage for org.springframework.security.cas.userdetails AbstractCasAssertionUserDetailsService AbstractCasAssertionUserDetailsService.

Prototype

AbstractCasAssertionUserDetailsService

Source Link

Usage

From source file:org.ambraproject.wombat.config.SpringSecurityConfiguration.java

private AuthenticationUserDetailsService authenticationUserDetailsService() {
    return new AbstractCasAssertionUserDetailsService() {
        @Override/*from   w  ww.  j a  v  a 2 s . c  o  m*/
        protected UserDetails loadUserDetails(Assertion assertion) {
            final List<GrantedAuthority> grantedAuthorities = new ArrayList<>();
            return new User(assertion.getPrincipal().getName(), "NO_PASSWORD", true, true, true, true,
                    grantedAuthorities);
        }
    };
}