haymon-ai/dbmcp
隐私优先的 SQL 数据库 MCP 服务器,默认脱敏敏感数据
解决什么问题
没有它,AI 客户端会直接看到查询结果中的邮箱、电话、银行卡号、身份证号和 API 密钥等敏感值。
- 查询结果默认脱敏
- 内置48类数据检测
- 列规则跟随数据
适用客户端
- claude-desktop
- cursor
- vscode
- windsurf
- cli
安装命令
npx @modelcontextprotocol/inspector ./target/release/dbmcp npx -y @haymon-ai/dbmcp 一键配置
{
"mcpServers": {
"dbmcp": {
"command": "dbmcp",
"env": {
"DBMCP_DB_BACKEND": "mysql",
"DBMCP_DB_HOST": "127.0.0.1",
"DBMCP_DB_PORT": "3306",
"DBMCP_DB_USER": "root",
"DBMCP_DB_PASSWORD": "secret",
"DBMCP_DB_NAME": "mydb"
}
}
}
} {
"mcpServers": {
"dbmcp": {
"type": "http",
"url": "http://127.0.0.1:9001/mcp"
}
}
} {
"mcpServers": {
"dbmcp": {
"type": "http",
"url": "http://127.0.0.1:9001/mcp",
"headers": {
"Authorization": "Bearer ${DBMCP_TOKEN}"
}
}
}
} 安全标记
- 需要 API Key: 未标注
- 本地运行: 是
- 访问网络: 是
- 需要 root: 否
维护状态
| 最近提交 | 2026-12-05(0d) |
|---|---|
| Star | 33 |
| 待处理 issue | 13 |
| 协议 | MIT |
| 已归档 | 否 |
| 数据抓取于 | 2026-12-05 |
原文摘录
以下为仓库 README 原文,未做改写,用于核对上面的摘要。
Out of the box, dbmcp redacts e-mail addresses, phone numbers, bank and card numbers, national IDs, API keys, and other pattern-detected values inside the server, so the AI client never sees them.