Security

A killed process never leaves a corrupt snapshot, one kernel owns a state directory, and /__monads refuses cross-origin calls.

16 tests in 4 files. Source: Typescript/tests/Security/

processInterruption.process.test.ts4 tests

Real SIGKILL and SIGTERM during writes never leave a corrupt snapshot.json; a second writer on one state directory is refused; a stale lock is reclaimed.

snapshotDurability.test.ts4 tests

Snapshots are saved atomically; a corrupted snapshot is quarantined, not overwritten.

stateDirLockRace.process.test.ts4 tests

Exactly one kernel survives a lock race; a late stale-lock reaper cannot remove a live lock; legacy locks fail closed or are recovered.

monadsControlOrigin.test.ts4 tests

The /__monads control surface blocks cross-origin and Origin: null requests and allows a local one.