8import fsPromises__default, { readFile, mkdir, writeFile, chmod } from 'node:fs/promises';
L9: import require$$0, { execFileSync, ChildProcess, execFile, spawnSync, spawn } from 'node:child_process';
L10: import { createServer } from 'node:http';
L11: import require$$4, { styleText, debuglog, stripVTControlCharacters, inspect, promisify, callbackify, aborted } from 'node:util';
L12: import process$2, { stdout, stdin, platform, hrtime, execPath, execArgv } from 'node:process';
L13: import * as l from 'node:readline';
...
L86: // with no body, we should not to set Content-Type
L87: serializedBody === void 0 || // if serialized body is FormData; browser will correctly set Content-Type & boundary expression
L88: serializedBody instanceof FormData ? {} : {
...
L214: if (parseAs === "json" &
CriticalHardcoded Runtime Data Exfiltration
Source sends credentials or rich application records to a package-controlled external receiver enabled by default.
dist/index.jsView on unpkg · L8 8Trigger-reachable chain: manifest.main -> dist/index.js
L8: import fsPromises__default, { readFile, mkdir, writeFile, chmod } from 'node:fs/promises';
L9: import require$$0, { execFileSync, ChildProcess, execFile, spawnSync, spawn } from 'node:child_process';
L10: import { createServer } from 'node:http';
L11: import require$$4, { styleText, debuglog, stripVTControlCharacters, inspect, promisify, callbackify, aborted } from 'node:util';
L12: import process$2, { stdout, stdin, platform, hrtime, execPath, execArgv } from 'node:process';
L13: import * as l from 'node:readline';
...
L86: // with no body, we should not to set Content-Type
L87: serializedBody === void 0 || // if serialized body is FormData; browser will correctly set Content-Type & boundary expression
L88: serializedBody instanc
CriticalTrigger Reachable Dangerous Capability
A package entrypoint or install-time lifecycle script reaches a source file with blocking dangerous behavior.
dist/index.jsView on unpkg · L8 8import fsPromises__default, { readFile, mkdir, writeFile, chmod } from 'node:fs/promises';
L9: import require$$0, { execFileSync, ChildProcess, execFile, spawnSync, spawn } from 'node:child_process';
L10: import { createServer } from 'node:http';
HighChild Process
Package source references child process execution.
dist/index.jsView on unpkg · L8 11import require$$4, { styleText, debuglog, stripVTControlCharacters, inspect, promisify, callbackify, aborted } from 'node:util';
L12: import process$2, { stdout, stdin, platform, hrtime, execPath, execArgv } from 'node:process';
L13: import * as l from 'node:readline';
15229try {
L15230: await execa(packageManager || getPackageManager(), ["install"], {
L15231: cwd: projectPath,
...
L15241: }
L15242: const TEMPLATES_API_URL = process.env.MASTRA_TEMPLATES_API_URL || "https://mastra.ai/api/templates.json";
L15243: async function loadTemplates() {
HighSame File Env Network Execution
A single source file combines environment access, network access, and code or shell execution; review context before blocking.
dist/index.jsView on unpkg · L15229 •Manifest-reachable source captures an API credential, sends it to a fixed unofficial gateway, and persists that redirection in agent or shell configuration.
dist/index.js:
import fs, { readFileSync, statSync, appendFileSync, writeFileSync, createWriteStream, createReadStream, existsSync, mkdirSync, constants as constants$2 } from 'node:fs';
import fsPromises__default, { readFile, mkdir, writeFile, chmod } from 'node:fs/promises';
import * as l from 'node:readline';
import l__default from 'node:readline';
baseUrl = "",
baseUrl = removeTrailingSlash(baseUrl);
baseUrl: localBaseUrl,
let finalBaseUrl = baseUrl;
HighCredential Redirect Persistence
Manifest-reachable source sends a prompted API credential to a fixed unofficial gateway and persists the redirection.
dist/index.jsView on unpkg •Manifest-reachable source resolves another installed package, overwrites its runtime code, and injects package-defined remote behavior.
dist/index.js:
import fs, { readFileSync, statSync, appendFileSync, writeFileSync, createWriteStream, createReadStream, existsSync, mkdirSync, constants as constants$2 } from 'node:fs';
import fsPromises__default, { readFile, mkdir, writeFile, chmod } from 'node:fs/promises';
redirect: "follow",
const MASTRA_PLATFORM_API_URL = process.env.MASTRA_PLATFORM_API_URL || "https://platform.mastra.ai";
if (MASTRA_PLATFORM_API_URL.includes("staging")) return "https://gateway-api.staging.mastra.ai/v1";
return "https://gateway-api.mastra.ai/v1";
if (MASTRA_PLATFORM_API_URL.includes("staging")) return "https://studio.staging.mastra.ai";
return "https://studio.mastra.a
HighEntrypoint Foreign Package Code Overwrite
Manifest-reachable source overwrites another installed package with package-defined remote behavior.
dist/index.jsView on unpkg 10337// If `subprocess.stdin` is destroyed before being fully written to, it is considered aborted and should throw an error.
L10338: // This can happen for example when user called `subprocess.stdin.destroy()` before `subprocess.stdin.end()`.
L10339: // However, Node.js calls `subprocess.stdin.destroy()` on exit for cleanup purposes.
L10340: // https://github.[redacted]child_process.js#L278
L10341: // This is normal and should not throw an error.
...
L10346: // The only way to detect this is to spy on `subprocess.stdin._destroy()` by wrapping it.
L10347: // If `subprocess.exitCode` or `subprocess.signalCode` is set, it means `.destroy()` is being called by Node.js itself.
L10348: const handleStdinDestroy = (stream, {originalStreams: [originalStdin], subprocess}) => {
HighCommand Output Exfiltration
Source combines command execution, command-output handling, and outbound requests; review data flow before blocking.
dist/index.jsView on unpkg · L10337 8import fsPromises__default, { readFile, mkdir, writeFile, chmod } from 'node:fs/promises';
L9: import require$$0, { execFileSync, ChildProcess, execFile, spawnSync, spawn } from 'node:child_process';
L10: import { createServer } from 'node:http';
L11: import require$$4, { styleText, debuglog, stripVTControlCharacters, inspect, promisify, callbackify, aborted } from 'node:util';
L12: import process$2, { stdout, stdin, platform, hrtime, execPath, execArgv } from 'node:process';
L13: import * as l from 'node:readline';
...
L86: // with no body, we should not to set Content-Type
L87: serializedBody === void 0 || // if serialized body is FormData; browser will correctly set Content-Type & boundary expression
L88: serializedBody instanceof FormData ? {} : {
...
L214: if (parseAs === "json" &
HighSandbox Evasion Gated Capability
Source gates dangerous network, credential, or execution behavior behind CI, host, platform, time, or geo fingerprint checks.
dist/index.jsView on unpkg · L8 10337Trigger-reachable command-output exfiltration chain: manifest.main -> dist/index.js
L10337: // If `subprocess.stdin` is destroyed before being fully written to, it is considered aborted and should throw an error.
L10338: // This can happen for example when user called `subprocess.stdin.destroy()` before `subprocess.stdin.end()`.
L10339: // However, Node.js calls `subprocess.stdin.destroy()` on exit for cleanup purposes.
L10340: // https://github.[redacted]child_process.js#L278
L10341: // This is normal and should not throw an error.
...
L10346: // The only way to detect this is to spy on `subprocess.stdin._destroy()` by wrapping it.
L10347: // If `subprocess.exitCode` or `subprocess.signalCode` is set, it means `.destroy()` is being called by Node.js itself.
L10348: const handleStdinDestro
HighTrigger Reachable Command Output Exfiltration
A manifest entrypoint or package-local install chain reaches command-output exfiltration behavior.
dist/index.jsView on unpkg · L10337