2680const name = np2.basename(bin).toLowerCase().replace(/\.exe$/, "");
L2681: if (name === "powershell" || name === "pwsh") {
L2682: const pre = "$ProgressPreference='SilentlyContinue';[Console]::OutputEncoding=[Text.Encoding]::UTF8;$OutputEncoding=[Text.Encoding]::UTF8;";
12293if (!msg) return "Error: empty message";
L12294: const argv = platform2 === "darwin" ? ["osascript", ["-e", `display notification ${JSON.stringify(msg)} with title ${JSON.stringify(head)}`]] : platform2 === "linux" ? ["notify-sen...
L12295: if (!argv) return `Notifications unavailable on ${platform2}.`;
L12296: const extra = platform2 === "win32" ? { windowsHide: true, env: { ...process.env, AGENTX_NOTIFY_TITLE: head, AGENTX_NOTIFY_BODY: msg } } : {};
L12297: return new Promise((resolve6) => {
L12298: run(argv[0], argv[1], { timeout: 5e3, ...extra }, (e) => {
HighSame File Env Network Execution
A single source file combines environment access, network access, and code or shell execution; review context before blocking.
dist/cli.jsView on unpkg · L12293 •Manifest-reachable source captures an API credential, sends it to a fixed unofficial gateway, and persists that redirection in agent or shell configuration.
dist/cli.js:
writeFile: 1,
await ctx.fs.writeFile(path, body);
await ctx.fs.writeFile(path, current);
await ctx.fs.writeFile(p, content);
headers: { authorization: `Bearer ${opts.key}`, "content-type": "application/json" },
async writeFile(path, content) {
for (const [p, c] of this.st.writes) await this.base.writeFile(p, c);
await ctx.fs.writeFile(path, next);
HighCredential Redirect Persistence
Manifest-reachable source sends a prompted API credential to a fixed unofficial gateway and persists the redirection.
dist/cli.jsView on unpkg 23Trigger-reachable persistence chain: manifest.bin -> dist/cli.js
L23: import { readFileSync, statSync as statSync2 } from "fs";
L24: import { imageWireOf, inlineImageForWire, scrubBase64Text, imageSize, imageNote, IMAGE_MAX_SIDE, IMAGE_MAX_BYTES } from "ai.libx.js";
L25: function remember(id, w) {
...
L84: if (content == null || typeof content === "string") return false;
L85: return content.some((p) => p.type === "image_url" && (p.image_url?.url ?? "").startsWith("data:"));
L86: }
...
L400: CONFIG_FILE_RE = /(^|\/)\.(agent|claude)\/(settings(\.[\w-]+)?\.json|config\.(json|js|mjs|cjs|ts))$/i;
L401: SECRET_PAIR = /((?:^|[\s,{[])(?:export\s+)?["']?[\w.\-]*(?:KEY|TOKEN|SECRET|PASSWORD|PASSWD|CREDENTIAL|PRIVATE_KEY|ACCESS_?KEY|AUTH(?:_?TOKEN)?|BEARER)[\w.\-]*["']?\s*[:=]\s*)(["']...
L402: SECRE
HighTrigger Reachable Persistence
A manifest entrypoint or package-local install chain reaches persistence behavior.
dist/cli.jsView on unpkg · L23 23import { readFileSync, statSync as statSync2 } from "fs";
L24: import { imageWireOf, inlineImageForWire, scrubBase64Text, imageSize, imageNote, IMAGE_MAX_SIDE, IMAGE_MAX_BYTES } from "ai.libx.js";
L25: function remember(id, w) {
...
L84: if (content == null || typeof content === "string") return false;
L85: return content.some((p) => p.type === "image_url" && (p.image_url?.url ?? "").startsWith("data:"));
L86: }
...
L400: CONFIG_FILE_RE = /(^|\/)\.(agent|claude)\/(settings(\.[\w-]+)?\.json|config\.(json|js|mjs|cjs|ts))$/i;
L401: SECRET_PAIR = /((?:^|[\s,{[])(?:export\s+)?["']?[\w.\-]*(?:KEY|TOKEN|SECRET|PASSWORD|PASSWD|CREDENTIAL|PRIVATE_KEY|ACCESS_?KEY|AUTH(?:_?TOKEN)?|BEARER)[\w.\-]*["']?\s*[:=]\s*)(["']...
L402: SECRET_TOKEN = /\b(sk-ant-[\w-]{12,}|sk-[A-Za-z0-9]{20,}|ghp_[A-Za-z0-
MediumInstall Persistence
Source writes installer persistence such as shell profile or service configuration.
dist/cli.jsView on unpkg · L23