ContractSutra AIv0.2.1GitHub

Security and privacy

Privacy

Threat model (summary)

ThreatControlEvidence
Oversized or deeply nested input (DoS)4 MiB file cap, $ref depth 40, schema nesting 6unit tests, fuzz
Cyclic or remote $refLocal-only resolution, cycle detection, remote refs reported as unresolvedtests, fuzz
Prototype pollution via __proto__ keysOwn-property checks (Object.hasOwn), no deep-merge of inputfuzz (__proto__ payloads)
HTML/script injection through spec textEscaping everywhere, CSP default-src 'none', zero script tags (AUD-12)HTML escape tests
Report tamperingSHA-256 chain plus per-file hashes; independent audittests/assure.test.mjs
Path traversal / symlink escape (server, MCP, IDE copier)realpath containment, symlink rejectionserver/MCP tests (self-skip on Windows hosts without symlink rights)
Unauthorized HTTP accessLoopback bind, bearer token 32+ chars, constant-time compare, read-only, rate limitserver tests
Over-claimingNOT_RUN, USER_DECLARED_UNVERIFIED, UNKNOWN, AUD-08, AUD-11audit tests

What the hash chain is and is not

It makes after-the-fact edits detectable. It does not prove who produced the files, and an attacker who can rewrite the whole directory consistently can recompute it. For stronger guarantees, sign release artifacts and store audit output in write-once storage.

Supply chain

No runtime dependencies. GitHub Actions are pinned to major versions; npm releases use trusted publishing (OIDC) with provenance, so no long-lived npm token is stored.

Reporting a vulnerability

Use GitHub private vulnerability reporting on the repository (Security tab), or see SECURITY.md. Please include a minimal synthetic reproduction.

Limits

Not penetration-tested by a third party. No security certification is claimed. See Legal and governance.