Skip to content

Commit 3b0d46b

Browse files
attestation: fail closed on Nitro and ARM parser paths
1 parent 4d63149 commit 3b0d46b

6 files changed

Lines changed: 166 additions & 62 deletions

File tree

docs/audits/EVIDENCE_INDEX.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,8 @@ The current evidence branch is a pre-audit hardening candidate on top of
388388
| Drand relay boundary regression | `go test ./x/pouw/keeper -run 'TestHTTPDrandPulseProvider_|TestAssignmentEntropyFromContext_'` | `x/pouw/keeper/drand_pulse_test.go` |
389389
| Worker backend proxy boundary regression | `go test ./services/tee-worker/executor` | `services/tee-worker/executor/main_test.go` |
390390
| Lightweight attestation collateral fail-closed regression | `cargo test --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence fails_closed_without_backend` | `services/tee-worker/nitro-sdk/src/attestation/engine.rs` |
391+
| Nitro parser fail-closed regression | `cargo test --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence nitro` | `services/tee-worker/nitro-sdk/src/attestation/aws_nitro.rs` |
392+
| ARM attestation fail-closed regression | `cargo test --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence arm` | `services/tee-worker/nitro-sdk/src/attestation/arm_trustzone.rs` |
391393
| Seal verifier regression | `go test ./x/seal/keeper/...` | `x/seal/keeper/` |
392394
| Vault relay governance regression | `go test ./x/vault/keeper` | `x/vault/keeper/keeper_test.go` |
393395
| Sovereign access-control regression | `cargo test --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features full-sdk lib_full::sovereign::` | `services/tee-worker/nitro-sdk/src/sovereign/` |

docs/audits/REMEDIATION_REGISTER.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,8 @@ part of the `main`-branch CLOSED statistics below.
216216
| HS-2026-04-16-49 | Medium | Consensus / Drand Relay Boundary | Apply the shared endpoint safety validator to the consensus drand relay configuration and bound the localhost fallback decoder so malformed, metadata, or private-address relay targets fail closed instead of being probed, and local fallback responses cannot consume unbounded memory | `ramesh/protocol-hardening-sweep-20260416` / PR `#141` | `go test ./x/pouw/keeper -run 'TestHTTPDrandPulseProvider_|TestAssignmentEntropyFromContext_'`, `go test ./x/pouw/keeper`, and `go test ./app ./x/pouw/keeper ./x/verify/... ./x/seal/keeper ./x/validator/keeper ./x/vault/keeper` |
217217
| HS-2026-04-16-50 | Medium | Worker / Backend Proxy Boundary | Apply the shared endpoint safety validator to the TEE worker backend proxy configuration and runtime forwarding path so unsafe backend URLs fail closed at startup and at request time instead of allowing `/execute` and `/verify` traffic to be forwarded to malformed, metadata, or private-address targets | `ramesh/protocol-hardening-sweep-20260416` / PR `#141` | `go test ./services/tee-worker/executor` and `go test ./app ./x/pouw/keeper ./x/verify/... ./x/seal/keeper ./x/validator/keeper ./x/vault/keeper` |
218218
| HS-2026-04-16-51 | Medium | Worker / Attestation Collateral Truthfulness | Fail closed in the lightweight attestation engine when Intel PCCS or AMD KDS collateral backends are unavailable, instead of fabricating empty collateral bundles that could be mistaken for partial verification state | `ramesh/protocol-hardening-sweep-20260416` / PR `#141` | `cargo test --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence fails_closed_without_backend` and `cargo check --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence` |
219+
| HS-2026-04-16-52 | Medium | Worker / Nitro Parser Truthfulness | Fail closed in the Nitro attestation wrapper when the COSE/CBOR parsing backend is unavailable, instead of constructing a placeholder attestation document after only validating the outer COSE shell | `ramesh/protocol-hardening-sweep-20260416` / PR `#141` | `cargo test --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence nitro` and `cargo check --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence` |
220+
| HS-2026-04-16-53 | Medium | Worker / ARM Attestation Truthfulness | Fail closed in the ARM TrustZone / CCA wrapper when parser or signature-verification backends are unavailable, instead of fabricating placeholder token state or returning success from non-cryptographic signature paths | `ramesh/protocol-hardening-sweep-20260416` / PR `#141` | `cargo test --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence arm` and `cargo check --manifest-path services/tee-worker/nitro-sdk/Cargo.toml --features attestation-evidence` |
219221

220222
See `docs/audits/protocol-hardening-sweep-2026-04-16.md` for the detailed
221223
scope and verification record.

