mirror of
https://gitee.com/log4j/pig.git
synced 2024-12-22 12:48:58 +08:00
🔖 Releasing / Version tags. 3.7.4
This commit is contained in:
parent
6c2c989e42
commit
9e2f1aaba5
@ -23,6 +23,7 @@ public class GatewayConfiguration {
|
||||
|
||||
/**
|
||||
* 创建密码解码器过滤器
|
||||
*
|
||||
* @param modifyRequestBodyGatewayFilterFactory 修改请求体网关过滤器工厂
|
||||
* @param configProperties 配置属性
|
||||
* @return 密码解码器过滤器
|
||||
@ -36,6 +37,7 @@ public class GatewayConfiguration {
|
||||
|
||||
/**
|
||||
* 创建PigRequest全局过滤器
|
||||
*
|
||||
* @return PigRequest全局过滤器
|
||||
*/
|
||||
@Bean
|
||||
@ -45,19 +47,19 @@ public class GatewayConfiguration {
|
||||
|
||||
/**
|
||||
* 创建验证码网关过滤器
|
||||
*
|
||||
* @param configProperties 配置属性
|
||||
* @param objectMapper 对象映射器
|
||||
* @param redisTemplate Redis模板
|
||||
* @return 验证码网关过滤器
|
||||
*/
|
||||
@Bean
|
||||
public ValidateCodeGatewayFilter validateCodeGatewayFilter(GatewayConfigProperties configProperties,
|
||||
ObjectMapper objectMapper, RedisTemplate redisTemplate) {
|
||||
return new ValidateCodeGatewayFilter(configProperties, objectMapper, redisTemplate);
|
||||
public ValidateCodeGatewayFilter validateCodeGatewayFilter(GatewayConfigProperties configProperties, RedisTemplate redisTemplate) {
|
||||
return new ValidateCodeGatewayFilter(configProperties, redisTemplate);
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建全局异常处理程序
|
||||
*
|
||||
* @param objectMapper 对象映射器
|
||||
* @return 全局异常处理程序
|
||||
*/
|
||||
@ -68,6 +70,7 @@ public class GatewayConfiguration {
|
||||
|
||||
/**
|
||||
* 创建图片验证码处理器
|
||||
*
|
||||
* @param redisTemplate Redis模板
|
||||
* @return 图片验证码处理器
|
||||
*/
|
||||
|
@ -54,8 +54,6 @@ public class ValidateCodeGatewayFilter extends AbstractGatewayFilterFactory<Obje
|
||||
|
||||
private final GatewayConfigProperties configProperties;
|
||||
|
||||
private final ObjectMapper objectMapper;
|
||||
|
||||
private final RedisTemplate<String, Object> redisTemplate;
|
||||
|
||||
/**
|
||||
@ -89,7 +87,7 @@ public class ValidateCodeGatewayFilter extends AbstractGatewayFilterFactory<Obje
|
||||
CharsetUtil.CHARSET_UTF_8);
|
||||
// 刷新请求跳过,直接向下执行
|
||||
if (StrUtil.equals(SecurityConstants.REFRESH_TOKEN, requestBodyMap.get("grant_type"))) {
|
||||
return chain.filter(exchange);
|
||||
return chain.filter(exchange.mutate().request(serverHttpRequest).build());
|
||||
}
|
||||
|
||||
// 根据 randomStr 参数判断验证码是否正常
|
||||
|
Loading…
Reference in New Issue
Block a user