Chuyển đến nội dung
Skillpedia
Bảo mật33k · #9076

supply-chain-guard

Skill này làm gì

Skill này hướng dẫn agent AI tìm các cuộc tấn công chuỗi cung ứng phần mềm trong dự án. Skill dành cho lập trình viên và đội bảo mật muốn kiểm tra thư viện phụ thuộc và pipeline của mình.

Khi nào nên dùng

  • ✓Khi bạn muốn kiểm tra thư viện phụ thuộc của dự án xem có gói đã biết là bị xâm nhập hoặc độc hại không.
  • ✓Khi có báo cáo về một cuộc tấn công chuỗi cung ứng mới và bạn muốn xem dự án của mình có bị ảnh hưởng không.
  • ✓Khi bạn thiết lập pipeline CI/CD và muốn tăng cường bảo mật cho chúng.

Liên kết skill

https://github.com/davila7/claude-code-templates/blob/main/cli-tool/components/skills/security/supply-chain-guard/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/davila7/claude-code-templates/blob/main/cli-tool/components/skills/security/supply-chain-guard/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Bạn có thể kiểm tra thiết lập npm và GitHub Actions của dự án chúng tôi xem có bị xâm nhập chuỗi cung ứng đã biết nào không?”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Agent xác định các tệp gói trong dự án, chạy các công cụ quét đi kèm, rồi báo cáo các gói bị xâm nhập và rủi ro của pipeline.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

Supply Chain Guard

Automated detection and remediation of software supply chain attacks across npm, PyPI, crates.io, GitHub Actions, and CI/CD pipelines. Built from real-world attack intelligence gathered through March 31, 2026.

When to Use This Skill

Use this skill when:

  • The user asks to audit a project's dependencies for security issues
  • Before deploying code to production
  • When investigating a potential supply chain compromise
  • When the user mentions a recent supply chain attack and wants to check their projects
  • As a regular security check in development workflows
  • When setting up CI/CD pipelines and wanting to harden them
  • When a new supply chain attack is reported and the user wants to verify exposure

Instructions

Step 1: Understand the Project

Identify what the user's project uses:

  • Node.js/npm: Look for package.json, package-lock.json, yarn.lock, pnpm-lock.yaml
  • Python/PyPI: Look for requirements.txt, Pipfile, pyproject.toml, poetry.lock
  • Rust/crates.io: Look for Cargo.toml, Cargo.lock
  • CI/CD: Look for .github/workflows/, Dockerfile, docker-compose.yml

Step 2: Run the Appropriate Scanners

The skill includes three specialized scanners plus a unified runner. All scripts are in the scripts/ directory.

Full audit (recommended):

bash /path/to/supply-chain-guard/scripts/scan-all.sh /path/to/project

Individual scanners:

# npm/Node.js projects
bash /path/to/supply-chain-guard/scripts/scan-npm.sh /path/to/project

# Python/PyPI projects
bash /path/to/supply-chain-guard/scripts/scan-python.sh /path/to/project

# CI/CD pipeline audit
bash /path/to/supply-chain-guard/scripts/scan-ci.sh /path/to/project

Each scanner checks for:

  1. Known compromised packages — exact matches against the IOC database
  2. Malicious versions — specific version numbers known to contain malware
  3. Filesystem IOCs — persistence mechanisms left by attackers
  4. Network IOCs — C2 domains and IPs in source code
  5. CI/CD misconfigurations — unpinned actions, dangerous triggers, exposed secrets
  6. Credential exposure — npm tokens, PyPI credentials, .env files

Step 3: Interpret Results

Scanners exit with the number of issues found (0 = clean). Issues are categorized:

  • [CRITICAL] — Known malicious package or active IOC detected. Immediate action required.
  • [WARNING] — Security concern that needs investigation. May not be an active compromise.

Step 4: Remediate

Based on findings, guide the user through remediation:

If a compromised package is found:

  1. Remove or downgrade to a known safe version immediately
  2. Clear package caches: npm cache clean --force / pip cache purge
  3. Delete node_modules / .venv and reinstall from lockfile
  4. Rotate ALL credentials that were accessible from the environment

If filesystem IOCs are found:

  1. The system should be treated as fully compromised
  2. Identify and remove persistence mechanisms (systemd services, .pth files, cron jobs)
  3. Rotate every credential on the system
  4. Audit cloud provider logs (AWS CloudTrail, GCP Audit Logs, Azure Activity Log)
  5. Check for lateral movement in Kubernetes clusters
  6. Consider reimaging the machine

If CI/CD issues are found:

  1. Pin all GitHub Actions to full commit SHAs (not version tags)
  2. Add --ignore-scripts to npm install/ci commands
  3. Add --require-hashes to pip install commands
  4. Remove or secure pull_request_target triggers
  5. Apply least-privilege permissions to workflow tokens
  6. Audit pipeline execution logs for the attack window periods

Step 5: Harden the Project

After remediation, recommend these preventive measures:

  1. Lock everything: Exact version pins + lockfiles committed to repo
  2. Hash-verify: Use npm ci (not npm install), pip install --require-hashes
  3. Disable scripts: Use --ignore-scripts by default, enable only for trusted packages
  4. Pin actions: All GitHub Actions pinned to full SHA, never tags
  5. Scope tokens: CI/CD tokens should have minimal permissions
  6. Monitor: Set up automated dependency scanning (but verify the scanner itself is not compromised — see Trivy incident)
  7. Network controls: Block known C2 domains/IPs at firewall level
  8. Audit regularly: Run this scanner before every deployment

Reference Files

  • references/ioc-database.md — Full IOC database with all compromised packages, malicious versi
Câu hỏi thường gặp

Skill bao gồm những hệ sinh thái nào?

Skill bao gồm npm, PyPI, crates.io, GitHub Actions và các pipeline CI/CD.

Skill có thay đổi mã của tôi không?

Skill tập trung vào phát hiện và khuyến nghị khắc phục, và agent nên giải thích các thay đổi trước khi áp dụng.

Dữ liệu của skill cập nhật đến khi nào?

Skill cho biết nó được xây dựng từ thông tin tình báo về các cuộc tấn công thu thập đến ngày 31 tháng 3 năm 2026.

Chi tiết

Mô tả gốc của tác giả

Detect and remediate software supply chain attacks in npm, PyPI, crates.io, GitHub Actions, and CI/CD pipelines by scanning for known compromised packages, malicious versions, filesystem IOCs, C2 indicators, and CI/CD misconfigurations.

repo: davila7/claude-code-templates

Độ phổ biến

Sao GitHub
33k
Vị trí xếp hạng
#9076
Giấy phép
MIT
Cập nhật
2/11/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự