<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
System Status
Announcements
Announcements
Search
Search
Select Language
0D54z00008IDAn5CAHOkta Classic EngineAPI Access ManagementAnswered2024-08-24T09:00:57.000Z2022-10-27T06:19:03.000Z2022-10-28T15:21:34.000Z

6o3cz (6o3cz) asked a question.

How to use organization level authorization server in OKTA with spring boot application

I am attempting to use my organization’s org level auth server to validate tokens in my Spring Boot backend. When I'm setting the okta.oauth2.issuer in my application.properties to https://{company}.oktapreview.com/oauth2, the application fails to start up with the error: Unable to resolve Configuration with the provided Issuer of “https://{company}.oktapreview.com/oauth2”.

Please refer the below error.

 

ERROR [org.springframework.boot.SpringApplication] (ServerService Thread Pool -- 136) Application run failed: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jwtDecoder' defined in class path resource [/config/OktaConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.security.oauth2.jwt.JwtDecoder]: Factory method 'jwtDecoder' threw exception; nested exception is java.lang.IllegalArgumentException: Unable to resolve the Configuration with the provided Issuer of "https://{company}.oktapreview.com/oauth2".

 

Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.security.oauth2.jwt.JwtDecoder]: Factory method 'jwtDecoder' threw exception; nested exception is java.lang.IllegalArgumentException: Unable to resolve the Configuration with the provided Issuer of "https://{company}.oktapreview.com/oauth2"

 

 


This question is closed.
Loading
How to use organization level authorization server in OKTA with spring boot application
Okta Support Agent (Beta)

Terms of Service

Hello! I'm the Okta Support Agent (Beta), your go-to resource for questions about Okta products. Please remember for your security and privacy, do not share any Personally Identifiable Information (PII) such as passwords, IP addresses, or other details with me.

Okta Privacy Policy and Terms of Service apply