← 开源
kaplanelad

shellfirm

Safety guardrails for ai coding agents and human terminal commands

AI EngineeringTest & guardGive agent toolsRust
在 GitHub 打开
增长势头
+024 小时新增 Star0.0%
946
Star
33
Fork
+10
本周
11
贡献者
创建于 2021-12-24 · 更新于 2026-10-15 · 今日第 12467 名
主要开发者
kaplaneladIsan-Rivkindonbeave

kaplanelad/shellfirm 排名第 12,467,有 946 个星标。

同类别比较

kaplanelad/shellfirm 排名第 12,467,此处有 8 个同类条目;BaranziniLab/KG_RAG 排名第 12,464。

同类别比较
名称排名指标
Caho1/open-claude-ui12,444
语言:
TypeScript
星标数:
949
分叉数:
212
简介:
基于 REA 深度拆解并高保真还原 Claude 官方桌面端 UI。还原 30 个独立 React 组件与 8 项硬核交互物理算法,附带 3000+ 行逆向分析手册。
inngest/agent-kit12,458
语言:
TypeScript
星标数:
947
分叉数:
145
简介:
AgentKit: Build multi-agent networks in TypeScript with deterministic routing and rich tooling via MCP.
nullquant/ComfyUI-BrushNet12,460
语言:
Python
星标数:
947
分叉数:
53
简介:
ComfyUI BrushNet nodes
BaranziniLab/KG_RAG12,464
语言:
Jupyter Notebook
星标数:
946
分叉数:
115
简介:
Empower Large Language Models (LLM) using Knowledge Graph based Retrieval-Augmented Generation (KG-RAG) for knowledge intensive tasks
Pipelex/pipelex12,470
语言:
Python
星标数:
945
分叉数:
78
简介:
Build AI methods with your coding agent, then run them anywhere: as an MCP for chatbots, as a webapp for people, or via API for your software.
CopilotKit/channels-sdk12,497
星标数:
941
分叉数:
63
简介:
The open-source SDK for bringing any agent into any chat platform: Slack, Microsoft Teams, Discord, Telegram - with native, Interactive UI.
Anarkh-Lee/universal-db-mcp12,502
语言:
TypeScript
星标数:
940
分叉数:
92
简介:
通用数据库 MCP 连接器:支持 MySQL、PostgreSQL、Oracle、MongoDB 等 17 种数据库,支持 Claude Desktop、Cursor、Windsurf、VS Code、ChatGPT 等 50+ 平台,用自然语言查询和分析数据
AndersonBY/vector-vein12,503
语言:
Vue
星标数:
940
分叉数:
140
简介:
No-code AI workflow. Drag and drop workflow nodes and use your workflow with your AI agents.
关键参数与规格
关键参数与规格
参数值
语言Rust
类别AI Engineering
子类别Test & guard,Give agent tools
关键词AI safety, Guardrails, MCP, Terminal
星标数946
分叉数33
贡献者11
创建日期2021-12-24
更新日期2026-10-15
1 天星标数0
7 天星标数10
排名12,467
上次排名3,261
排名变化-9,206
7 天星标排名4,041
上次 7 天星标排名3,842
7 天星标排名变化-199
总星标排名11,639
上次总星标排名11,619
总星标排名变化-20
国家Israel
README 摘录

shellfirm intercepts dangerous shell commands before the damage is done. Install the shell hook** (auto-detects your shell): **2. Try it:** For manual setup, shell-specific instructions, and Oh My Zsh plugin, see the shell setup docs. Please open an issue or pull request on GitHub.

常见问题

记录了多少星标和分叉?

kaplanelad/shellfirm 有 946 个星标和 33 个分叉。

仓库排名是多少?

kaplanelad/shellfirm 排名第 12,467。

记录的语言和类别是什么?

kaplanelad/shellfirm 有 946 个星标,语言为 Rust,类别为 AI Engineering。

哪个仓库排名最接近?

kaplanelad/shellfirm 与 BaranziniLab/KG_RAG 比较,后者排名第 12,464,有 946 个星标。

README

shellfirm

Think before you execute.

Humans make mistakes. AI agents make them faster. shellfirm intercepts dangerous shell commands before the damage is done.

$ rm -rf ./src
============ RISKY COMMAND DETECTED ============
Severity: Critical
Blast radius: [PROJECT] — Deletes 347 files (12.4 MB) in ./src
Description: You are going to delete everything in the path.

Solve the challenge: 8 + 0 = ? (^C to cancel)
$ git push origin main --force
============ RISKY COMMAND DETECTED ============
Severity: High
Blast radius: [RESOURCE] — Force-pushes branch main (3 commits behind remote)
Description: This command will force push and overwrite remote history.
Alternative: git push --force-with-lease
  (Checks that your local ref is up-to-date before force pushing, preventing accidental overwrites of others' work.)

Solve the challenge: 3 + 5 = ? (^C to cancel)

Features

  • 100+ patterns across 9 ecosystems (filesystem, git, Kubernetes, Terraform, Docker, AWS, GCP/Azure, Heroku, databases)
  • 8 shells — Zsh, Bash, Fish, Nushell, PowerShell, Elvish, Xonsh, Oils
  • Context-aware escalation — harder challenges when connected via SSH, running as root, on protected git branches, or in production Kubernetes clusters
  • Safe alternative suggestions — actionable safer commands shown alongside every warning
  • Severity levels with configurable thresholds (Critical, High, Medium, Low, Info)
  • Project policies — share team safety rules via .shellfirm.yaml (additive-only, never weakens)
  • Audit trail — every intercepted command and decision logged as JSON-lines
  • Blast radius detection — runtime context signals feed into risk scoring
  • MCP server — expose shellfirm as an AI tool for Claude Code, Cursor, and other agents

AI Tool Integration

Claude Code

One command sets up both automatic safety (hooks) and on-demand analysis (MCP):

shellfirm connect claude-code

This adds:

  • Hooks — every Bash command is checked before execution; risky commands are blocked
  • MCP — Claude can call shellfirm tools to explain risks and suggest alternatives

MCP Tools

Tool Description
check_command Check if a command is risky — returns severity, matched rules, and alternatives
suggest_alternative Get safer replacement commands
explain_risk Detailed explanation of why a command is dangerous
get_policy Read the active shellfirm configuration and project policy

Installation

npm

npm install -g @shellfirm/cli

Homebrew

brew tap kaplanelad/tap && brew install shellfirm

Cargo

cargo install shellfirm

Or download the binary from the releases page.


Quick Start

1. Install the shell hook (auto-detects your shell):

shellfirm init

2. Restart your shell (or source your rc file).

3. Try it:

git reset --hard  # Should trigger shellfirm!

For manual setup, shell-specific instructions, and Oh My Zsh plugin, see the shell setup docs.


Documentation

Full documentation is available at shellfirm.vercel.app:


Contributing

Contributions are welcome! Please open an issue or pull request on GitHub.

License

Apache-2.0

排名相邻
同类项目