Skip to content

feat(validator): only issue shares for validated transactions - #2533

Open
sergerad wants to merge 1 commit into
sergerad-validator-admin-listfrom
sergerad-validator-share-hardening
Open

feat(validator): only issue shares for validated transactions#2533
sergerad wants to merge 1 commit into
sergerad-validator-admin-listfrom
sergerad-validator-share-hardening

Conversation

@sergerad

@sergerad sergerad commented Aug 31, 2026

Copy link
Copy Markdown
Collaborator

Summary

Part 3 of a 4-PR stack formalizing the validator admin API (#2455).

The share endpoint would issue a decryption share over any well-formed ciphertext, acting as an unrestricted decryption oracle.

  • Adds PrivateRecordContext::try_from_bytes, a strict parser for the canonical v1 context (domain tag, field lengths, format version, canonical transaction id), with round-trip and rejection tests for every failure path.
  • POST /admin/v1/decryption-share parses the transaction id out of the request's decryption context and refuses (404) unless this validator itself validated that transaction. The context is cryptographically bound to the ciphertext, so an arbitrary ciphertext cannot be smuggled under a validated transaction's context. Cross-validator recovery keeps working: every validator in the quorum validated the transaction, and each still issues shares over ciphertexts it does not store.
  • map_share_error now matches PrivateRecordError exhaustively, so a new variant — or a golden-ehtdh1 upgrade that introduces a new failure — must be classified rather than silently becoming a 500.

Stack: #2531#2532#2533#2517

Changelog

[[entry]]
scope       = "validator"
impact      = "changed"
description = "The validator admin decryption-share endpoint refuses to issue shares for transactions the validator has not itself validated."

@sergerad sergerad changed the title sergerad validator share hardening feat(validator): only issue shares for validated transactions Aug 31, 2026
@sergerad
sergerad force-pushed the sergerad-validator-share-hardening branch 2 times, most recently from 649a1e4 to 5808530 Compare August 31, 2026 02:28
@sergerad
sergerad marked this pull request as ready for review August 31, 2026 02:34
@sergerad
sergerad force-pushed the sergerad-validator-share-hardening branch from 5808530 to 86dc8f1 Compare August 31, 2026 02:50
The share endpoint would issue a decryption share over any well-formed
ciphertext, acting as an unrestricted decryption oracle. Parse the
decryption context (new canonical parser with strict domain, length,
version, and transaction-id checks) and refuse unless it references a
transaction this validator itself validated. Cross-validator recovery
keeps working because every validator in the quorum validated the
transaction. Share errors are now classified exhaustively so a new
error variant must be triaged instead of silently becoming a 500.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@sergerad
sergerad force-pushed the sergerad-validator-share-hardening branch from 86dc8f1 to 7b992c6 Compare August 31, 2026 02:59
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