Auth0 Home Blog Docs

Spring Boot - User details not being called

Hi There,

I’m currently using the Auth0 spring security framework in order to secure my WebApp.
It work quite well but I have an issue.

The userDetailService is not called and I don’t know why.

My configuration class is like this:

    @Override
protected void configure(HttpSecurity http) throws Exception {
    JwtWebSecurityConfigurer
            .forRS256(audience, issuer)
            .configure(http)
            .csrf().disable()
            .userDetailsService(new MyUserDetailsService())
            .authorizeRequests()
            .antMatchers("/api/**").authenticated()
            .antMatchers("/token").authenticated();
}

The MyUserDetailsService.loadUserByUsername is still ignore and I don’t know how to load the user entity from the database.

I found a post here: https://stackoverflow.com/questions/51062836
And I wonder if the same issue still exists.

Hey there @charles.bourasseau!

Unfortunately I don’t have enough Java experience to help you with that but I think it’s a good idea to go to the GitHub repo and raise and issue there so someone will be able to help you more quickly!