You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
test+docs: hinted P-384 review tests and forward-compat documentation
Follow-up to #28 (hinted P-384 Nitro attestation verification). Adds focused
tests covering hint-verification soundness and signature/cache/replay
semantics, and documents the attestation parser's forward-compatibility
limitations, which were previously undocumented.
Tests (added to existing files, reusing the real fixture and helpers):
- HintedNitroAttestation.t.sol: non-canonical (unreduced) inverse hint is
sound, modulus-confusion hint reverts, corrupted signature never accepts
under any hint stream, malleable twin (r, n-s) is accepted, and there is no
on-chain anti-replay. Adds a U384TestWrapper to exercise the hinted U384
primitives (modinv / moddivAssign) directly.
- IndefiniteLengthCbor.t.sol: skipped forward-compat specs for unknown-key
tolerance and nested indefinite-length pcrs parsing, co-located with the
regression tests that pin current behaviour.
- CertManager.t.sol: skipped spec documenting the verifiedParent
first-writer-wins cache-griefing edge (requires a same-key-renewed CA
fixture to realise).
Docs:
- docs/hinted-p384-nitro-attestation.md: new "Forward-compatibility" section.
- README.md: forward-compatibility note under Security considerations.
- NitroValidator.sol: NatSpec on _parseAttestation recording that the strict
key whitelist / lack of nested indefinite-length support is liveness-only
(can only revert, never a false accept) but forward-incompatible with AWS
attestation-format changes.
No production logic changes; src edits are NatSpec/comments only.
Generated with Claude Code
Co-Authored-By: Claude <noreply@anthropic.com>
0 commit comments