Skip to content

chore(release): v0.11.0#412

Merged
jithinraj merged 17 commits intomainfrom
chore/release-v0.11.0
Feb 23, 2026
Merged

chore(release): v0.11.0#412
jithinraj merged 17 commits intomainfrom
chore/release-v0.11.0

Conversation

@jithinraj
Copy link
Member

@jithinraj jithinraj commented Feb 22, 2026

v0.11.0: Infrastructure Modernization + Enterprise Readiness

This release integrates 6 feature/chore PRs into a single release:

PR Title Status
#408 feat: migrate workspace to Zod 4 (DD-120) Ready
#407 feat: MCP Streamable HTTP transport (DD-119, DD-123) Ready
#409 feat: kernel constraints pipeline enforcement (DD-121) Ready
#410 feat: integrator kit bootstrap + conformance harness (DD-122) Ready
#411 chore: security, performance, dependency sweep (DD-118) Ready
This PR chore(release): v0.11.0 (version bump + CHANGELOG) Ready

Breaking Change

`@peac/schema` exports Zod 4 types. Zod 3 and Zod 4 types are not assignment-compatible. Consumers pinned to `^0.10.x` stay on v0.10.14 (safe); `^0.11.x` opts in.

Summary

  • Zod 4 migration (DD-120): all workspace packages migrated from Zod 3.25.x to Zod 4.x; `pnpm.overrides` enforces single major; `scripts/check-zod-single-major.mjs` CI gate verifies no mixed majors
  • MCP Streamable HTTP transport (DD-119, DD-123): session-isolated McpServer per HTTP session, CVE-2026-25536 mitigated by design, CORS/rate-limit/Origin/Host security, RFC 9728 PRM (implemented but disabled by default; enabled via `--authorization-servers` + `--public-url`)
  • Kernel constraint enforcement (DD-121): `validateKernelConstraints()` in issue() pre-sign and verify post-decode, fail-closed, new `constraint_violation` reason
  • Integrator Kit (DD-108, DD-122): template kit, ecosystem scaffolds (MCP/A2A/ACP/x402/Content Signals), conformance harness CLI with `format_version` 1.1.0 and `tooling` block (git_sha, node_version)
  • OWASP ASI alignment: all 10 risks mapped with test file citations
  • Performance baselines: updated with measured Zod 4 benchmarks; atomic writes; CI never auto-updates baseline

Security Hardening (Rounds 1-4)

  • CVE-2026-25536 multi-client concurrent isolation regression test (stop-ship)
  • Trust-proxy formal definition: peer_ip (socket addr) vs client_ip (resolved after trust evaluation)
  • XFF spoofing defense: untrusted peer's X-Forwarded-For ignored (negative test)
  • Per-IP session creation cap (default 10/IP) with decrement on terminate/evict
  • Session ID validation: visible ASCII 0x21-0x7E, max 128 chars (MCP spec)
  • MCP compliance matrix: 13 transport, 11 security, 8 session isolation, 7 authorization requirements tracked
  • Trojan Source bidi scanner regression test

Design Decisions

DD-119 (Streamable HTTP), DD-120 (Zod 4), DD-121 (kernel constraints pipeline), DD-122 (conformance harness), DD-123 (HTTP security)

PR Merge Order

`#407 -> #408 -> #409/#410/#411 (parallel) -> #412 (release)`

Test Coverage

4191 tests across 171 files, 77 build targets

Migrate all 9 packages from Zod 3.22.x to Zod 4.3.6. This is a
breaking change for downstream TypeScript consumers who compile
against exported @peac/schema types (z.infer<> types are not
assignment-compatible across Zod majors).

Schema changes:
- z.record() single-arg form removed in Zod 4: add explicit
  z.string() key schema in 5 locations (schema, control, mcp-server)
- .default({}) on object schemas requires output-type-compatible
  values in Zod 4: use .prefault({}) for input-type defaults (policy.ts)
- ZodError.errors alias removed: use .issues in test assertions
- issue.path typed as PropertyKey[] (was (string | number)[]): add
  casts at 2 call sites (protocol/issue.ts, cli/validators.ts)

No behavioral changes to schema validation, receipt issuance, or
verification. All 4138 tests pass across 167 test files.

Workspace enforcement:
- pnpm.overrides forces zod@^4.3.6 across all workspace packages
- Prevents mixed Zod 3/4 which causes runtime TypeError
Add HTTP transport alongside stdio for remote MCP client connectivity.
Each session gets isolated McpServer + transport (CVE-2026-25536 defense).

