
Security News
Rust 1.100 Will Add Dependency Cooldowns to Cargo
Rust 1.100 will add opt-in dependency cooldowns to Cargo, giving security scanners and maintainers time to catch malicious crate releases.
@grayhaven/sandcastle
Advanced tools
TypeScript SDK for the SandCastle sandbox runtime — lightweight WASM-based sandboxes for AI agent code execution.
bun add @grayhaven/sandcastle
# or
npm install @grayhaven/sandcastle
import { SandCastle } from "@grayhaven/sandcastle";
const sc = new SandCastle();
const result = await sc.run<number>("return 1 + 1;");
// result === 2
const result = await sc.run<string>(
'const i = globalThis.__sandcastle_input; return "Hello " + i.name;',
{ name: "World" }
);
// result === "Hello World"
import { createCodeTool, TwoPassExecutor } from "@grayhaven/sandcastle/codemode";
const executor = new TwoPassExecutor();
const tool = createCodeTool({ tools: [...yourTools], executor });
// Give this single tool to your LLM instead of N separate tools
Feed these to your LLM so it knows the sandbox API:
import type {} from "@grayhaven/sandcastle/guest";
The sandcastle CLI must be installed and in your PATH. See the main repo for installation instructions.
LLM-generated code just works — no configuration needed:
const _ = require('lodash'); // Built-in shim
const { format } = require('date-fns'); // Built-in shim
const data = await fetch(url); // Delegates to HTTP capability
setTimeout(() => {}, 100); // Runs immediately (no event loop)
const clone = structuredClone(obj); // JSON round-trip
const id = crypto.randomUUID(); // Polyfilled
Object.groupBy, Set.intersection, iterator helpersfetch() polyfill — delegates to HTTP capability when registeredlodash, path, uuid, date-fns, qs work via require()console.log callbackreturn Promise.all([...]) works)MemoryExceeded status instead of opaque WASM trapsrequire('express') explains alternatives instead of crashingApache-2.0
FAQs
The fastest way to run untrusted JavaScript safely. Zero-config, Bun-first.
The npm package @grayhaven/sandcastle receives a total of 11 weekly downloads. As such, @grayhaven/sandcastle popularity was classified as not popular.
We found that @grayhaven/sandcastle demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Security News
Rust 1.100 will add opt-in dependency cooldowns to Cargo, giving security scanners and maintainers time to catch malicious crate releases.

Security News
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.

Security News
Anthropic’s free OSS Scanner uses Mythos and other Claude models to find open source vulnerabilities and send maintainers reports with proposed fixes.