Papyrus

PassAudited by VirusTotal on May 6, 2026.

Overview

Type: OpenClaw Skill Name: papyrus Version: 0.2.1 The Papyrus skill bundle contains several shell scripts (build_pdf.sh, render_figures.sh, and render_formulas.sh) that are vulnerable to command injection. These scripts use shell variables directly within Python one-liners (e.g., python3 -c "... '${VAR}' ...") without proper sanitization. This allows for arbitrary Python code execution if a processed LaTeX formula, filename, or URL contains malicious escape characters. While the tool's logic and instructions in SKILL.md and SOP.md appear aligned with its stated purpose of academic paper processing, these vulnerabilities represent a significant security risk in an agentic environment where untrusted paper sources are processed.

Findings (0)

Artifact-based informational review of SKILL.md, metadata, install specs, static scan signals, and capability signals. ClawScan does not execute the skill or run runtime probes.

What this means

A malformed or hostile archive could overwrite files outside the intended work area or leave a partial/corrupt workspace without the agent noticing.

Why it was flagged

The skill downloads an external paper archive and extracts it directly into a user-specified directory without validating archive member paths, symlinks, size, or extraction failure.

Skill content
curl -sL "$SOURCE_URL" -o "$OUTPUT_DIR/source.tar.gz"
...
tar -xzf "$OUTPUT_DIR/source.tar.gz" -C "$OUTPUT_DIR" 2>/dev/null || true
Recommendation

Validate archive contents before extraction, reject absolute paths, '..' paths, and unsafe symlinks, extract in a disposable sandbox, and remove the '|| true' so extraction failures stop the workflow.

What this means

If a crafted paper or formula file causes hostile formula text to be copied into the workflow, it could alter the Python snippet in the online-render path or trigger unsafe local TeX processing under the user's account.

Why it was flagged

Formula text taken from formulas.txt is embedded into a TeX document and also interpolated directly into Python source code inside a shell command instead of being passed as data via argv, stdin, or a safely quoted file.

Skill content
cat > "$tmpdir/formula.tex" << TEXEOF
...
${tex_formula}
...
TEXEOF
...
encoded=$(python3 -c "import urllib.parse; print(urllib.parse.quote('${tex_formula}'))")
Recommendation

Pass formula text to Python via stdin/sys.argv or JSON, avoid interpolating untrusted values into python -c strings, sanitize formula names and output paths, and run LaTeX in a sandbox with shell escape disabled.

What this means

For public arXiv papers this is usually acceptable, but formulas from a private or unpublished paper may leave the local machine.

Why it was flagged

When local LaTeX dependencies are unavailable, formula source is sent to the third-party Codecogs rendering service.

Skill content
echo "🌐 Falling back to online API (codecogs.com)"
...
local url="https://latex.codecogs.com/png.image?${encoded}"
...
resp = urllib.request.urlopen(req, timeout=15)
Recommendation

Use local LaTeX/offline rendering for private documents, or require an explicit user confirmation before using the Codecogs fallback.

What this means

Those agent platforms may continue to expose Papyrus commands after the immediate paper-conversion task.

Why it was flagged

The skill documents copying adapters into multiple agent platform configuration directories, which can persist tool availability beyond a single Papyrus task.

Skill content
cp platforms/claude-code/papyrus-skill.md .claude/skills/
cp platforms/codex/papyrus-tool.yaml .codex/tools/
cp platforms/hermes/papyrus-tool.py hermes/tools/
cp platforms/open-code/papyrus-config.yaml .open-code/
Recommendation

Only copy the adapters into trusted projects where you want persistent Papyrus access, and remove them when no longer needed.