New files:
- src/http-transport.ts: HTTP server with CORS, rate limiting, PRM
- src/session-manager.ts: session lifecycle, TTL eviction, isolation

Endpoints: POST /mcp (JSON-RPC), DELETE /mcp (terminate session),
GET /health, GET /.well-known/oauth-protected-resource (conditional PRM)

Security (DD-123): localhost-only default, CORS deny-all, 1MB body limit,
per-session + per-IP rate limiting, Host/Origin validation, server timeouts

CLI flags: --transport, --port, --host, --cors-origins,
--authorization-servers, --public-url, --trust-proxy

Tests: 25 new (session manager + HTTP transport integration)
Wire validateKernelConstraints() into issue() and verify pipelines.
Fail-closed: violations reject before signing (issue) or before
schema validation (verify).

Changes:
- issue.ts: constraint check after claims build, before Zod parse
- verify-local.ts: constraint check after signature, before schema
- verify.ts: constraint check after decode, before Zod parse
- errors.ts: E_CONSTRAINT_VIOLATION error code + factory function
- verify-local.ts: E_CONSTRAINT_VIOLATION added to VerifyLocalErrorCode
- verify.ts: 'constraint_violation' added to VerifyFailure reasons

New: docs/specs/KERNEL-CONSTRAINTS.md normative specification
Tests: 11 new (issue + verify constraint boundary tests)
Add integrator kit templates for ecosystem partners and a CLI
conformance harness for running fixtures against validators.

Integrator kits:
- template/: base kit with README, integration guide, security FAQ
- mcp/, a2a/, acp/, x402/, content-signals/: ecosystem scaffolds

Conformance harness (scripts/conformance-harness.ts):
- Runs fixtures from specs/conformance/fixtures/ against validators
- JSON (default) or pretty output format
- Deterministic ordering, stable report schema
- Exit code 0 = pass, 1 = failures
- Core adapter: validates 10 fixture categories via @peac/schema
- Update performance baselines with Zod 4 benchmarks (measured)
- Create OWASP Top 10 for Agentic Applications alignment mapping (ASI-01 through ASI-10)
- Verify audit-gate allowlist freshness (3 active entries, all within 30-day ceiling)
- All 10 OWASP ASI risks mapped to specific PEAC mitigations with test file citations
Bump all 63 workspace packages to 0.11.0. CHANGELOG documents:
- Zod 4 migration (DD-120): breaking for TS consumers compiling against exported schemas
- MCP Streamable HTTP transport (DD-119, DD-123): session-isolated, CVE-2026-25536 mitigated
- Kernel constraint enforcement in pipelines (DD-121): fail-closed, new constraint_violation reason
- Integrator Kit + conformance harness (DD-108, DD-122)
- OWASP Top 10 for Agentic Applications alignment (ASI-01 through ASI-10)
- Performance baselines updated with Zod 4 benchmarks

Gates: 76 build targets, 4174 tests, lint/typecheck/format clean, guard.sh + check-planning-leak.sh pass
MCP transport (DD-119, DD-123):
- Session ID validation: ASCII 0x21-0x7E, max 128 chars (MCP spec)
- Trust-proxy: typed TrustProxyValue (off|loopback|IPs) replacing boolean
- PRM path-aware routing: validatePublicUrl(), trailing slash normalization
- Startup banner references MCP spec dates (2025-06-18, 2025-11-25)

Error code governance:
- E_CONSTRAINT_VIOLATION added to specs/kernel/errors.json (canonical registry)

Conformance harness (DD-122):
- Promoted to workspace package @peac/conformance-harness
- FAIL vs SKIP semantics: AdapterDefinition with supportedCategories
- Report schema (specs/conformance/report.schema.json) with schema_version
- Legacy fixture detection: auth wrapper + old format -> SKIP not FAIL
- scripts/conformance-harness.ts now thin redirect to workspace package

Editorial:
- CHANGELOG Unicode: replaced typographic arrows/symbols with ASCII equivalents
- guard.sh: allowlist integrator-kits/ for npm references (user-facing docs)

