Skip to content

Negative vectors: embedded-key rejection (pairs with @veritasacta/verify 0.4.0)#5

Open
tomjwxf wants to merge 1 commit into
mainfrom
negative/embedded-key-rejection
Open

Negative vectors: embedded-key rejection (pairs with @veritasacta/verify 0.4.0)#5
tomjwxf wants to merge 1 commit into
mainfrom
negative/embedded-key-rejection

Conversation

@tomjwxf

@tomjwxf tomjwxf commented Apr 19, 2026

Copy link
Copy Markdown
Contributor

What this adds

Four fixtures under negative/embedded-key-rejection/ that a conformant implementation of draft-farley-acta-signed-receipts MUST reject when no external key source is provided.

Fixture Shape
001 Passport envelope with payload.public_key
002 v1 flat artifact with top-level public_key
003 v2 structured with payload.verification_key
004 Passport envelope with payload.verification_jwk (full JWK)

Each carries a valid-looking Ed25519 signature (placeholder hex, not real crypto) that would verify cleanly if the verifier accepted embedded keys. The rejection is a policy check preceding signature validation. A signature that verifies under an attacker-chosen key is strictly worse than no signature at all.

Why

@desiorac surfaced the gap publicly on GetBindu PR #459 last week. Root cause: draft-farley-acta-signed-receipts-01 is silent on key distribution, which permits implementers to add an embedded-key fallback that violates the issuer-blind property the spec is designed to provide.

This PR pairs with:

  • @veritasacta/verify 0.4.0 (coming this week) — rejects embedded keys by default, deprecated --allow-embedded-key escape hatch for one release cycle.
  • draft-farley-acta-signed-receipts-02 (coming this week) — adds the normative MUST NOT in Security Considerations.

Together these three artifacts close the gap across spec, reference verifier, and conformance surface.

Expected verifier outcome

For all four fixtures, a 0.4.0+ verifier invoked as:

npx @veritasacta/verify <fixture>.json

MUST exit with status 2 (undecidable) and emit an error identifying the embedded-key pattern as the reason.

With --allow-embedded-key (deprecated, 0.4.x only): verifier accepts the embedded key for backward compatibility during migration. Tests at this mode pass signature verification against the (placeholder) signature, which fails for unrelated reasons since the signatures in fixtures are placeholder hex.

Verification

  • All four JSON files parse as valid JSON
  • _meta block on each fixture documents expected outcome
  • README explains rationale and cross-links spec/verifier/desiorac thread
  • Rejection is policy-layer, not signature-layer (attacker-chosen sig would verify clean against attacker-chosen key; that's the point)

Related

…ify 0.4.0)

Adds four fixtures under negative/embedded-key-rejection/ that a conformant
implementation of draft-farley-acta-signed-receipts MUST reject when no
external key source is provided:

  001 — Passport envelope with payload.public_key
  002 — v1 flat artifact with top-level public_key
  003 — v2 structured with payload.verification_key
  004 — Passport envelope with payload.verification_jwk (full JWK)

Each fixture carries a valid-looking Ed25519 signature (placeholder hex,
not real crypto) that would verify if the verifier accepted embedded
keys. The rejection is a policy check preceding signature validation,
not a signature-validity check. A signature that verifies under an
attacker-chosen key is worse than no signature at all.

Pairs with:

  - @veritasacta/verify 0.4.0 (rejects embedded keys by default,
    deprecated --allow-embedded-key escape hatch for 0.4.x only)
  - draft-farley-acta-signed-receipts-02 Security Considerations
    (normative "MUST NOT accept a verification key transported inside
    the receipt unless independently anchored")

Triggered by the desiorac review on GetBindu PR #459 that publicly
surfaced the gap.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.

2 participants