← MCP server and skill grades

skills

bmad-code-org/BMAD-METHOD/skills

D
Type
Skill
Scanned
Nov 13, 2026
Version
e435a22574fe
Files read
542

This project provides the BMad Method collection of AI agent skills, role personas, and helper scripts for planning, designing, building, reviewing, and testing software. Its biggest risk is that these skills automatically run scripts and custom instructions stored inside the project folder being inspected, meaning simply reviewing an untrusted code repository or pull request can run malicious code on your computer.

What it can reach

Files
Reads and writes files in your project folder (such as code, settings, planning docs, tickets, and reports), as well as user templates in ~/.bmad/, installed skill folders, and Claude chat logs in ~/.claude/projects/.
Shell commands
Runs local Python scripts, Git and GitHub commands, package installers (uv and npx) to download dependencies or skills, file openers, and background AI command-line tools with permission prompts turned off during skill tests.
Network
Performs web searches, downloads software packages, fetches templates and files from GitHub or external links, connects to optional project trackers (like GitHub, Jira, Linear, Notion, and Trello), and loads display scripts from the internet when viewing HTML reports.
Secrets
Copies or links configured login files and system keychains from your home folder and forwards environment variables like API keys into temporary test environments when evaluating skills.
Browser
Opens locally generated HTML pages, including brainstorming tools, design mockups, reports, and formatted documents, in your default web browser.

Findings

2 high2 medium2 low
  1. HighSkills execute repository-controlled Python scripts from _bmad/scripts/ during code reviews

    skills/method/bmad-code-review/SKILL.md:17

    Skills locate {project-root} by walking up from the working directory for _bmad/ and immediately run Python scripts such as render_skill.py and resolve_customization.py from {project-root}/_bmad/scripts/, which is tracked in git. Even when bmad-code-review is run in no-code inspection-only mode or by a CI bot on a checked-out pull request or cloned third-party repository, a stranger who modifies _bmad/scripts/render_skill.py (or adds workflow hooks in _bmad/custom/) gets arbitrary code or prompt execution before the review starts.

    Fix: Run render_skill.py, resolve_customization.py, and resolve_config.py from the trusted installed skill directory ({skill-root}) rather than {project-root}/_bmad/scripts/, and ignore repository-committed executable hooks when reviewing untrusted branches.

  2. HighPath traversal via SKILL.md name escapes the bmad-eval clean room and writes files on the host

    skills/toolsmith/bmad-eval/scripts/run_triggers.py:99

    parse_skill_md() reads the name field from the target skill's SKILL.md frontmatter without sanitizing path separators or .. segments, and passes it directly into skills_dir / clean_name and make_run_dir(). Evaluating a downloaded or third-party skill whose SKILL.md contains ../ segments in name writes synthetic SKILL.md files (with attacker-controlled body text from description) and JSON artifacts outside the temporary clean room—potentially directly into the user's real ~/.claude/skills/ or ~/.agents/skills/ folder—before any harness sandbox runs.

    Fix: Pass skill_name through safe_name() and verify both skills_dir / clean_name and output_dir / run_id with contained() before creating directories or writing files.

  3. MediumSymlinked fixtures and skill files in run_evals.py copy arbitrary host files into the eval workspace

    skills/toolsmith/bmad-eval/scripts/run_evals.py:147

    When staging an evaluated skill and its cases.json fixtures on the host, resolve_fixtures() resolves relative paths with .resolve() without checking that the resolved target stays inside project_root or cases_dir, and stage_skill() calls shutil.copytree() with symlinks=False. If a user evaluates an untrusted skill repository containing symlinks (for example pointing to ~/.ssh/id_rsa or cloud credentials), host-side staging copies those secret files into the clean-room cwd/ and saved run artifacts, defeating any sandbox wrapped around harness.command.

    Fix: Verify that every resolved fixture path is is_relative_to() project_root or cases_dir, and refuse symlinks (or verify symlink targets stay inside skill_path) when copying the skill.

  4. MediumHTML entity bypass in render_view.py URL filter allows javascript: links in rendered HTML views

    skills/core-tools/bmad-facilitate/scripts/render_view.py:235

    harden() checks link and image URLs with unsafeUrl(href) on the raw token string before marked@12.0.2 emits <a href="..."> and inserts it via .innerHTML. Because marked does not decode HTML character references in link destinations and encodeURI() leaves &, #, and ; intact, a markdown link such as [link](javascript&colon;alert(1)) or [link](&#106;avascript:alert(1)) from external research or imported content bypasses unsafeUrl() and is decoded by the browser's HTML parser into an active javascript: link on a file:// page.

    Fix: Replace the raw-string scheme blocklist with post-render DOM sanitization that inspects parsed a.protocol and img.src values and permits only http:, https:, mailto:, and relative references.

  5. LowRendered HTML document views load remote CDN scripts without Subresource Integrity

    skills/core-tools/bmad-facilitate/scripts/render_view.py:483

    HTML views generated for PRFAQs, briefs, pitch decks, board packs, and investor updates dynamically inject <script> tags from https://cdn.jsdelivr.net for marked@12.0.2 and mermaid@10.9.1 without integrity hashes. Opening a local HTML document makes outbound requests to jsDelivr and trusts the CDN response without cryptographic verification in the file:// origin.

    Fix: Set pinned s.integrity (sha384-...) and s.crossOrigin = "anonymous" on the dynamically created <script> elements, or bundle the libraries locally so views are truly offline and self-contained.

  6. LowSetup and update workflows run unpinned npx skills commands with -y

    skills/core-tools/bmad/references/setup.md:5

    The setup instructions tell the agent to run npx skills commands automatically with -y, including npx skills update -p -y and npx skills add <owner>/<repo>. Using -y with an unpinned npm package name downloads and executes whatever version of skills is currently latest on npm without confirmation, and install_command() defaults to unpinned main branches unless the user already pinned a tag.

    Fix: Pin a specific version of the skills CLI package (such as npx skills@<version>) and require explicit user confirmation of the package, repository, and git ref before running install or update commands.