archify
- Type
- Skill
- Scanned
- Nov 14, 2026
- Version
- e37848822238
- Files read
- 992
Archify is an AI coding agent skill and local Node.js tool that turns plain-language descriptions, Mermaid snippets, or project code into interactive HTML diagrams and one-page explainers. The biggest risks are that updating or checking untrusted files can read local files outside their folder, make live web requests, or open unverified HTML in Chrome, while the skill can also edit global AI agent settings across all your projects or be triggered unasked by untrusted text.
What it can reach
- Files
- Reads project files, Git history, diagram drafts, and local assets; writes HTML outputs, validation receipts, .archify working files, and update-check cache files; and can edit global AI agent rule files in your home folder (such as ~/.claude/CLAUDE.md or ~/.codex/AGENTS.md).
- Network
- Checks a GitHub Pages URL for release updates when delivering diagrams (unless disabled with ARCHIFY_UPDATE_CHECK_DISABLED=1), fetches remote brand icons over HTTP/HTTPS when validating or capturing brand URLs, and can run a local preview server on 127.0.0.1.
- Shell commands
- Runs its bundled Node.js CLI and child Node processes to build and verify diagrams, runs local git commands to check repository history and source files, and runs system opener commands (open, xdg-open, or PowerShell) when asked to open finished files.
- Browser
- Launches local headless Chrome, Chromium, or Microsoft Edge to check layouts and capture screenshots during verification, and opens generated HTML files or local preview URLs in your default browser when requested.
Findings
-
MediumExplainer panel patching trusts embedded baseDir and can read files outside the artifact directory
archify/explainer/patch.mjs:72
When running
archify patch explaineron a shared HTML file (such as via the built-in Ask button workflow), Archify reads the unsigned<script id="archify-explainer-prepared">JSON payload inside the HTML and resolvesprevious.baseDirrelative to the HTML file without checking for..traversal or absolute paths. BecausecheckExplainerHtmlonly verifies an unkeyed SHA-256 digest and does not require every image, chart data file, or diagram spec to already be frozen in the bundle, a crafted explainer HTML can pointbaseDirat another folder on the user's computer so that patching a panel embeds local PNG, JPEG, WebP, GIF, CSV, or JSON files from that folder into the new HTML.Fix: Reject
previous.baseDirandprevious.sourcePathvalues that escapepath.dirname(artifactPath)or require--require-provenancebefore re-reading any unretained local dependencies duringpatch explainer. -
MediumDiagram validation and rendering make live outbound HTTP(S) requests for brand.url entries
archify/renderers/shared/brand-marks.mjs:607
Whenever
validate,render,deliver,finalize,compare, orpreviewprocesses a diagram JSON containing abrand: { url, sha256 }object, Archify fetchesbrand.urlover the network (including query strings and discovered HTML icon links) before checking whether the response matchessha256. If an AI agent is tricked by prompt injection into placing workspace secrets intobrand.urlquery parameters with a dummy hash and runningarchify validateorfinalize, or if a user validates an untrusted JSON file, data is sent to the remote server with no offline disable flag.Fix: Store captured icon data or cache it locally during
brands capturesovalidateandrenderdo not make live network requests, or add an offline-by-default policy for validation. -
Mediumvisual-check and browser-check open unverified HTML in headless Chrome without blocking network or local file frames
archify/bin/visual-check.mjs:1557
The standalone
visual-checkandbrowser-checkcommands leave--require-provenanceoff by default (even though SKILL.md states that captures require strict provenance), copy the target HTML to a temporary file, and open it viafile://in headless Chrome without blocking outbound HTTP/HTTPS requests and with automatic--no-sandboxwhen running as root. If an agent is tricked into runningvisual-checkon an untrusted HTML file from a repository, the page can run arbitrary JavaScript with network access and frame local files viafile://so their contents appear in the captured screenshots.Fix: Require delivery provenance by default in
visual-checkandbrowser-check, blockhttp://*andhttps://*viaNetwork.setBlockedURLsduring inspection, and only pass--no-sandboxwhenARCHIFY_CHROME_NO_SANDBOX=1is explicitly set. -
LowSkill instructions trust mode-switching tags anywhere in context and offer to edit global agent rule files
SKILL.md tells the agent that a
[archify explainer: proactive]or[archify explainer: always-on]line anywhere in context changes its behavior to generate explainer files on unasked replies, without verifying that the directive came from the user's trusted configuration rather than an untrusted file or issue read into context. It also instructs the agent to offer appending persistent instructions to global agent configuration files (~/.claude/CLAUDE.md,~/.codex/AGENTS.md, or~/.config/devin/AGENTS.md), affecting all future projects.Fix: Only honor
[archify explainer: ...]directives from trusted user or project rule files rather than arbitrary context text, and avoid modifying global agent rule files from within a skill. -
LowLocal preview server serves rendered diagrams on 127.0.0.1 without authentication
When
archify previewis explicitly started, it opens an HTTP listener on127.0.0.1on a random port. Although Host-header andCross-Origin-Resource-Policy: same-originchecks block browser cross-origin and DNS-rebinding attacks, there is no per-session token, so other local users on a shared machine can read/artifact.htmland/state.Fix: Require an unguessable per-session token in the preview URL path or query string before serving
/,/state,/events, and/artifact.html. -
LowAgent installation guide runs unpinned skills@latest CLI against a mutable website endpoint
README.md instructs users to have their AI agent install Archify by reading llms.txt, which directs the agent to run npx -y skills@latest add https://archify.si. Using -y skills@latest automatically downloads and executes whatever version is currently tagged latest on npm without pinning a verified version, and https://archify.si serves whatever archive is currently deployed to the website rather than an immutable Git tag or commit SHA.
Fix: Pin the skills CLI to a specific verified version in llms.txt and README.md, and install from an immutable release tag or commit SHA or include an expected SHA-256 digest check.
-
LowFive newer diagram JSON schemas omit portableOutputPath validation on meta.output
archify/schemas/erd.schema.json:40
While the architecture, workflow, sequence, dataflow, lifecycle, and explainer schemas constrain meta.output to common.schema.json#/$defs/portableOutputPath (which blocks .. traversal, absolute paths, backslashes, non-.html extensions, and Windows device names) and archify/schemas/README.md states that every diagram schema requires a durable portable output, the erd, class, tree, timeline, and waterfall schemas define meta.output as an unconstrained string and omit it from required fields. Any consumer or preflight check relying on these compiled schemas will accept path-traversal or non-.html strings in meta.output unless blocked later by runtime CLI checks.
Fix: Reference common.schema.json#/$defs/portableOutputPath for meta.output (and add output to meta.required where intended) in erd.schema.json, class.schema.json, tree.schema.json, timeline.schema.json, and waterfall.schema.json, then regenerate the standalone validators.
-
LowAgent bootstrap instructions execute unpinned skills@latest package from mutable URLs
The README and website tell users to install Archify by having their coding agent read an unpinned main-branch URL (raw.githubusercontent.com/tt-a1i/archify/main/llms.txt), which in turn instructs the agent to run npx -y skills@latest against the live https://archify.si endpoint. Running skills@latest with -y downloads and executes whatever version is currently published on npm without version pinning, and fetching from moving branches or web endpoints exposes installers to upstream account or domain compromise.
Fix: Pin the Skills CLI to a vetted version (for example skills@1.7.4) and reference immutable release tags or commit SHAs in installation instructions.
-
LowPredictable shared /tmp directory used to stage and execute test code
test/explainer-packaging.test.mjs:11
On Linux and macOS, this developer test bypasses os.tmpdir() and creates a fixed /tmp/explainer-implementation/packaging directory with recursive mkdirSync before staging executable .mjs files inside it and running them with Node. On a multi-user machine, another local user could pre-create /tmp/explainer-implementation as a symlink or permissive directory and swap the staged CLI script before it is executed during test runs (the installed skill itself never runs this test).
Fix: Create the temporary directory directly under os.tmpdir() using fs.mkdtempSync(path.join(os.tmpdir(), 'archify-explainer-packaging-')) on all platforms instead of a fixed /tmp parent path.
