tirith

分类: 工具与效率 | 上传者: sheeki03sheeki03 | 下载: 0 | 版本: v1.0(最新)

shell环境的终端安全分析。在执行前检查命令是否存在供应链攻击、扫描存储库是否存在隐藏内容或配置中毒、对 URL 进行同形异义攻击评分、为 Claude Code/Cursor/Codex/Windsurf 设置 AI 工具保护、安全下载和执行脚本、调查 tirith 阻止命令的原因、管理可信模式、运行安全审计、配置 MCP 网关代理或使用威胁情报数据库时,应使用此技能。当用户提及“tirith”、“pipe-to-shell”、“同形异义词”、“ANSI 注入”、“零宽度”、“punycode”、“终端安全”、“shell hook”、“伪装检测”、“供应链攻击”、“bidi 覆盖”、“不可见的 unicode”或“配置中毒”时也可使用。 即使用户没有明确命名 tirith,当他们询问保护 shell 环境、拦截危险命令或强化 AI 代理工具执行时,也可以使用此技能。 --- # tirith — 开发人员环境的终端安全 tirith 拦截 shell 命令和粘贴文本,在执行之前检测供应链攻击。它捕获管道到外壳模式、同形异义域(西里尔文/希腊语相似)、ANSI 终端注入、双向文本覆盖、零宽度字符、缩短的 URL、punycode 技巧和配置中毒。它作为用于实时保护的 shell 挂钩运行,并作为用于扫描、评分、审核和 AI 代理安全的独立 CLI 运行。 ## 快速入门 ```bash # 安装 shell 钩子 (zsh/bash/fish/powershell/nushell) eval "$(tirith init --shell zsh)" # zsh eval "$(tirith init --shell bash)" # bash tirith init --shell Fish |来源#fish tirith init --shell nushell | source # nushell # 在运行命令之前检查命令 tirith check -- 'curl https://example.com/install.sh | bash' # 验证安装健康 tiith doctor ``` ## 检测规则

更新日志: Source: GitHub https://github.com/sheeki03/tirith

目录结构

