mirror of
https://gitee.com/log4j/pig.git
synced 2024-12-23 05:00:23 +08:00
🎨 Improving structure / format of the code. 格式化代码
This commit is contained in:
parent
f472e701ac
commit
0f4ca191b2
@ -51,7 +51,7 @@ import java.util.Arrays;
|
|||||||
/**
|
/**
|
||||||
* @author lengleng
|
* @author lengleng
|
||||||
* @date 2022/5/27
|
* @date 2022/5/27
|
||||||
*
|
* <p>
|
||||||
* 认证服务器配置
|
* 认证服务器配置
|
||||||
*/
|
*/
|
||||||
@Configuration
|
@Configuration
|
||||||
@ -115,22 +115,17 @@ public class AuthorizationServerConfiguration {
|
|||||||
* @return DelegatingAuthenticationConverter
|
* @return DelegatingAuthenticationConverter
|
||||||
*/
|
*/
|
||||||
private AuthenticationConverter accessTokenRequestConverter() {
|
private AuthenticationConverter accessTokenRequestConverter() {
|
||||||
return new DelegatingAuthenticationConverter(Arrays.asList(
|
return new DelegatingAuthenticationConverter(
|
||||||
new OAuth2ResourceOwnerPasswordAuthenticationConverter(),
|
Arrays.asList(new OAuth2ResourceOwnerPasswordAuthenticationConverter(),
|
||||||
new OAuth2ResourceOwnerSmsAuthenticationConverter(),
|
new OAuth2ResourceOwnerSmsAuthenticationConverter(),
|
||||||
// OAuth2TokenEndpointFilter中构造的DelegatingAuthenticationConverter中已经创建了这三个,会重复调用
|
new OAuth2AuthorizationCodeRequestAuthenticationConverter()));
|
||||||
// new OAuth2RefreshTokenAuthenticationConverter(),
|
|
||||||
// new OAuth2ClientCredentialsAuthenticationConverter(),
|
|
||||||
// new OAuth2AuthorizationCodeAuthenticationConverter(),
|
|
||||||
new OAuth2AuthorizationCodeRequestAuthenticationConverter()));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 注入授权模式实现提供方
|
* 注入授权模式实现提供方
|
||||||
*
|
* <p>
|
||||||
* 1. 密码模式 </br>
|
* 1. 密码模式 </br>
|
||||||
* 2. 短信登录 </br>
|
* 2. 短信登录 </br>
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
private void addCustomOAuth2GrantAuthenticationProvider(HttpSecurity http) {
|
private void addCustomOAuth2GrantAuthenticationProvider(HttpSecurity http) {
|
||||||
|
Loading…
Reference in New Issue
Block a user