'关闭IP白名单'
This commit is contained in:
parent
87e2c523c8
commit
ba407b3e09
2
.vscode/settings.json
vendored
2
.vscode/settings.json
vendored
@ -4,5 +4,5 @@
|
||||
"maven.view": "hierarchical",
|
||||
"maven.executable.path": "D:\\2515587071\\apache-maven-3.9.11\\bin\\mvn.cmd",
|
||||
"java.configuration.maven.userSettings": "D:\\2515587071\\apache-maven-3.9.11\\conf\\settings.xml",
|
||||
"java.jdt.ls.vmargs": "-XX:+UseParallelGC -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -Dsun.zip.disableMemoryMapping=true -Xmx4G -Xms100m -Xlog:disable"
|
||||
"java.jdt.ls.vmargs": "-XX:+UseParallelGC -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -Dsun.zip.disableMemoryMapping=true -Xmx8G -Xms100m -Xlog:disable"
|
||||
}
|
||||
@ -5,22 +5,22 @@ api:
|
||||
enabled: true
|
||||
maxRequests: 100 # 每个时间窗口最大请求数
|
||||
timeWindow: 60 # 时间窗口(秒)
|
||||
|
||||
|
||||
# 签名验证配置
|
||||
signature:
|
||||
enabled: true
|
||||
secretKey: ${API_SECRET_KEY:digital_credit_secret_key_2025}
|
||||
timestampTolerance: 300 # 时间戳容忍度(秒)
|
||||
|
||||
|
||||
# IP白名单配置
|
||||
ipWhitelist:
|
||||
enabled: true
|
||||
allowedIps: >
|
||||
127.0.0.1,
|
||||
::1,
|
||||
192.168.1.0/24,
|
||||
10.0.0.0/8,
|
||||
172.16.0.0/12
|
||||
enabled: false
|
||||
# allowedIps: >
|
||||
# 127.0.0.1,
|
||||
# ::1,
|
||||
# 192.168.1.0/24,
|
||||
# 10.0.0.0/8,
|
||||
# 172.16.0.0/12
|
||||
|
||||
# 日志配置
|
||||
logging:
|
||||
@ -36,14 +36,14 @@ spring:
|
||||
security:
|
||||
# HTTPS配置
|
||||
require-ssl: false # 开发环境设为false,生产环境应设为true
|
||||
|
||||
|
||||
# 会话配置
|
||||
sessions:
|
||||
creation-policy: stateless # 无状态会话
|
||||
|
||||
|
||||
# CORS配置
|
||||
cors:
|
||||
allowed-origins:
|
||||
allowed-origins:
|
||||
- "https://localhost:3000"
|
||||
- "https://127.0.0.1:3000"
|
||||
allowed-methods:
|
||||
@ -71,4 +71,4 @@ management:
|
||||
prometheus:
|
||||
enabled: true
|
||||
tags:
|
||||
application: digital-credit-service
|
||||
application: digital-credit-service
|
||||
|
||||
Loading…
Reference in New Issue
Block a user