Back to skill

Security audit

rabbit-readme-improver

Security checks for vulnerabilities and agentic risk

Overview

The README helper is mostly coherent, but its optional model-rewrite mode can send draft excerpts and a Rabbit model API key to a repository-selected endpoint without a separate trust gate.

Before installing, be comfortable with the skill reading project documentation and voice-profile files and editing README text when asked. Avoid running scan.py --apply-model in repositories you do not trust unless you inspect .rabbit-model first or pass your own known endpoint; use --model-plan for a no-send preview and keep valuable API keys out of RABBIT_* variables used in untrusted checkouts.

Vulnerability Patterns
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/rwlib/endpoint.py:481
Finding

Repository-Controlled Configuration Can Redirect Document Passages and Model Credentials

Content
View full analysis

Vulnerability Details

File Location: scripts/rwlib/endpoint.py:481-520 and scripts/rwlib/endpoint.py:278-289
Vulnerability Type: Untrusted endpoint configuration and sensitive-data disclosure
Risk Level: Medium

Complete Code Snippet

python
def _request(self, system, user, temperature, opener, thinking_off):
    payload = {
        "model": self.model,
        "messages": [{"role": "system", "content": system},
                     {"role": "user", "content": user}],
        "temperature": (self.temperature if temperature is None
                        else float(temperature)),
        "max_tokens": self.max_output_tokens,
        "stream": False,
    }
    if thinking_off:
        payload.update(THINKING_OFF)
    body = json.dumps(payload).encode("utf-8")
    headers = {"Content-Type": "application/json"}
    if self.api_key:
        headers["Authorization"] = "Bearer %s" % self.api_key
    url = self.base_url + "/chat/completions"
    request = urllib.request.Request(url, data=body, headers=headers,
                                     method="POST")
    opener = opener or urllib.request.urlopen
    try:
        with opener(request, timeout=self.timeout) as response:
            raw = response.read().decode("utf-8", "replace")
python
start_dirs = []
if target_path:
    start_dirs.append(os.path.dirname(os.path.abspath(target_path)))
start_dirs.append(os.getcwd())
path = next((p for p in (_find_config(d) for d in start_dirs) if p), None)

if path:
    try:
        with open(path, encoding="utf-8") as fh:
            config = json.load(fh)
    except (OSError, ValueError) as exc:
        return None, "%s could not be read: %s" % (path, exc)
    bad = problems(config, path)
    if bad:
        return None, " ".join(bad)
    env_name = config.pop("api_key_env", None)
    key = os.environ.get(env_name) if env_name else None
    if env_na
...[truncated 3585 chars]
Remediation
View remediation

Remediation Suggestions

  1. Treat every .rabbit-model file located inside a Git working tree as untrusted by default.
  2. Refuse repository-controlled remote endpoints unless the user supplies an explicit flag such as --trust-repository-model-config.
  3. Require interactive confirmation before the first transmission, showing the normalized destination host, configuration source, credential variable name, and passage count.
  4. Prefer user-owned configuration outside the repository. Environment or command-line endpoint settings should override repository files rather than the reverse.
  5. Maintain a user-level allowlist of approved endpoint origins and require exact scheme, hostname, and port matching.
  6. Do not attach credentials selected by repository configuration. Require credential selection to come from a trusted user-level configuration or an explicit command-line option.
  7. Consider refusing api_key_env entirely in repository-local files, even when the name begins with RABBIT_.
  8. Make --model-plan or an equivalent no-send preview mandatory before using a repository-controlled endpoint.
  9. Clearly distinguish local loopback endpoints from remote endpoints and require an additional opt-in for any non-loopback destination.
  10. Add regression tests proving that configuration inside a Git checkout cannot silently override a trusted endpoint or cause a credential-bearing request without explicit approval.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (66)

Agent Config Directory Access

High
Category
Agent Snooping
Confidence
90% confidence
Finding

Skill reads from agent configuration directories (.claude/, .codex/, .gemini/). These directories may contain API keys, personal settings, and other credentials that the skill has no legitimate need to access.

Content

Scanner excerpt · SECURITY.md (reported line 74)May include surrounding context.

md
- It writes four paths and no others: two markdown files under
  `~/.claude/output-styles/`, the `hooks` and `outputStyle` keys inside
  `~/.claude/settings.json`, and a record of those at
  `~/.claude/rabbit-writes-host.json`.
- `--dry-run` prints every one of them and writes nothing, and the skill's
  own instructions require showing that output to the user before running the

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Preservation/compliance checks between markdown files and stylistic-marker analysis are audit capabilities rather than README generation. Undeclared rewrite verification can inspect and compare content more broadly than users expect from a drafting aid.

Content

No source excerpt is available for this finding.

Static analysis

Detected: suspicious.dynamic_code_execution, suspicious.exposed_secret_literal

Dynamic code execution detected.

Critical
Code
suspicious.dynamic_code_execution
Location
scripts/readme_check.py:771

Dynamic code execution detected.

Critical
Code
suspicious.dynamic_code_execution
Location
scripts/rwlib/voices.py:688

File appears to expose a hardcoded API secret or token.

Critical
Code
suspicious.exposed_secret_literal
Location
scripts/rwlib/endpoint.py:54