This issue is the result of the problem discussed here https://github.com/spring-projects/spring-security/issues/7883
To use OpaqueTokenIntrospection
, which is an optional feature, it is necessary to add com.nimbusds:oauth2-oidc-sdk
as dependency. However, that dependency is not managed by spring-boot-dependencies
which is unexpected, normally optional dependencies are still managed.
There seems to have been a preview issue #14137, which was closed but oauth2-oidc-sdk
is still not managed, I can't really tell what the resolution of that issue was.
Furthermore, it was quite confusing getting OpaqueTokenIntrospection
to work, since there were a number of optional dependencies that were necessary and it was not really apparent which those were. A dedicated spring-boot-starter-oauth2-opaque-token
might be helpful.
Comment From: wilkinsona
For our future reference, we've never had dependency management for oauth2-oidc-sdk. #14137 addressed a duplicate JavaMail dependency problem that was coming in transitively from oauth2-oidc-sdk via Spring Security's OAuth client module.