feat(application): add isolated JavaScript replay

Expose one plan/execute replay contract through both CLI and MCP with exact source, input, runtime, sandbox, limit, and export commitments.

Run selected ESM and extracted CommonJS/Rspack factories in a disposable Linux x64 Bubblewrap namespace with a content-addressed Node ELF closure, architecture-checked seccomp, delegated systemd cgroup limits, bounded protocol capture, cancellation, and observable cleanup.

Preserve left and right observations as Evidence, derive differential comparisons without erasing unknowns, add optional separately authorized reproducers, and fail closed on stale plans or unavailable host boundaries.

Add source-owned parser, sanitizer, clipboard, denial, timeout, OOM, protocol-forgery, and cancellation coverage; a real Linux verifier and workflow; regenerated catalogs and TypeDoc; and updated the packaged REA analysis skill for the 83-tool inventory.
This commit is contained in:
N0zoM1z0
2026-07-16 15:45:55 +09:00
committed by N0zoM1z0
parent 461990da3f
commit d86231ad33
194 changed files with 6332 additions and 604 deletions
+5
View File
@@ -0,0 +1,5 @@
export default function busyLoop() {
while (true) {
// Intentionally consume the committed wall-clock budget.
}
}
+10
View File
@@ -0,0 +1,10 @@
202(module, exports, require) {
require.r(exports);
require.d(exports, {
normalize: () => normalize,
});
const normalize = (value) => ({
text: value.replaceAll("\r\n", "\n"),
bytes: value.length,
});
}
+1
View File
@@ -0,0 +1 @@
export default async () => import("node:fs");
+3
View File
@@ -0,0 +1,3 @@
export default function fail(value) {
throw new TypeError(`fixture:${value}`);
}
+8
View File
@@ -0,0 +1,8 @@
export default function allocateUntilKilled() {
const retained = [];
while (true) {
const allocation = new Uint8Array(1024 * 1024);
allocation.fill(1);
retained.push(allocation);
}
}
+7
View File
@@ -0,0 +1,7 @@
export default function parseMarkdown(value) {
if (value.startsWith("# "))
return { type: "heading", depth: 1, text: value.slice(2) };
if (/^\*\*.*\*\*$/u.test(value))
return { type: "strong", text: value.slice(2, -2) };
return { type: "paragraph", text: value.replaceAll("\r\n", "\n") };
}
+6
View File
@@ -0,0 +1,6 @@
export default function parseMarkdown(value) {
if (value.startsWith("# ")) return { type: "heading", text: value.slice(2) };
if (/^\*\*.*\*\*$/u.test(value))
return { type: "strong", text: value.slice(2, -2) };
return { type: "paragraph", text: value.replaceAll("\r\n", "\n") };
}
+9
View File
@@ -0,0 +1,9 @@
export default () =>
new Proxy(
{ hidden: true },
{
ownKeys() {
throw new Error("proxy trap must not run");
},
},
);
+6
View File
@@ -0,0 +1,6 @@
101(module) {
module.exports.sanitize = (value) => value
.replace(/<script[^>]*>[\s\S]*?<\/script>/giu, "")
.replace(/\son\w+=[^\s>]+/giu, "")
.replace(/javascript:/giu, "");
}
+9
View File
@@ -0,0 +1,9 @@
export default function attempt() {
return {
process: typeof process,
require: typeof require,
fetch: typeof fetch,
buffer: typeof Buffer,
timer: typeof setTimeout,
};
}
+3
View File
@@ -0,0 +1,3 @@
303(module, exports, require) {
module.exports = () => require("node:fs");
}