docs/audits/STATUS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ March 30 verified baseline.
101101
| Branch / PR | Scope | Current Head | Status | Evidence |
102102
|---|---|---|---|---|
103103
| `ramesh/broad-review-cleanup-20260416` / `#139` | Repo review-surface cleanup for TypeScript SDK and VSCode tooling | Branch head in PR | In Review | PR checks + local `npm run typecheck`, `npm run compile`, `npm run lint`, `npm test` |
104-
| `ramesh/protocol-hardening-sweep-20260416` / `#141` | Bridge relayer persistence and authority, burn nonce extraction, fail-closed zk proof and TEE/VM verification, authenticated simulated keeper attestations, deterministic simulated EZKL verification, deterministic simulated keeper zk proof binding, secure-by-default TEE precompile registry wiring, seal verifier fail-closed defaults, stateful seal revocation approval/execution, removal of the ordinary privileged seal-revocation bypass, narrowed raw keeper revoke entrypoints, quorumed emergency seal revocation, explicit authority enforcement on governance-only vault keeper methods, authority-gated non-overwritable relay liveness challenges with audit logging, loopback-by-default admin consensus-audit endpoint enforcement with explicit bearer-token authorization for remote exposure, truthful simulated/degraded health reporting with `503` reserved for genuinely unhealthy runtime posture, redacted public health diagnostics with detailed output gated to loopback or explicit token authorization, loopback-by-default metrics endpoint enforcement with explicit bearer-token authorization for remote scraping, forwarded proxy traffic no longer inheriting unauthenticated loopback trust on admin, metrics, or detailed health routes, fail-closed remote TEE endpoint validation across startup and health probing, fail-closed readiness endpoint probing for configured verifier targets, fail-closed EZKL remote prover/verifier endpoint validation, fail-closed DCAP collateral and CRL endpoint validation, fail-closed mirrored worker Nitro remote endpoint validation, fail-closed drand relay endpoint validation with bounded local fallback decoding, fail-closed TEE worker backend proxy endpoint validation, fail-closed lightweight attestation collateral backends, fail-closed TEE startup gating for real remote verifier modes, explicit simulated Nitro client identity with schema-consistent quote/proof artifacts, fail-closed Nitro payload confidentiality handling, fail-closed seal signature verification semantics, fail-closed seal export provenance semantics, honest PQC backend availability gating, fail-closed enhanced seal signature semantics, fail-closed seal import provenance semantics, aligned simulated TEE platform taxonomy across app and PoUW validation, ABCI vote-extension request binding for validator identity and height, runtime enforcement of locked PoUW governance parameters, governance compatibility and compliance alignment with runtime lock policy, auditable trusted-measurement registry mutations with legacy Nitro index reconciliation, bonded-quorum trusted-measurement emergency revocation, aligned security audit and threat-model narratives with the hardened production governance posture, cryptographic mempool signature enforcement, fail-closed VM job-registry proof verification, owner-bound sovereign payload encryption and fail-closed sovereign access control, validator slashing economic-penalty enforcement, timelock-safe automation keeper ownership, fail-closed non-local deployment authority resolution, real hybrid secp256k1 + Dilithium signer/verification in the worker runtime, governance bootstrap, Cruzible deployability | Latest branch head in PR | In Review | `docs/audits/protocol-hardening-sweep-2026-04-16.md` |
104+
| `ramesh/protocol-hardening-sweep-20260416` / `#141` | Bridge relayer persistence and authority, burn nonce extraction, fail-closed zk proof and TEE/VM verification, authenticated simulated keeper attestations, deterministic simulated EZKL verification, deterministic simulated keeper zk proof binding, secure-by-default TEE precompile registry wiring, seal verifier fail-closed defaults, stateful seal revocation approval/execution, removal of the ordinary privileged seal-revocation bypass, narrowed raw keeper revoke entrypoints, quorumed emergency seal revocation, explicit authority enforcement on governance-only vault keeper methods, authority-gated non-overwritable relay liveness challenges with audit logging, loopback-by-default admin consensus-audit endpoint enforcement with explicit bearer-token authorization for remote exposure, truthful simulated/degraded health reporting with `503` reserved for genuinely unhealthy runtime posture, redacted public health diagnostics with detailed output gated to loopback or explicit token authorization, loopback-by-default metrics endpoint enforcement with explicit bearer-token authorization for remote scraping, forwarded proxy traffic no longer inheriting unauthenticated loopback trust on admin, metrics, or detailed health routes, fail-closed remote TEE endpoint validation across startup and health probing, fail-closed readiness endpoint probing for configured verifier targets, fail-closed EZKL remote prover/verifier endpoint validation, fail-closed DCAP collateral and CRL endpoint validation, fail-closed mirrored worker Nitro remote endpoint validation, fail-closed drand relay endpoint validation with bounded local fallback decoding, fail-closed TEE worker backend proxy endpoint validation, fail-closed lightweight attestation collateral backends, fail-closed Nitro parser placeholder path, fail-closed ARM parser and signature placeholder paths, fail-closed TEE startup gating for real remote verifier modes, explicit simulated Nitro client identity with schema-consistent quote/proof artifacts, fail-closed Nitro payload confidentiality handling, fail-closed seal signature verification semantics, fail-closed seal export provenance semantics, honest PQC backend availability gating, fail-closed enhanced seal signature semantics, fail-closed seal import provenance semantics, aligned simulated TEE platform taxonomy across app and PoUW validation, ABCI vote-extension request binding for validator identity and height, runtime enforcement of locked PoUW governance parameters, governance compatibility and compliance alignment with runtime lock policy, auditable trusted-measurement registry mutations with legacy Nitro index reconciliation, bonded-quorum trusted-measurement emergency revocation, aligned security audit and threat-model narratives with the hardened production governance posture, cryptographic mempool signature enforcement, fail-closed VM job-registry proof verification, owner-bound sovereign payload encryption and fail-closed sovereign access control, validator slashing economic-penalty enforcement, timelock-safe automation keeper ownership, fail-closed non-local deployment authority resolution, real hybrid secp256k1 + Dilithium signer/verification in the worker runtime, governance bootstrap, Cruzible deployability | Latest branch head in PR | In Review | `docs/audits/protocol-hardening-sweep-2026-04-16.md` |
105105

