spring-projects / spring-authorization-server

Spring Authorization Server
https://spring.io/projects/spring-authorization-server
Apache License 2.0
4.78k stars 1.25k forks source link

Introspection can't work #1606

Closed yanggang3390 closed 1 month ago

yanggang3390 commented 2 months ago

http.authorizeHttpRequests(authorize -> { authorize.anyRequest().authenticated(); } ) .oauth2ResourceServer(oauth2 -> oauth2 .opaqueToken(opaqueToken -> opaqueToken .introspectionUri("http://localhost:9000/introspect") .introspectionClientCredentials("platform-client", "secret"))

// .jwt(Customizer.withDefaults()) .authenticationEntryPoint(new MyAuthenticationEntryPoint()) .accessDeniedHandler(new MyAccessDeniedHandler())

            );
    return http.build();

Every correct token is a token failure

Do I need to add any configuration to the authentication server?

jgrandja commented 1 month ago

Thanks for getting in touch, but it feels like this is a question that would be better suited to Stack Overflow. We prefer to use GitHub issues only for bugs and enhancements. Feel free to update this issue with a link to the re-posted question (so that other people can find it) or add a minimal sample that reproduces this issue if you feel this is a genuine bug.