Spring Boot Okta дает плохие учетные данныеJAVA

Программисты JAVA общаются здесь
Anonymous
Spring Boot Okta дает плохие учетные данные

Сообщение Anonymous »

Currently I'm learning Oauth in java using Okta as authorization server,
When i use the Google as authorization server, but it doesn't with okta, i can't go to the login page after clicking the link that i get from Defaultloginpagegenerating.java
image of okta setupimage of okta setupimage of okta setup
this is my Application.properties < /p>
spring.security.oauth2.client.registration.okta.client-id=0oapnifo589dgowBf5d7
spring.security.oauth2.client.registration.okta.client-secret=abc(on purpose)
spring.security.oauth2.client.registration.okta.scope=openid,profile,email
spring.security.oauth2.client.registration.okta.authorization-grant-type=authorization_code
spring.security.oauth2.client.registration.okta.redirect-uri=http://localhost:8080/login/oauth2/code/okta

spring.security.oauth2.client.provider.okta.authorization-uri=https://dev-39838129.okta.com/oauth2/de ... /authorize
spring.security.oauth2.client.provider.okta.token-uri=https://dev-39838129.okta.com/oauth2/default/v1/token
spring.security.oauth2.client.provider.okta.jwk-set-uri=https://dev-39838129.okta.com/oauth2/default/v1/keys
spring.security.oauth2.client.provider.okta.issuer-uri=https://dev-39838129.okta.com/oauth2/default
< /code>
Это конфигурация безопасности < /p>
@Bean
public SecurityFilterChain securityFilterChain (HttpSecurity http) throws Exception{

http.authorizeHttpRequests(auth ->
// auth.requestMatchers("/").permitAll()
auth .anyRequest().authenticated())
.csrf(csrf->csrf.disable())

.oauth2Login(Customizer.withDefaults())
.oauth2Client(Customizer.withDefaults());

return http.build();
}


Подробнее здесь: https://stackoverflow.com/questions/797 ... redentials

Вернуться в «JAVA»