106106
These branches are additive hardening tranches and do not reopen any finding
107107
that was already marked CLOSED on the March 30 baseline. They exist to reduce

docs/audits/protocol-hardening-sweep-2026-04-16.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -754,6 +754,39 @@ already merged.
754754
Intel and AMD lightweight-engine collateral paths under the
755755
`attestation-evidence` feature.
756756

757+
### 3zo. Nitro parser fail-closed hardening
758+
759+
- Tightened `services/tee-worker/nitro-sdk/src/attestation/aws_nitro.rs`,
760+
where the Nitro wrapper still returned a placeholder attestation document
761+
after only checking the outer COSE marker, leaving later verification steps
762+
to fail on fabricated empty fields.
763+
- `parse_document(...)` now fails closed with an explicit
764+
`AwsNitro("Nitro COSE/CBOR parsing backend is not implemented")` error
765+
instead of constructing fake attestation state that could be mistaken for a
766+
partially parsed real document.
767+
- Added a focused regression in
768+
`services/tee-worker/nitro-sdk/src/attestation/aws_nitro.rs` covering the
769+
fail-closed parse behavior under the `attestation-evidence` feature.
770+
771+
### 3zp. ARM attestation parser and signature fail-closed hardening
772+
773+
- Tightened `services/tee-worker/nitro-sdk/src/attestation/arm_trustzone.rs`,
774+
where the ARM TrustZone / CCA wrapper still relied on placeholder token
775+
parsing and signature-verification methods that returned success once a
776+
non-empty signature was present.
777+
- `parse_cca_token(...)` and `parse_psa_token(...)` now fail closed with
778+
explicit backend-unavailable errors instead of fabricating placeholder token
779+
state.
780+
- `verify_platform_signature(...)`, `verify_realm_signature(...)`, and
781+
`verify_tz_signature(...)` now fail closed with explicit
782+
`ArmTrustZone("...not implemented")` errors once signature presence has been
783+
checked, instead of returning `Ok(())` without real cryptographic
784+
verification.
785+
- Added focused regressions in
786+
`services/tee-worker/nitro-sdk/src/attestation/arm_trustzone.rs` covering
787+
fail-closed parser and signature paths under the `attestation-evidence`
788+
feature.
789+
757790
### 4. Cruzible deployability and reviewability
758791

759792
- Reduced `Cruzible.sol` deployed bytecode under the EIP-170 limit without
@@ -974,6 +1007,13 @@ already merged.
9741007
AMD collateral bundles that could be mistaken for partial verification state.
9751008
Those collateral paths now fail closed until a real fetch backend is wired
9761009
into that engine surface.
1010+
- The Nitro attestation wrapper no longer fabricates a placeholder parsed
1011+
document after only recognizing a COSE shell. Nitro parsing now stops
1012+
immediately with an explicit backend-unavailable error until a real CBOR/COSE
1013+
parser is wired in.
1014+
- The ARM attestation wrapper no longer fabricates placeholder token state or
1015+
report success from signature-verification methods that lack real crypto
1016+
backends. Its parser and signature paths now fail closed explicitly.
9771017
- The built-in security audit and threat model now describe the same hardened
9781018
governance posture the runtime enforces, which removes an internal
9791019
claim-vs-control mismatch around consensus threshold policy, one-way

0 commit comments

Comments
 (0)