用户登录问题修改
This commit is contained in:
parent
d76808d79c
commit
7fae2c4bff
|
|
@ -4,7 +4,6 @@ import com.bonus.common.core.exception.CaptchaException;
|
||||||
import com.bonus.common.core.utils.encryption.Sm3Util;
|
import com.bonus.common.core.utils.encryption.Sm3Util;
|
||||||
import com.bonus.common.core.utils.encryption.Sm4Utils;
|
import com.bonus.common.core.utils.encryption.Sm4Utils;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.springframework.beans.factory.annotation.Value;
|
|
||||||
import org.springframework.cloud.gateway.filter.GatewayFilterChain;
|
import org.springframework.cloud.gateway.filter.GatewayFilterChain;
|
||||||
import org.springframework.cloud.gateway.filter.GlobalFilter;
|
import org.springframework.cloud.gateway.filter.GlobalFilter;
|
||||||
import org.springframework.core.Ordered;
|
import org.springframework.core.Ordered;
|
||||||
|
|
@ -43,33 +42,6 @@ import java.util.stream.Collectors;
|
||||||
@Component
|
@Component
|
||||||
@Slf4j
|
@Slf4j
|
||||||
public class RequestCoverFilter implements GlobalFilter, Ordered {
|
public class RequestCoverFilter implements GlobalFilter, Ordered {
|
||||||
/**
|
|
||||||
* 密钥算法
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.keyAlgorithm}")
|
|
||||||
public String keyAlgorithm;
|
|
||||||
/**
|
|
||||||
* 加密/解密算法 / 工作模式 / 填充方式
|
|
||||||
* Java 6支持PKCS5Padding填充方式
|
|
||||||
* Bouncy Castle支持PKCS7Padding填充方式
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.cipherAlgorithm}")
|
|
||||||
public String cipherAlgorithm;
|
|
||||||
/**
|
|
||||||
* 偏移量,只有CBC模式才需要
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.ivParameter}")
|
|
||||||
public String ivParameter;
|
|
||||||
/**
|
|
||||||
* AES要求密钥长度为128位或192位或256位,java默认限制AES密钥长度最多128位
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.sKey}")
|
|
||||||
public String sKey;
|
|
||||||
/**
|
|
||||||
* 编码格式导出
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.encoding}")
|
|
||||||
public String encoding;
|
|
||||||
|
|
||||||
/* *//**
|
/* *//**
|
||||||
* 是否启用解密功能
|
* 是否启用解密功能
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,6 @@ package com.bonus.gateway.filter;
|
||||||
import com.bonus.common.core.utils.encryption.Sm4Utils;
|
import com.bonus.common.core.utils.encryption.Sm4Utils;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.reactivestreams.Publisher;
|
import org.reactivestreams.Publisher;
|
||||||
import org.springframework.beans.factory.annotation.Value;
|
|
||||||
import org.springframework.cloud.gateway.filter.GatewayFilterChain;
|
import org.springframework.cloud.gateway.filter.GatewayFilterChain;
|
||||||
import org.springframework.cloud.gateway.filter.GlobalFilter;
|
import org.springframework.cloud.gateway.filter.GlobalFilter;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
|
@ -32,34 +31,6 @@ import java.nio.charset.StandardCharsets;
|
||||||
@Configuration
|
@Configuration
|
||||||
@Slf4j
|
@Slf4j
|
||||||
public class ResponseEncryptFilter implements GlobalFilter, Ordered {
|
public class ResponseEncryptFilter implements GlobalFilter, Ordered {
|
||||||
/**
|
|
||||||
* 密钥算法
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.keyAlgorithm}")
|
|
||||||
public String keyAlgorithm;
|
|
||||||
/**
|
|
||||||
* 加密/解密算法 / 工作模式 / 填充方式
|
|
||||||
* Java 6支持PKCS5Padding填充方式
|
|
||||||
* Bouncy Castle支持PKCS7Padding填充方式
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.cipherAlgorithm}")
|
|
||||||
public String cipherAlgorithm;
|
|
||||||
/**
|
|
||||||
* 偏移量,只有CBC模式才需要
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.ivParameter}")
|
|
||||||
public String ivParameter;
|
|
||||||
/**
|
|
||||||
* AES要求密钥长度为128位或192位或256位,java默认限制AES密钥长度最多128位
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.sKey}")
|
|
||||||
public String sKey;
|
|
||||||
/**
|
|
||||||
* 编码格式导出
|
|
||||||
*/
|
|
||||||
@Value("${aesCbc.encoding}")
|
|
||||||
public String encoding;
|
|
||||||
|
|
||||||
/* *//**
|
/* *//**
|
||||||
* 返回数据是否加密
|
* 返回数据是否加密
|
||||||
*//*
|
*//*
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue