79434841

Date: 2025-02-13 01:10:02
Score: 1
Natty:
Report link

I have managed to get past the 404 error. Folowing is the confirmation.

oauth2.authUri=https://dev-xx.okta.com/oauth2/default/v1/authorize
okta.oauth2.issuer=https://dev-xx.okta.com/oauth2/default
oauth2.accessTokenUri=https://dev-xx.okta.com/oauth2/default/v1/token
oauth2.userInfoUri=https://dev-xx.okta.com/oauth2/v1/userInfo
oauth2.redirect_uri=http://localhost:8081/oauth2/authorization/okta
oauth2.clientId=xxx
oauth2.clientName=Okta
oauth2.clientSecret=xxx
oauth2.scope=openid,profile,email

Now im getting ERR_TOO_MANY_REDIRECTS enter image description here

Following is the code to create OAuth2AuthorizedClientService and OAuth2AuthorizedClientRepository

@Bean
public OAuth2AuthorizedClientRepository authorizedClientRepository( OAuth2AuthorizedClientService authorizedClientService) {
    return new AuthenticatedPrincipalOAuth2AuthorizedClientRepository(authorizedClientService);
}

@Bean
public OAuth2AuthorizedClientService authorizedClientService( ClientRegistrationRepository clientRegistrationRepository) {
    return new InMemoryOAuth2AuthorizedClientService(clientRegistrationRepository);
}
Reasons:
  • Blacklisted phrase (1): enter image description here
  • Long answer (-1):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Dimuthu A