T03 · Remote Payload Retrieval and Execution
- Location
handlers/latex.md:14- Finding
Mandatory execution of an unverified remote shell installer
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This PDF skill is mostly aligned with PDF creation and processing, but it uses unsafe dependency installation and gives HTML conversion more file and network access than necessary.
Install only if you trust the publisher and are willing to let the skill modify your development environment. Avoid running its remote `curl | sh` installer; prefer a verified Tectonic release or package manager. Do not use it on untrusted HTML unless network access and local file reads are sandboxed or disabled.
handlers/latex.md:14Mandatory execution of an unverified remote shell installer
scripts/html_to_pdf.js:193Active HTML rendering permits unrestricted network requests and arbitrary local stylesheet reads
scripts/pdf.sh:39Runtime installation of mutable and unpinned dependencies
The supplied code chunk does not implement PDF creation, PDF manipulation, LaTeX handling, citations, math rendering, Mermaid, or academic document features. Its primary purpose is dependency/environment management for Playwright/Chromium, likely as a support component for an HTML-to-PDF pipeline. While such a helper could indirectly support PDF generation, this chunk itself is focused on locating browser binaries and optionally installing Chromium, which is materially different from the declared end-user description. Therefore this code chunk's behavior is not accurately represented by the declared purpose.
The declared description emphasizes two main areas: creating PDFs using HTML + Paged.js (plus academic/LaTeX-oriented features) and processing existing PDFs with Python. The supplied code does neither of those directly. Instead, it performs file-format conversion from various source formats such as DOCX, PPTX, XLSX, CSV, TXT, and HTML into PDF using a headless LibreOffice subprocess. That is a materially different capability and primary behavior from the declared purpose. While converting HTML to PDF is loosely related to PDF creation, the implementation path and supported formats are much broader and centered on LibreOffice-based document conversion, which is undeclared.
The code chunk does not implement PDF generation, PDF reading/extraction/merge/split/form filling, academic formatting features, KaTeX/Mermaid support, or LaTeX compilation. Instead, it is a standalone HTML hyperlink preservation tool specifically designed for translation workflows. Its primary purpose and exposed commands (extract, restore, placeholder, unplaceholder) are materially different from the declared PDF/LaTeX solution, so this is a clear description-behavior mismatch.
This code appears to be an internal support library for CSS/Paged.js-style document rendering infrastructure, likely part of a PDF-generation stack, but the supplied chunk itself does not implement the declared end-user functionality. It mainly parses CSS, walks ASTs, validates syntax, matches declarations, and generates source maps. Those are supporting implementation details for HTML+Paged.js workflows, but the declared description is much broader and includes direct PDF creation, Python-based PDF processing, and LaTeX support. None of those capabilities are evidenced in this chunk. Therefore the description does not accurately represent what this specific code chunk actually does.
The code clearly supports several declared PDF-processing capabilities such as extracting content, merging/splitting PDFs, filling forms, and converting files to PDF. However, the declared description emphasizes a PDF creation workflow centered on HTML + Paged.js and academic/LaTeX-oriented features, none of which are evidenced in this code chunk. Instead, the code is a general-purpose PDF processing CLI with delegated commands for forms, extraction, page manipulation, metadata editing, and generic conversion. It also exposes capabilities not explicitly described, such as metadata modification and page rotation/cropping. Because the declared purpose prominently includes specialized creation and academic/LaTeX features that are absent here, while the actual code focuses on operational PDF manipulation, this is a meaningful description/behavior mismatch.
Referenced artifact was not completely inspected
如果运行 `pdf.sh html` 或 `html_to_pdf.js` 时遇到以下错误:
Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="{WORKSPACE}/.minimax/skills/minimax-pdf/scripts/styles/base.css">
<!-- 如果需要封面,再加一行对应的 cover CSS -->
<!-- <link rel="stylesheet" href="{WORKSPACE}/.minimax/skills/minimax-pdf/scripts/styles/cover-corporate.css"> -->
<style>
/* 这里只写本文档特有的自定义样式,base.css 已包含的不要重复写 */
Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="{WORKSPACE}/.minimax/skills/minimax-pdf/scripts/styles/base.css">
<!-- 如果需要封面,再加一行对应的 cover CSS -->
<!-- <link rel="stylesheet" href="{WORKSPACE}/.minimax/skills/minimax-pdf/scripts/styles/cover-corporate.css"> -->
<style>
/* 这里只写本文档特有的自定义样式,base.css 已包含的不要重复写 */
Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.
data-* Attributes<!-- Figures -->
<figure id="fig-1">
<img src="chart.png" alt="...">
<figcaption data-label="Figure 1">System Architecture</figcaption>
The skill instructs the agent/user to install software by fetching and piping a remote script directly into the shell in the home directory, without integrity verification, pinning, or trust guidance. This creates a clear supply-chain and remote code execution risk: if the endpoint is compromised, spoofed, or changed, arbitrary commands will run with the user's privileges.
The exact command 'curl -fsSL https://drop-sh.fullyjustified.net | sh' is a classic external-script-fetch pattern that executes untrusted remote content immediately. In the context of an agent skill, this is especially dangerous because it normalizes direct execution of network-delivered code during routine document generation workflows.
Tectonic is not pre-installed. Install it first:
cd ~ && curl -fsSL https://drop-sh.fullyjustified.net | sh && ls -la tectonic
Note: Tectonic will be installed to ~/tectonic (user home directory)
The chained command combines directory changes, remote script execution, and follow-up commands in one line, reducing visibility and making unsafe execution easier to overlook or automate. Chaining amplifies the risk of the remote installer by encouraging non-interactive execution and by making failure modes and side effects harder to inspect.
Tectonic is not pre-installed. Install it first:
cd ~ && curl -fsSL https://drop-sh.fullyjustified.net | sh && ls -la tectonic
Note: Tectonic will be installed to ~/tectonic (user home directory)
Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.
* @param {Node} node An object implementing the DOM1 |Node| interface.
* @return {boolean} true if the node is:
* 1) A |Text| node that is all whitespace
* 2) A |Comment| node
* and otherwise false.
*/
function isIgnorable(node) {
Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.
* @param {Node} node An object implementing the DOM1 |Node| interface.
* @return {boolean} true if the node is:
* 1) A |Text| node that is all whitespace
* 2) A |Comment| node
* and otherwise false.
*/
function isIgnorable(node) {
YARA rule matched a hack tool or exploit indicator (offensive tools, reconnaissance, privilege escalation, or exploit frameworks).
ry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz";
var _spec = "1.1.3";
var _where = "/home/gitlab-runner/builds/BQJy2NwB/0/pagedjs/pagedjs";
var author = {
name: "Roman Dvornov",
email: "rdvornov@gmail.com",
url: "https://github.com/lahmatiy"
};
var bugs = {
url: "https://github.com/csstree/csstree/issues"
};
var dependencies = {
"mdn-data": "2.0.14",
"source-map": "^0.6.1"
};
var description = "A tool set for CSS: fast detailed parser (CSS → AST), walker (AST traversal), generator (AST → CSS) and lexer (validation and matching) based on specs and browser implementations";
var devDependencies = {
"@rollup/plugin-commonjs": "^11.0.2",
"@rollup/plugin-json": "^4.0.2",
"@rollup/plugin-node-resolve": "^7.1.1",
coveralls: "^3.0.9",
eslint: "^6.8.0",
"json-to-ast": "^2.1.0",
mocha: "^6.2.3",
nyc: "^14.1.1",
rollup: "^1.32.1",
"rollup-plugin-terser": "^5.3.0"
};
var engines = {
node: ">=8.0.0"
};
var files = [
"data",
"dist",
"lib"
];
var
Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.
this.addNotesStyles(page.notes, page, ruleList, rule, sheet);
}
return rule;
}
addMarginVars(margin, list, item) {
Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.
this.addNotesStyles(page.notes, page, ruleList, rule, sheet);
}
return rule;
}
addMarginVars(margin, list, item) {
The script prints curl -fsSL https://drop-sh.fullyjustified.net | sh, which is a classic remote-script execution pattern with no integrity verification, pinning, or trust validation. In a setup/help context this is dangerous because users often copy-paste suggested commands verbatim, creating a high-impact supply-chain compromise path if the endpoint or transport is ever compromised.
echo " Python: brew install python3 (macOS) / apt install python3 (Ubuntu)"
echo " pikepdf: pip install pikepdf pdfplumber --user"
echo " LibreOffice: brew install --cask libreoffice (macOS)"
echo " Tectonic: curl -fsSL https://drop-sh.fullyjustified.net | sh"
echo ""
echo "=== Fix Version Mismatch ==="
The skill explicitly instructs the agent to use shell commands, dependency installers, and web-enabled tooling, but it does not declare any tool scope such as allowed-tools or permissions. That creates an authorization gap where an agent may invoke broad shell, environment inspection, and network-capable commands without an auditable least-privilege boundary, increasing the chance of unintended command execution or package installation.
The SKILL.md contains multiple mandatory instructions written entirely in Chinese, including operational requirements and prohibitions, which effectively impose a specific language on skill operators. The file does not offer an opt-in language choice or explain that the skill is intentionally limited to Chinese-speaking users, so this is a natural-language locale policy concern.
The instruction to run npx playwright install chromium relies on an unpinned package/tool resolution path, which can introduce supply-chain risk or inconsistent behavior across environments. If the resolved package version is unexpected or compromised, the skill can trigger execution of unreviewed code during installation.
npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.
npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.
npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.
npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.