Browse Source

Merge branch 'develop' of gitadmin/tuoheng_oidc into release

tags/v2.3.0
gitadmin 1 year ago
parent
commit
698314e556
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      tuoheng_oidc_server/src/main/java/com/tuoheng/config/SecurityConfig.java

+ 2
- 1
tuoheng_oidc_server/src/main/java/com/tuoheng/config/SecurityConfig.java View File

package com.tuoheng.config; package com.tuoheng.config;


import com.tuoheng.handler.AuthenticationEntryPoint;
import com.tuoheng.oauth2.authentication.OAuth2ResourceOwnerPasswordAuthenticationConverter; import com.tuoheng.oauth2.authentication.OAuth2ResourceOwnerPasswordAuthenticationConverter;
import com.tuoheng.handler.AccessDeniedHandler; import com.tuoheng.handler.AccessDeniedHandler;
import com.tuoheng.mapper.UserMapper; import com.tuoheng.mapper.UserMapper;
.and() .and()
.oauth2ResourceServer(OAuth2ResourceServerConfigurer::jwt) .oauth2ResourceServer(OAuth2ResourceServerConfigurer::jwt)
.exceptionHandling(exceptions -> exceptions .exceptionHandling(exceptions -> exceptions
.authenticationEntryPoint(new LoginUrlAuthenticationEntryPoint("/toLogin"))
.authenticationEntryPoint(new AuthenticationEntryPoint())
.accessDeniedHandler(new AccessDeniedHandler())) .accessDeniedHandler(new AccessDeniedHandler()))
//.authenticationEntryPoint(new AuthenticationEntryPoint())) //.authenticationEntryPoint(new AuthenticationEntryPoint()))
.apply(authorizationServerConfigurer); .apply(authorizationServerConfigurer);

Loading…
Cancel
Save