Tests: 24 HTTP transport tests (session ID, PRM paths, trust-proxy behavior)
Trust-proxy upgrade:
- TrustProxyValue presets: off, loopback, linklocal, private, all (discouraged)
- isLoopbackAddr/isLinkLocalAddr/isPrivateAddr helpers for RFC 1918/3927 ranges
- IPv6-mapped IPv4 (::ffff:) recognized in all presets

CVE-2026-25536 hardening:
- Explicit regression test: 3 concurrent sessions verified isolated (unique
  server, transport, and session ID per session; termination of one does not
  affect others)

Unicode/bidi stop-ship gate:
- Trojan Source regression test: RLO + LRI + PDI attack pattern detected
- Proves scanner catches exact pattern GitHub flags in diff views

MCP compliance:
- docs/security/MCP-COMPLIANCE-MATRIX.md maps 35 requirements (MUST/SHOULD/MAY)
  to specific test names across transport, security, session, and auth categories
- Intentional deviations documented (GET /mcp 405, Accept tolerance, unprotected mode)

Kernel constraints:
- Normative ordering precedence rule in KERNEL-CONSTRAINTS.md: constraint check
  runs before expensive JWKS fetch and signature verify (DoS resistance)
- Constraint validation does not mask downstream signature failures

Security:
- docs/security/HTTP-TRANSPORT-SECURITY.md: deployer-facing checklist (TLS,
  bind address, auth, trust-proxy, session management, monitoring)

CHANGELOG:
- Standards References section: MCP 2025-06-18/2025-11-25, RFC 9728,
  CVE-2026-25536, Zod ^4.3.6, OWASP ASI-01 through ASI-10
Session management hardening:
- Per-IP session creation limit (default 10/IP) prevents one IP from
  exhausting the global session pool (maxSessions)
- SessionEntry now tracks clientIp for per-IP accounting
- ipSessionCount map incremented on create, decremented on terminate/evict
- Startup banner shows per-IP limit alongside global limit

PRM startup validation:
- Empty authorization_servers entries filtered (whitespace-only rejected)
- Explicit warnings when --authorization-servers set without --public-url
  or vice versa (prevents silent misconfiguration)
- PRM document uses filtered authServers array

Trust-proxy integration test:
- trust-proxy=loopback test: XFF parsed from 127.0.0.1 connections

Benchmark metadata:
- Added cpu, git_ref, warmup/measurement iterations, notes to
  tests/perf/baseline-results.json for reproducibility

Tests: 4189 passing (171 files), 77 builds, all gates clean
…e versioning)

- Fix CI: regenerate errors.generated.ts after E_CONSTRAINT_VIOLATION addition
- Multi-client concurrent isolation regression test (CVE-2026-25536 stop-ship)
- Trust-proxy: formal peer_ip vs client_ip definition with JSDoc
- Trust-proxy: negative spoofing test (untrusted peer XFF ignored)
- PRM language precision: "implemented but disabled by default" in banner/CHANGELOG
- Zod single-major CI gate: scripts/check-zod-single-major.mjs
- Conformance report versioning: format_version 1.1.0, tooling block (git_sha, node_version)
- Benchmark reproducibility: atomic writes, warmup/measurement iteration constants
- MCP compliance matrix: S10/S11 (XFF spoofing, per-IP cap), C7/C8 (per-IP, concurrent isolation)
- PR merge order documented in CHANGELOG Notes
- Format errors.generated.ts after codegen (CI gate fix)
- Remove unused exactArray variable in issue-constraints.test.ts
- Refactor isLegacyFormat to IIFE with explicit type narrowing
- Bump specs/kernel/errors.json version to 0.11.0 (E_CONSTRAINT_VIOLATION added)
- Fix report.schema.json $id: add www. prefix to match all other schemas
- Fix peac-v0.9.2.json $id: peac.org -> www.peacprotocol.org (canonical domain)
# Conflicts:
#	docs/specs/KERNEL-CONSTRAINTS.md
#	packages/mcp-server/src/cli.ts
#	packages/mcp-server/src/http-transport.ts
#	packages/mcp-server/src/session-manager.ts
#	packages/mcp-server/tests/http/http-transport.test.ts
#	packages/mcp-server/tests/http/session-manager.test.ts
#	scripts/conformance-harness.ts
#	scripts/guard.sh
#	tests/perf/baseline-results.json
@jithinraj jithinraj merged commit 67c6240 into main Feb 23, 2026
9 checks passed
@jithinraj jithinraj deleted the chore/release-v0.11.0 branch February 24, 2026 21:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant