Commit 0ea5df47 authored by 李驰骋's avatar 李驰骋

token密钥调整

parent f63922fb
......@@ -42,7 +42,7 @@ logging:
sql:
Statement: debug
file:
name: ximai-mes.log
name: logs/ximai-mes.log
# Spring配置
spring:
......@@ -122,9 +122,9 @@ spring:
servlet:
multipart:
# 单个文件大小
max-file-size: 10MB
max-file-size: 30MB
# 设置总上传的文件大小
max-request-size: 20MB
max-request-size: 30MB
# 服务模块
devtools:
restart:
......@@ -159,7 +159,7 @@ token:
# 令牌自定义标识
header: Authorization
# 令牌密钥
secret: abcdefghijklmnopqrstuvwxyz
secret: q8w3Cx9Lr4fT2y6uV5sZ8aE1mN0kP7gH
# 令牌有效期(默认30分钟)
expireTime: 1440
......
......@@ -157,7 +157,7 @@ token:
# 令牌自定义标识
header: Authorization
# 令牌密钥
secret: abcdefghijklmnopqrstuvwxyz
secret: q8w3Cx9Lr4fT2y6uV5sZ8aE1mN0kP7gH
# 令牌有效期(默认30分钟)
expireTime: 1440
......
......@@ -159,7 +159,7 @@ token:
# 令牌自定义标识
header: Authorization
# 令牌密钥
secret: abcdefghijklmnopqrstuvwxyz
secret: q8w3Cx9Lr4fT2y6uV5sZ8aE1mN0kP7gH
# 令牌有效期(默认30分钟)
expireTime: 1440
......
......@@ -56,7 +56,7 @@ spring:
druid:
# 主库数据源
master:
url: jdbc:mysql://10.168.8.188:3306/xm_mes?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&serverTimezone=Asia/Shanghai
url: jdbc:mysql://10.168.8.188:3306/xm_mes?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B7
username: root
password: t0psunit
# 从库数据源
......@@ -159,7 +159,7 @@ token:
# 令牌自定义标识
header: Authorization
# 令牌密钥
secret: abcdefghijklmnopqrstuvwxyz
secret: q8w3Cx9Lr4fT2y6uV5sZ8aE1mN0kP7gH
# 令牌有效期(默认30分钟)
expireTime: 1440
......
......@@ -159,7 +159,7 @@ token:
# 令牌自定义标识
header: Authorization
# 令牌密钥
secret: abcdefghijklmnopqrstuvwxyz
secret: q8w3Cx9Lr4fT2y6uV5sZ8aE1mN0kP7gH
# 令牌有效期(默认30分钟)
expireTime: 1440
......
......@@ -113,6 +113,7 @@ public class TokenService
Map<String, Object> claims = new HashMap<>();
claims.put(Constants.LOGIN_USER_KEY, token);
claims.put(Constants.JWT_USERNAME, loginUser.getUsername());
return createToken(claims);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment