manthanghasadiya/Broude

GitHub: manthanghasadiya/Broude

一套 Claude Code hooks,在 AI 编程助手与终端之间充当安全审计层,拦截供应链攻击、暴露密钥和混淆命令。

Stars: 0 | Forks: 0

# Broude 你的 AI 编程助手的安全卫士。 [![CI](https://static.pigsec.cn/wp-content/uploads/repos/cas/ad/ad5834178f7599af9fdda11629d49cae07f2997beec49821b2920eff5bfd50e7.svg)](https://github.com/manthanghasadiya/Broude/actions/workflows/ci.yml) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) ![Bash 4.0+](https://img.shields.io/badge/bash-4.0%2B-green) ## 什么是 Broude? Broude 是一套 Claude Code hooks,能够在供应链攻击、暴露的密钥和混淆的 bash 命令进入你的终端之前将其拦截。你可以将其视为位于 AI 编程助手和你的 shell 之间的基于签名的安全层。 ## 为什么需要它? 近年来,针对开发者的供应链攻击激增。2026 年 6 月,恶意的 JetBrains 插件、流氓 Chrome 扩展以及像 Mastra 这样被入侵的 npm 包被专门设计用来窃取开发者凭证并破坏 AI agent。Broude 通过在 AI 会话期间审计你的环境来保护你。 ## 快速开始 ``` curl -fsSL https://raw.githubusercontent.com/manthanghasadiya/Broude/main/install.sh | bash ``` ## 检查内容 Broude 会执行全面的会话审计,检查暴露的密钥、npm/pip 依赖、恶意的 JetBrains 插件、可疑的 Chrome 扩展以及 git hooks。未来即将推出的功能还包括:执行前拦截(针对恶意包安装、pipe-to-shell 模式和 GuardFall 混淆)和执行后扫描(用于检测写入文件中的密钥并维护审计追踪)。 ## 示例输出 ``` === BROUDE v1.0.0: Session Security Audit === Project: /path/to/project [PASS] No secrets detected in project files (10 files scanned) [PASS] .env is in .gitignore [PASS] npm audit: no vulnerabilities found [INFO] pip-audit skipped (no requirements.txt) [PASS] JetBrains plugins look clean [WARN] Found extensions matching known threats (PromptSnatcher variants): 'Chrome extension 1' Risk: MEDIUM (4 PASS, 1 WARN, 0 FAIL) Action: Address WARN items before committing. ========================================== ``` ## 环境要求 - bash 4.0+ - jq - Claude Code - 可选:npm(用于依赖审计),pip-audit(用于 Python 审计) ## 配置 通过 `~/.broude/settings.json`(或项目本地配置)自定义 Broude,以绕过特定检查、添加自定义密钥匹配规则或切换特定规则。 ## 路线图 - [v1.0](https://github.com/manthanghasadiya/Broude/issues/1):会话审计(当前版本) - [v1.1](https://github.com/manthanghasadiya/Broude/issues/2):执行前拦截 - [v1.2](https://github.com/manthanghasadiya/Broude/issues/3):执行后扫描 - [v1.3](https://github.com/manthanghasadiya/Broude/issues/4):MCP server 集成 (mcpsec) - [v1.4](https://github.com/manthanghasadiya/Broude/issues/5):AI 驱动的分析 ## 作者 Manthan Ghasadiya (@manthanghasadiya) 由 mcpsec 的创建者及 MCP server 中的 3 个已发布 CVE 的作者构建。 ## 许可证 MIT
标签:AI编程助手, CI/CD与钩子, DNS 反向解析, StruQ, 前端框架, 应用安全, 文档安全, 暗色界面, 机密检测, 软件供应链安全, 远程方法调用