Auto-claude-code-research-in-sleep
wanshuiyin/Auto-claude-code-research-in-sleep
- Type
- Plugin
- Scanned
- Nov 17, 2026
- Version
- 9f30e834d24a
- Files read
- 748
foo
Findings
-
HighUnrestricted shell execution pre-approved in web-scraping and literature-search skills
skills/firecrawl-search/SKILL.md:5
firecrawl-search (along with other web-facing search and read-only analysis skills such as exa-search, keenable-search, comm-lit-review, prior-art-search, alphaxiv, research-lit, and meta-optimize) declares allowed-tools: Bash(*) in its YAML frontmatter. In Claude Code, this pre-authorizes any shell command without a user confirmation prompt while the skill is active. Because these skills scrape and read untrusted third-party web pages and preprints directly into the agent's context, prompt injection hidden in a fetched page can make the agent run arbitrary commands silently.
Fix: Remove Bash(*) from skills that need no shell commands (such as comm-lit-review and prior-art-search, matching web-debug-search), and restrict Bash(...) in helper-backed search skills to the specific Python helper rather than a wildcard.
-
HighHelper script resolution executes untrusted scripts from the current git repository
skills/shared-references/review-tracing.md:58
The canonical helper resolver used across review tracing, wiki ingestion, paper lookup, and style extraction checks .aris/installed-skills.txt, .aris/tools/, and tools/ inside the current git repository before falling back to the user's trusted ARIS installation in ~/.aris/repo. If a user has ARIS installed globally and runs a review or paper-lookup skill inside a cloned third-party repository, a malicious tools/save_trace.sh, tools/arxiv_fetch.py, or .aris/installed-skills.txt in that repository will be executed directly via bash or python3 without any prompt injection. The same pattern appears in wiki-helper-resolution.md, skills-codex/shared-references/integration-contract.md, alphaxiv/SKILL.md, arxiv/SKILL.md, and auto-paper-improvement-loop/SKILL.md.
Fix: Resolve helper scripts from the trusted ARIS installation path ($ARIS_REPO or ~/.aris/repo, or symlinks verified to point inside ~/.aris/repo) before or instead of executing arbitrary files from ./tools/ or ./.aris/ in the current workspace.
-
MediumPython code injection when building Gemini API payloads in paper-illustration
skills/paper-illustration/SKILL.md:415
Steps 2, 3, and 4 of paper-illustration splice prompt text and raw Gemini API responses ($LAYOUT_REQUEST, $STYLE_REQUEST from layout_description.txt, and $RENDER_PROMPT from style_spec.txt) directly inside triple-quoted Python string literals ('''...''') within an unquoted python3 << PYTHON heredoc. If an input method file, reference paper, or model response contains ''' (for example in a code snippet or injected text), it breaks out of the string literal and executes arbitrary Python code on the user's machine.
Fix: Quote the heredoc delimiter (python3 << 'PYTHON') and read the text from the file or os.environ inside Python instead of interpolating shell variables into Python source code.
-
MediumUnauthenticated Feishu HTTP server bound to all network interfaces
mcp-servers/feishu-bridge/server.py:226
When started, the Feishu bridge binds an HTTP server to 0.0.0.0:5000 with no authentication, token check, or Origin validation. Anyone on the local network, or any website the user visits in a browser via cross-site POST requests, can call /send to send arbitrary Feishu messages using the user's bot credentials or call /reply to spoof user approvals for interactive ARIS workflow gates.
Fix: Bind HTTPServer to 127.0.0.1 by default, require a random bearer secret on /send and /poll, verify official Feishu webhook signatures on /reply, and reject browser cross-origin requests.
-
MediumRegex HTML sanitizer bypass allows stored XSS in rendered HTML reports
skills/render-html/scripts/render_html.py:122
Core skills (including citation-audit, rebuttal, proof-checker, and research-pipeline) automatically render Markdown reports containing external paper metadata or review text into HTML files via render_html.py (and its skills-codex mirror). Its sanitize_html function uses regexes that require leading whitespace before event handlers (missing valid HTML5 like <img src="x"onerror="alert(1)">) and miss HTML-entity-encoded javascript: URLs in raw <a> tags, allowing untrusted content to run JavaScript when the user opens the report in a browser.
Fix: Escape all raw HTML by default instead of stashing raw inline/block tags, or parse tags with html.parser against a strict attribute allowlist and decode HTML entities before validating URL schemes.
-
LowModal inference templates deploy unauthenticated public GPU endpoints
skills/serverless-modal/SKILL.md:200
Patterns B (@modal.fastapi_endpoint) and C (@modal.web_server(port=8000) running vllm.entrypoints.openai.api_server on an H100 GPU) are deployed via modal deploy app.py with no authentication. On Modal, these decorators expose a publicly reachable internet HTTPS URL by default; anyone on the internet who discovers the endpoint can send requests and burn the user's GPU credits or linked payment method.
Fix: Enable requires_proxy_auth=True on @modal.fastapi_endpoint and @modal.web_server, and pass --api-key backed by a Modal Secret to the vLLM server.
-
LowHeredoc delimiter breakout and missing read-only sandbox in nightmare-mode codex exec
skills/auto-review-loop/SKILL.md:520
In difficulty: nightmare mode, the skill instructs the agent to paste the verbatim contents of review-stage/REVIEWER_MEMORY.md and rebuttal text inside codex exec "$(cat <<'PROMPT' ... PROMPT)" while omitting --sandbox read-only. Although the Copilot section of the same file warns never to paste memory or rebuttal text into a heredoc because a line matching the delimiter breaks out, the codex exec blocks remain unpatched: a line equal to PROMPT in REVIEWER_MEMORY.md closes the heredoc early and executes subsequent lines as shell commands inside $(...).
Fix: Write the prompt and REVIEWER_MEMORY.md to a mktemp file using cat -- (as already done for the Copilot path), pass it to codex exec via stdin, and add --sandbox read-only.
-
LowDouble-quoted external paper metadata in wiki-ingestion shell templates allows command substitution
skills/exa-search/SKILL.md:193
When research-wiki/ is active, exa-search (as well as semantic-scholar, alphaxiv, research-lit, and idea-creator) instructs the agent to pass external web and paper metadata (<title>, <authors>, <venue>, and <thesis>) inside double quotes in bash commands. Unlike single quotes (used in firecrawl-search), bash double quotes evaluate $(...) and backtick command substitutions, so crafted or backtick-containing titles from external search results can execute unintended shell commands.
Fix: Pass untrusted metadata in single quotes (escaping embedded single quotes) after --, or feed structured JSON via stdin/file rather than double-quoted shell strings.
-
LowMandatory diagram verification downloads and runs unpinned npm package at runtime
skills/mermaid-diagram/SKILL.md:122
Step 4 of mermaid-diagram marks syntax verification as mandatory and runs npx -y @mermaid-js/mermaid-cli@latest whenever mmdc is not installed locally. Passing -y with @latest silently downloads and executes unpinned third-party npm code (and its browser dependencies) at runtime without user confirmation.
Fix: Require a locally installed mmdc binary or prompt the user before installing a pinned version rather than running npx -y ...@latest automatically.
-
LowSilent unpinned pip install at runtime in paper-slides
skills/paper-slides/SKILL.md:450
Phase 7 of paper-slides (also run automatically by paper-talk) executes pip install python-pptx without a version pin or user confirmation whenever pptx cannot be imported, mutating the local Python environment and running unpinned package installation code despite a note below claiming the step will be skipped if missing.
Fix: Remove || pip install python-pptx so the skill skips PPTX export and prints an install instruction when python-pptx is not installed.
-
LowFallback instructs the agent to read global ~/.claude/settings.json into LLM context
skills/auto-review-loop-minimax/SKILL.md:65
When the minimax-chat MCP server is unavailable, the skill instructs the AI agent to read ~/.claude/settings.json directly to obtain MINIMAX_API_KEY for curl. Reading the global settings file with the agent's Read tool sends every secret in that file (including unrelated MCP API keys and auth headers) to the executor model provider and records them in the session transcript.
Fix: Rely only on the process environment variable ($MINIMAX_API_KEY) inside the shell or MCP server rather than instructing the LLM agent to read ~/.claude/settings.json.
-
Lowcode_sync: git stages and pushes all untracked files with git add -A
skills/run-experiment/SKILL.md:107
When code_sync: git is enabled in CLAUDE.md, run-experiment runs git add -A && git commit && git push. Unlike the rsync mode above it—which excludes dotfiles, .aris/ logs, data, and weights—git add -A stages every untracked file not listed in .gitignore (such as .env secrets, vast-instances.json, or .aris/ review traces) and immediately pushes them to the remote git server.
Fix: Stage only tracked files (git add -u) or an explicit list of source paths, and check git status before pushing.
-
LowAPI keys and passwords passed in command-line arguments expose credentials locally
skills/paper-illustration/SKILL.md:327
paper-illustration passes GEMINI_API_KEY in the curl URL query string (?key=$API_KEY), while run-experiment runs ssh <server> "wandb login <WANDB_API_KEY>" and qzcli documents qzcli login -p 'YOUR_PASSWORD' and unguarded ~/.qzcli/.env creation. Command-line secrets are visible to other users via ps on shared workstations/GPU servers and can be captured in .aris/meta/events.jsonl tool logs.
Fix: Pass API keys via HTTP headers read from stdin/config (such as curl -H @- or x-goog-api-key via environment-only helpers), use --password-stdin, and set chmod 600 on credential files.
-
LowPredictable /tmp paths expose unpublished drafts and allow local tampering on shared machines
skills/citation-crosscheck/SKILL.md:398
Multiple skills write unpublished research content and verification state to fixed paths in /tmp—including /tmp/cx_gate.json and /tmp/cx_*.json in citation-crosscheck, /tmp/paper_full_text.txt in auto-paper-improvement-loop, /tmp/gemini_*.json in paper-illustration, and /tmp/screen_<name>.txt on remote SSH hosts in monitor-experiment. On shared lab or GPU servers, other local users can read unpublished manuscripts or pre-create/modify these files to disrupt runs or alter gate inputs.
Fix: Write temporary artifacts under a project-local .aris/ directory or a private directory created with mktemp -d (mode 0700).
-
LowUnencrypted HTTP used for arXiv API requests
The inline arXiv query fallback in arxiv (and Step 2.3 of wiki-enrich) fetches http://export.arxiv.org/api/query over plaintext HTTP instead of HTTPS, allowing an attacker on local Wi-Fi to read search queries and tamper with returned paper abstracts fed into the agent.
Fix: Use https://export.arxiv.org/api/query instead of http://.
-
LowRuntime clone and execution of external Anti-Autoresearch repository
skills/integrity-forensics/SKILL.md:81
integrity-forensics—which runs by default in /paper-writing at max, beast, or submission assurance—clones https://github.com/wanshuiyin/Anti-Autoresearch.git into ~/.aris/anti-autoresearch at a pinned commit SHA and runs python3 eval/run_eval.py plus its external SKILL.md workflow. Although pinned and documented, this executes code fetched from GitHub at runtime that is not part of the installed plugin files.
Fix: Bundle the audited forensics scripts directly in the repository or verify a cryptographic SHA-256 archive hash.
-
Lowtraining-check instructs the agent to create recurring CronCreate jobs without asking
skills/training-check/SKILL.md:135
training-check (which can also be invoked from experiment-bridge and auto-review-loop when W&B is enabled) explicitly tells the agent not to ask the user before registering a recurring CronCreate background job that polls metrics, calls external reviewers, and can terminate training sessions.
Fix: Ask for user confirmation before registering recurring background cron tasks that consume API quota or can stop running jobs.
-
Lowcodex-image2 checks for shell execution only after commands have already run
mcp-servers/codex-image2/server.py:465
Although documented as a narrow bridge that only writes PNG images under cwd/figures/ai_generated/ and rejects shell or Python execution, run_codex_image invokes codex debug app-server send-message-v2 without a read-only sandbox flag and only checks summary["commandItems"] after subprocess.run finishes. If prompt injection in an image prompt convinces Codex to run a command, the command executes on the host before the bridge rejects the response.
Fix: Pass explicit read-only sandbox and command-disabling flags to Codex before starting the turn rather than relying on prompt instructions and post-execution log inspection.
-
Lowclaude-review MCP bridge logs full prompts and responses to world-readable /tmp file by default
mcp-servers/claude-review/server.py:42
Unlike the sibling bridges that disable debug logging by default or store redacted logs with 0600 permissions, claude-review defaults DEBUG_LOG to /tmp/claude-review-mcp-debug.log and logs full prompts and responses with default file permissions and without O_NOFOLLOW. On shared machines such as university GPU servers, other local users can read unpublished manuscripts, code, or confidential patent disclosures from /tmp, or plant symlinks at the predictable log path.
Fix: Disable debug logging by default, move opt-in logs inside the user's 0700 state directory, open log files with O_NOFOLLOW and 0600 permissions, and redact prompt and response bodies.
-
LowShared /tmp/aris-watchdog directory and unvalidated task names allow local file overwrite
The server-side monitoring daemon defaults its base directory to /tmp/aris-watchdog without checking directory ownership or setting 0700 permissions, and builds status file paths directly as status_dir / f"{name}.json". On a shared multi-user GPU server, another local user can pre-create /tmp/aris-watchdog with permissive permissions or tamper with tasks.json using path traversal in the task name to make the victim's daemon overwrite arbitrary files.
Fix: Default the watchdog directory to a user-private path such as ~/.aris/watchdog with 0700 permissions, verify directory ownership before use, and validate task names against a strict alphanumeric slug regex.
-
LowPath traversal in jobId allows reading and corrupting arbitrary JSON files
mcp-servers/claude-review/server.py:195
Neither claude-review nor codex-image2 validates jobId before constructing JOBS_DIR / f"{job_id}.json" (unlike gemini-review, which enforces a strict alphanumeric regex). A prompt-injected agent can pass ../ segments in jobId to review_status or generate_status to read arbitrary JSON files on the host and, if a file contains status set to queued or running, overwrite it on disk.
Fix: Validate jobId against ^[0-9a-f]{32}$ (or a strict alphanumeric pattern) and verify that the resolved path stays inside JOBS_DIR before reading or writing.
-
LowUnvalidated threadId and unrestricted config overrides in codex-exec reviewer bridge
mcp-servers/codex-exec/server.py:61
Unlike antigravity-exec and grok-exec, codex-exec does not validate that threadId is a UUID, allowing ../ path traversal when loading saved thread settings and allowing leading-dash flags (such as --last) to be passed to codex exec resume to access private interactive sessions. In addition, the codex tool accepts danger-full-access sandboxing and arbitrary -c config overrides (which can define host notify or mcp_servers commands), even though documentation recommends pre-approving mcp__codex__codex for unattended runs while keeping Bash gated.
Fix: Validate threadId as a canonical UUID, pass -- before positional arguments where supported, default to read-only sandboxing, and restrict config overrides to an allowlist such as model_reasoning_effort.
-
LowInjected AGENTS.md instructions direct agents to install an external unpinned skill without confirmation
tools/install_aris_codex.sh:786
By default, install_aris_codex.sh appends a Goal Pulse section to the project's AGENTS.md (mirrored in AGENT_GUIDE.md for both Codex and Claude Code) instructing the agent to enable HERO Goal Pulse without confirmation when starting or resuming a Goal, and if missing, to follow an external GitHub main-branch URL to prepare the skill and its dependencies. Fetching and executing setup instructions from an unpinned remote branch without asking the user creates a supply-chain and prompt-injection risk if that repository is modified.
Fix: Vendor the Goal Pulse skill at a pinned commit inside this repository or require explicit user confirmation before fetching and installing external skills or dependencies.
-
LowOpt-in llm-chat HTTP reviewer reads arbitrary local files without workspace confinement
mcp-servers/llm-chat/server.py:389
When LLM_REVIEW_FALLBACK_ENABLED=true, the review and review_reply tools accept a files list and read each path via expanduser() with no workspace boundary or symlink check. A prompt-injected agent can supply sensitive paths outside the project (such as ~/.ssh keys or credential files) and send their contents to the configured external LLM_BASE_URL.
Fix: Confine all paths in files to an explicit project workspace root, reject symlinks and dotfiles/secret directories, and fail closed when a path resolves outside the workspace.
-
LowOverleaf setup exposes cleartext token in process arguments and alters global Git config
overleaf_setup.sh embeds OL_TOKEN directly in the git clone command-line URL before later calling git credential approve, exposing the cleartext Overleaf token in the OS process list (ps aux) to other local users during the clone, and overwrites the user's global git credential.helper setting (falling back to plaintext store on unrecognized platforms).
Fix: Configure the credential helper locally and feed the token via git credential approve on stdin before running git clone on the tokenless URL.
-
LowPoster and report HTML templates load unpinned CDN scripts without Subresource Integrity
skills/paper-poster-html/templates/landscape_4col.html:53
The HTML poster templates (landscape_4col.html, landscape_hero.html, and portrait_2col.html) load a floating major-version script (mathjax@3) from cdn.jsdelivr.net without pinning an exact version or verifying a Subresource Integrity hash. Because these files are opened locally over file:// in browsers and headless Chromium, an upstream CDN or package compromise would execute arbitrary JavaScript in the local rendering context.
Fix: Pin MathJax to an exact release version and add integrity and crossorigin="anonymous" attributes on external CDN script tags.
-
LowFeishu interactive setup guide recommends bypassPermissions without user allowlisting
docs/integrations/FEISHU.md:122
The optional Feishu integration guide (and FEISHU_CN.md) instructs users to enable group @mention and private-message permissions on a Feishu bot and sets PERMISSION_MODE=bypassPermissions in the example .env file. Although this guide is documentation rather than code run automatically on install, following it as written lets anyone in the Feishu group or organization message the bot to run unapproved commands in the configured project directory.
Fix: Default the documented example to PERMISSION_MODE=default, warn explicitly about the remote command execution risk of bypassPermissions, and document how to restrict the bot to a single authorized Feishu user ID.