当前层级: tree/main/

  • 📁 .cargo/
    • 📄 audit.toml 283 B
  • 📁 .claude/
    • 📁 hooks/
      • 📄 tirith-check.py 8.0 KB
    • 📄 settings.json 307 B
  • 📁 .cursor/
    • 📄 mcp.json 292 B
  • 📁 .github/
    • 📁 ISSUE_TEMPLATE/
      • 📄 dogfood-report.md 732 B
    • 📁 workflows/
      • 📄 bench.yml 942 B
      • 📄 ci.yml 2.7 KB
      • 📄 fuzz.yml 1.0 KB
      • 📄 release.yml 27.8 KB
      • 📄 threatdb.yml 4.2 KB
    • 📄 FUNDING.yml 17 B
  • 📁 assets/
    • 📄 cover.png 4.5 MB
  • 📁 crates/
    • 📁 tirith/
      • 📁 assets/
        • 📁 configs/
          • 📄 tirith-gateway.yaml 2.8 KB
        • 📁 data/
          • 📄 popular_packages.csv 2.2 KB
        • 📁 hooks/
          • 📄 copilot-cli-hook.py 7.4 KB
          • 📄 cursor-hook.sh 4.7 KB
          • 📄 kiro-hook.py 6.7 KB
          • 📄 openclaw-tirith-guard.ts 5.1 KB
          • 📄 tirith-check.py 8.0 KB
          • 📄 tirith-guard.ts 5.2 KB
          • 📄 tirith-security-guard-gemini.py 6.8 KB
          • 📄 vscode-hook.sh 5.3 KB
          • 📄 windsurf-hook.sh 3.2 KB
          • 📄 zshenv-guard.zsh 1.8 KB
        • 📁 keys/
          • 📄 threatdb-verify.pub 32 B
        • 📁 shell/
          • 📁 lib/
            • 📄 bash-hook.bash 33.2 KB
            • 📄 fish-hook.fish 11.5 KB
            • 📄 nushell-hook.nu 1.8 KB
            • 📄 powershell-hook.ps1 12.3 KB
            • 📄 zsh-hook.zsh 8.9 KB
          • 📄 tirith.sh 984 B
      • 📁 src/
        • 📁 bin/
          • 📄 tirith_threatdb_compile.rs 46.5 KB
        • 📁 cli/
          • 📁 setup/
            • 📄 fs_helpers.rs 19.2 KB
            • 📄 fs_helpers_windows.rs 10.9 KB
            • 📄 merge.rs 50.4 KB
            • 📄 mod.rs 21.5 KB
            • 📄 shell_profile.rs 17.6 KB
            • 📄 tools.rs 48.7 KB
            • 📄 zshenv.rs 21.9 KB
          • 📄 audit.rs 8.4 KB
          • 📄 check.rs 13.3 KB
          • 📄 checkpoint.rs 6.7 KB
          • 📄 completions.rs 224 B
          • 📄 daemon.rs 25.2 KB
          • 📄 diff.rs 4.0 KB
          • 📄 doctor.rs 47.2 KB
          • 📄 explain.rs 3.8 KB
          • 📄 fetch.rs 1.9 KB
          • 📄 gateway.rs 73.1 KB
          • 📄 hook_event.rs 467 B
          • 📄 init.rs 12.9 KB
          • 📄 last_trigger.rs 5.1 KB
          • 📄 license_cmd.rs 8.6 KB
          • 📄 manpage.rs 323 B
          • 📄 mcp_server.rs 269 B
          • 📄 mod.rs 16.0 KB
          • 📄 paste.rs 3.3 KB
          • 📄 policy.rs 12.9 KB
          • 📄 receipt.rs 3.6 KB
          • 📄 run.rs 1.6 KB
          • 📄 scan.rs 12.6 KB
          • 📄 score.rs 2.6 KB
          • 📄 test_harness.rs 3.3 KB
          • 📄 threatdb_cmd.rs 68.7 KB
          • 📄 trust.rs 26.8 KB
          • 📄 warnings.rs 15.4 KB
          • 📄 why.rs 1.9 KB
        • 📄 assets.rs 2.4 KB
        • 📄 main.rs 38.0 KB
      • 📁 tests/
        • 📄 bash_hook_exports.rs 8.7 KB
        • 📄 bash_preexec_enforce.rs 21.2 KB
        • 📄 cli_integration.rs 53.9 KB
        • 📄 help_snapshots.rs 9.9 KB
      • 📄 Cargo.toml 2.5 KB
    • 📁 tirith-core/
      • 📁 assets/
        • 📁 data/
          • 📄 confusables.txt 2.1 KB
          • 📄 credential_patterns.toml 4.3 KB
          • 📄 known_domains.csv 3.2 KB
          • 📄 ocr_confusions.tsv 916 B
          • 📄 popular_repos.csv 466 B
          • 📄 public_suffix_list.dat 1.5 KB
          • 📄 rule_explanations.toml 74.1 KB
          • 📄 text_confusables.txt 5.3 KB
        • 📁 keys/
          • 📄 threatdb-verify.pub 32 B
      • 📁 benches/
        • 📄 perf.rs 4.9 KB
      • 📁 src/
        • 📁 mcp/
          • 📄 dispatcher.rs 22.4 KB
          • 📄 mod.rs 69 B
          • 📄 resources.rs 5.3 KB
          • 📄 tools.rs 25.0 KB
          • 📄 types.rs 3.7 KB
        • 📁 network/
          • 📄 dns.rs 3.5 KB
          • 📄 mod.rs 107 B
          • 📄 shorturl.rs 6.5 KB
        • 📁 rules/
          • 📄 cloaking.rs 14.8 KB
          • 📄 codefile.rs 42.8 KB
          • 📄 command.rs 126.9 KB
          • 📄 configfile.rs 58.8 KB
          • 📄 credential.rs 41.4 KB
          • 📄 custom.rs 5.4 KB
          • 📄 ecosystem.rs 7.7 KB
          • 📄 environment.rs 2.7 KB
          • 📄 hostname.rs 14.4 KB
          • 📄 mod.rs 273 B
          • 📄 path.rs 3.8 KB
          • 📄 rendered.rs 39.2 KB
          • 📄 shared.rs 428 B
          • 📄 terminal.rs 26.4 KB
          • 📄 threatintel.rs 43.8 KB
          • 📄 transport.rs 5.4 KB
        • 📄 approval.rs 18.9 KB
        • 📄 audit.rs 17.2 KB
        • 📄 audit_aggregator.rs 27.5 KB
        • 📄 audit_upload.rs 9.5 KB
        • 📄 checkpoint.rs 27.4 KB
        • 📄 confusables.rs 1.6 KB
        • 📄 data.rs 2.6 KB
        • 📄 engine.rs 59.2 KB
        • 📄 escalation.rs 35.6 KB
        • 📄 extract.rs 75.9 KB
        • 📄 homoglyph.rs 6.9 KB
        • 📄 lib.rs 1.1 KB
        • 📄 license.rs 46.3 KB
        • 📄 normalize.rs 7.0 KB
        • 📄 output.rs 12.9 KB
        • 📄 parse.rs 16.8 KB
        • 📄 policy.rs 31.9 KB
        • 📄 policy_client.rs 3.4 KB
        • 📄 policy_validate.rs 21.1 KB
        • 📄 receipt.rs 8.0 KB
        • 📄 redact.rs 16.9 KB
        • 📄 rule_explanations.rs 4.4 KB
        • 📄 rule_metadata.rs 8.6 KB
        • 📄 runner.rs 12.0 KB
        • 📄 sarif.rs 12.2 KB
        • 📄 scan.rs 23.7 KB
        • 📄 script_analysis.rs 3.7 KB
        • 📄 session.rs 11.3 KB
        • 📄 session_warnings.rs 28.0 KB
        • 📄 style.rs 3.3 KB
        • 📄 text_confusables.rs 1.9 KB
        • 📄 threatdb.rs 83.8 KB
        • 📄 threatdb_api.rs 24.2 KB
        • 📄 threatdb_feeds.rs 9.7 KB
        • 📄 tokenize.rs 31.4 KB
        • 📄 url_validate.rs 17.5 KB
        • 📄 util.rs 1.3 KB
        • 📄 verdict.rs 14.8 KB
        • 📄 webhook.rs 18.5 KB
      • 📁 tests/
        • 📄 bypass_regression.rs 7.5 KB
        • 📄 generate_test_fixtures.rs 4.5 KB
        • 📄 golden_fixtures.rs 33.4 KB
        • 📄 policy_integration.rs 14.8 KB
      • 📄 build.rs 35.0 KB
      • 📄 Cargo.toml 1.7 KB
  • 📁 data/
    • 📄 confusables.txt 2.1 KB
    • 📄 known_domains.csv 3.0 KB
    • 📄 popular_repos.csv 466 B
    • 📄 public_suffix_list.dat 1.5 KB
  • 📁 docs/
    • 📄 compatibility.md 2.4 KB
    • 📄 cookbook.md 3.1 KB
    • 📄 dogfood-guide.md 1.7 KB
    • 📄 homebrew-core.md 734 B
    • 📄 roadmap.md 1.4 KB
    • 📄 security.md 1.6 KB
    • 📄 threat-model.md 3.6 KB
    • 📄 troubleshooting.md 12.8 KB
    • 📄 uninstall.md 1.8 KB
  • 📁 fuzz/
    • 📁 fuzz_targets/
      • 📄 byte_scanner.rs 130 B
      • 📄 extractor.rs 259 B
      • 📄 normalizer.rs 135 B
      • 📄 tokenizer_fish.rs 183 B
      • 📄 tokenizer_posix.rs 184 B
      • 📄 tokenizer_powershell.rs 189 B
      • 📄 url_parser.rs 126 B
    • 📄 Cargo.toml 815 B
  • 📁 mcp/
    • 📁 clients/
      • 📄 claude-code.md 8.1 KB
      • 📄 codex.md 2.6 KB
      • 📄 copilot-cli.md 3.7 KB
      • 📄 cursor.md 4.2 KB
      • 📄 E2E-CHECKLIST.md 6.1 KB
      • 📄 gemini-cli.md 2.9 KB
      • 📄 kiro.md 6.6 KB
      • 📄 openclaw.md 3.9 KB
      • 📄 pi-cli.md 3.2 KB
      • 📄 vscode.md 4.7 KB
      • 📄 windsurf.md 2.4 KB
    • 📄 tirith-gateway.yaml 2.8 KB
  • 📁 npm/
    • 📁 darwin-arm64/
      • 📄 LICENSE-AGPL 33.7 KB
      • 📄 LICENSE-COMMERCIAL 400 B
      • 📄 package.json 294 B
    • 📁 darwin-x64/
      • 📄 LICENSE-AGPL 33.7 KB
      • 📄 LICENSE-COMMERCIAL 400 B
      • 📄 package.json 288 B
    • 📁 linux-arm64/
      • 📄 LICENSE-AGPL 33.7 KB
      • 📄 LICENSE-COMMERCIAL 400 B
      • 📄 package.json 292 B
    • 📁 linux-x64/
      • 📄 LICENSE-AGPL 33.7 KB
      • 📄 LICENSE-COMMERCIAL 400 B
      • 📄 package.json 286 B
    • 📁 tirith/
      • 📁 bin/
        • 📄 tirith 1.1 KB
      • 📄 LICENSE-AGPL 33.7 KB
      • 📄 LICENSE-COMMERCIAL 400 B
      • 📄 package.json 558 B
    • 📁 win32-x64/
      • 📄 LICENSE-AGPL 33.7 KB
      • 📄 LICENSE-COMMERCIAL 400 B
      • 📄 package.json 288 B
  • 📁 packaging/
    • 📁 aur/
      • 📄 PKGBUILD 2.1 KB
      • 📄 tirith.install 473 B
    • 📁 chocolatey/
      • 📁 tools/
        • 📄 chocolateyinstall.ps1 609 B
        • 📄 chocolateyuninstall.ps1 92 B
      • 📄 tirith.nuspec 1.0 KB
    • 📁 homebrew/
      • 📄 tirith.rb 1.7 KB
    • 📁 mise/
      • 📄 tirith.toml 204 B
    • 📁 rpm/
      • 📄 tirith.spec 2.4 KB
    • 📁 scoop/
      • 📄 tirith.json 796 B
    • 📁 windows/
      • 📄 install.ps1 2.4 KB
  • 📁 scripts/
    • 📄 codex-upgrade-smoke.sh 9.0 KB
    • 📄 install.sh 5.3 KB
    • 📄 update-data.sh 828 B
  • 📁 shell/
    • 📁 lib/
      • 📄 bash-hook.bash 33.2 KB
      • 📄 fish-hook.fish 11.5 KB
      • 📄 nushell-hook.nu 1.8 KB
      • 📄 powershell-hook.ps1 12.3 KB
      • 📄 zsh-hook.zsh 8.9 KB
    • 📄 tirith.sh 984 B
  • 📁 tests/
    • 📁 fixtures/
      • 📄 clean.toml 7.1 KB
      • 📄 codefile.toml 4.4 KB
      • 📄 command.toml 35.6 KB
      • 📄 configfile.toml 18.5 KB
      • 📄 credential.toml 1.9 KB
      • 📄 documented_commands.toml 3.5 KB
      • 📄 ecosystem.toml 5.0 KB
      • 📄 environment.toml 1.6 KB
      • 📄 hostname.toml 7.5 KB
      • 📄 path.toml 2.9 KB
      • 📄 policy.toml 2.5 KB
      • 📄 README.md 399 B
      • 📄 rendered.toml 4.0 KB
      • 📄 shell_weirdness.toml 2.7 KB
      • 📄 terminal.toml 11.1 KB
      • 📄 test-threatdb.dat 505 B
      • 📄 threatintel.toml 2.7 KB
      • 📄 transport.toml 4.2 KB
    • 📁 install-sh/
      • 📄 verify_sha256.sh 2.9 KB
  • 📁 tools/
    • 📁 license-server/
      • 📁 src/
        • 📁 routes/
          • 📄 health.rs 154 B
          • 📄 mod.rs 513 B
          • 📄 receipt.rs 9.5 KB
          • 📄 refresh.rs 2.3 KB
          • 📄 webhook.rs 24.7 KB
        • 📄 config.rs 4.1 KB
        • 📄 db.rs 50.5 KB
        • 📄 error.rs 1.8 KB
        • 📄 main.rs 12.7 KB
        • 📄 sign.rs 3.9 KB
        • 📄 state.rs 276 B
        • 📄 webhook_verify.rs 7.0 KB
      • 📄 Cargo.toml 1.1 KB
    • 📁 sign-license/
      • 📁 src/
        • 📄 main.rs 15.6 KB
      • 📄 Cargo.toml 480 B
  • 📄 .dockerignore 40 B
  • 📄 .gitignore 883 B
  • 📄 .pre-commit-hooks.yaml 246 B
  • 📄 action.yml 2.1 KB
  • 📄 Cargo.lock 90.9 KB
  • 📄 Cargo.toml 1.6 KB
  • 📄 CHANGELOG.md 13.9 KB
  • 📄 deny.toml 1.2 KB
  • 📄 Dockerfile 573 B
  • 📄 flake.lock 1.5 KB
  • 📄 flake.nix 2.4 KB
  • 📄 LICENSE-AGPL 33.7 KB
  • 📄 LICENSE-COMMERCIAL 400 B
  • 📄 NOTICE 524 B
  • 📄 README.md 27.7 KB
  • 📄 rustfmt.toml 17 B
  • 📄 SECURITY.md 2.6 KB
  • 📄 SKILL.md 12.5 KB
  • 📄 threatdb-manifest.json 322 B
  • 📄 TIRITH.md 55.5 KB

SKILL.md

登录后下载/点赞/收藏 ❤ 2.3K | ★ 0
评论 0

请先登录后评论。

评论加载中...