mirror of
https://github.com/mangooer/mysql-mcp-server-sse.git
synced 2025-12-08 09:42:27 +08:00
<feat> 添加数据库隔离功能,支持跨数据库访问限制,更新配置和文档说明,增强安全性
This commit is contained in:
10
example.env
10
example.env
@ -46,6 +46,16 @@ BLOCKED_PATTERNS=
|
||||
# 是否启用查询安全检查
|
||||
ENABLE_QUERY_CHECK=true
|
||||
|
||||
# 数据库隔离配置
|
||||
# 是否启用数据库隔离(防止跨数据库访问)
|
||||
ENABLE_DATABASE_ISOLATION=false
|
||||
# 数据库访问级别: strict(严格), restricted(限制), permissive(宽松)
|
||||
# - strict: 只能访问指定的数据库
|
||||
# - restricted: 可以访问指定数据库和系统库(information_schema, mysql等)
|
||||
# - permissive: 可以访问所有数据库(默认)
|
||||
# 注意:生产环境(ENV_TYPE=production)会自动启用数据库隔离并设为restricted模式
|
||||
DATABASE_ACCESS_LEVEL=permissive
|
||||
|
||||
# 日志配置
|
||||
# DEBUG, INFO, WARNING, ERROR, CRITICAL
|
||||
LOG_LEVEL=DEBUG
|
||||
Reference in New Issue
Block a user