Repository navigation
feat(approach): Private Oracles - #217
Darkjay123 wants to merge 4 commits into
Conversation
Fills the Approach TBD gap on private-oracles (issue ethsystems#138). Adds the approach card comparing private information retrieval, TEE-served encrypted queries and batched delivery with anchored provenance; links the use-case card and adds the changelog entry.
rymnc
left a comment
There was a problem hiding this comment.
thank you for your contribution! left some comments inline
| uses_patterns: [pattern-tee-based-privacy, pattern-tee-key-manager] | ||
| ``` | ||
|
|
||
| **Summary:** Queries arrive encrypted to a key held inside a Trusted Execution Environment; the enclave resolves and serves them without the operator observing content or requester. |
There was a problem hiding this comment.
the operator runs the network edge, so it sees which consumer connects, when and how often. pattern-tee-based-privacy says that the host controls every byte that crosses the enclave boundary. #218 says the same at approach-private-read.md line 94. so "or requester" does not hold. the requirement at line 23 to hide the query source has no mechanism in this card.
suggestion: remove "or requester", and add pattern-network-anonymity or pattern-mixnet-anonymity for the source.
| **Summary:** Queries arrive encrypted to a key held inside a Trusted Execution Environment; the enclave resolves and serves them without the operator observing content or requester. | |
| **Summary:** Queries arrive encrypted to a key held inside a Trusted Execution Environment; the enclave resolves and serves them without the operator reading query content. The operator still sees which consumer connects, and when. |
| maturity: documented | ||
| context: both | ||
| crops: { cr: high, o: partial, p: full, s: medium } |
There was a problem hiding this comment.
these values differ from pattern-private-information-retrieval. the pattern is maturity: research, o: yes and s: high. it also says that cr drops to low when a single operator holds the only copy of the database. that is the oracle case: the matrix says "dataset hosting" at line 148. #218 marks its pir path concept.
suggestion: use maturity: concept and the pattern scores, or say why this card differs. then update the rationale at line 71 and the matrix at lines 142 and 144.
|
|
||
| **Summary:** The consumer fetches a record from the oracle's dataset without the serving infrastructure learning which record was fetched. | ||
|
|
||
| **How it works:** The oracle publishes an indexed dataset (price history, reference data). The consumer runs a PIR query: the server processes an encrypted query vector and returns a response the client decrypts to exactly the requested record, while the server learns nothing about which index was read. Batching many consumers' queries shares server cost, and update streams keep the dataset fresh between republications. |
There was a problem hiding this comment.
batching does not share the per-query server work. simplepir says that "the server must touch every bit of the database to answer even a single client query". clients share a preprocessing hint, which is 121 mb for a 1 gb database. after an update, the server must repeat some of the preprocessing. for price data, updates are frequent, so update cost is the binding cost.
suggestion: name the mechanism that amortizes cost, and state the hint download and the update cost. the "client light" cell at line 147 then needs the hint too.
| - Single-server PIR rests on computational assumptions; multi-server variants need non-colluding operators | ||
|
|
||
| **Threat model:** | ||
| - Timing or size side channels leak which record was fetched |
There was a problem hiding this comment.
simplepir says that "the server must touch every bit of the database to answer even a single client query". so a correct server's timing does not depend on the index. the leak is when queries happen and how often, which shows intent.
suggestion:
| - Timing or size side channels leak which record was fetched | |
| - Query timing and rate leak trading intent; non-oblivious implementations may also leak the index |
| - Read patterns are heavy and repeated, amortizing server cost | ||
|
|
||
| **Avoid when:** | ||
| - The consumer needs proof the served value is fresh and correct, not just unseen |
There was a problem hiding this comment.
line 24 requires integrity and freshness for every consumer. so this avoid-when rules out pir for every oracle use. pattern-private-information-retrieval pairs pir with a separate integrity anchor. that also answers open question 4 at line 188.
suggestion: add a signed snapshot or a state-root anchor to how it works, and remove this bullet.
| ### Constraints | ||
|
|
||
| - Trading-grade latency rules out heavyweight proving on the hot path | ||
| - Multiple providers must aggregate without a single trusted party |
There was a problem hiding this comment.
no sub-approach aggregates across providers. every column has an operator at line 148, and the tee default is one trusted party. the use case also requires hiding individual provider contributions at line 58. but line 117 attests the contributing providers, and line 126 lists attribution only as a threat. problem 2 of the use case (provider revenue) does not appear in the card.
suggestion: add a threshold or mpc aggregation sub-approach, or move these to open questions.
| uses_patterns: [pattern-verifiable-attestation, pattern-commit-and-prove] | ||
| ``` | ||
|
|
||
| **Summary:** Queries hide inside aggregate delivery rounds and provider provenance is attested on-chain, so neither consumption patterns nor data origin leak at the individual level. |
There was a problem hiding this comment.
this summary says that neither consumption patterns nor data origin leak. the rationale at line 136 says that cadence and volume leak. the provider attestations at line 117 also show data origin. line 161 also calls this model orthogonal to the other two. so it is a layer over them, but the matrix compares it as a third option.
suggestion:
| **Summary:** Queries hide inside aggregate delivery rounds and provider provenance is attested on-chain, so neither consumption patterns nor data origin leak at the individual level. | |
| **Summary:** Feeds publish in fixed rounds with provider provenance attested on-chain, so a consumer's individual queries hide inside a round, while round cadence, volume and the set of contributing providers stay visible. |
|
|
||
| ### Default | ||
|
|
||
| For an institutional consumer buying reference data with latency requirements, TEE-served encrypted queries are the default: they hide query content from the operator with production-grade latency and add little beyond the hardware trust a conventional oracle already implies. |
There was a problem hiding this comment.
the card gives no source for "the hardware trust a conventional oracle already implies". pattern-tee-based-privacy says that tee-only deployments suit only pilots or low-value operations. so the tee default adds a hardware-vendor trust anchor. "production-grade latency" also conflicts with maturity: documented.
suggestion:
| For an institutional consumer buying reference data with latency requirements, TEE-served encrypted queries are the default: they hide query content from the operator with production-grade latency and add little beyond the hardware trust a conventional oracle already implies. | |
| For an institutional consumer buying reference data with latency requirements, TEE-served encrypted queries are the default: they hide query content from the operator without proving on the hot path, at the cost of a hardware-vendor trust anchor. |
|
|
||
| ### Decision factors | ||
|
|
||
| - If the operator itself cannot be trusted with any query visibility, use private information retrieval instead. |
There was a problem hiding this comment.
pir hides which record is read. pattern-private-information-retrieval says that the server still learns that a query was issued and the query rate.
suggestion:
| - If the operator itself cannot be trusted with any query visibility, use private information retrieval instead. | |
| - If the operator must not learn which record is read, even under a hardware compromise, use private information retrieval instead. |
|
|
||
| ## [Unreleased] | ||
|
|
||
| - feat(approach): [Private Oracles](approaches/approach-private-oracles.md), filling the "Approach TBD" gap on [Private Oracles](use-cases/private-oracles.md), whose recommended-approaches section now links to the card. Compares private information retrieval (documented, I2I+I2U), TEE-served encrypted queries (documented) and batched delivery with anchored provenance (documented, I2I), with a 10-row comparison matrix, persona perspectives, a conditional recommendation and open questions. |
There was a problem hiding this comment.
the entry has no pr link. .claude/CLAUDE.md asks for one.
suggestion:
| - feat(approach): [Private Oracles](approaches/approach-private-oracles.md), filling the "Approach TBD" gap on [Private Oracles](use-cases/private-oracles.md), whose recommended-approaches section now links to the card. Compares private information retrieval (documented, I2I+I2U), TEE-served encrypted queries (documented) and batched delivery with anchored provenance (documented, I2I), with a 10-row comparison matrix, persona perspectives, a conditional recommendation and open questions. | |
| - feat(approach): [Private Oracles](approaches/approach-private-oracles.md), filling the "Approach TBD" gap on [Private Oracles](use-cases/private-oracles.md), whose recommended-approaches section now links to the card. Compares private information retrieval (documented, I2I+I2U), TEE-served encrypted queries (documented) and batched delivery with anchored provenance (documented, I2I), with a 10-row comparison matrix, persona perspectives, a conditional recommendation and open questions. ([#217](https://github.com/ethsystems/map/pull/217)) |
- PIR sub-approach: maturity concept and the pattern's own scores (CR low single-operator case, O yes, S high); rationale and matrix updated - batching economics stated: server touches every bit per query, 121 MB hint per 1 GB dataset, update cost binds for price data - threat model: timing and rate leak trading intent; non-oblivious implementations may leak the index - integrity: pair PIR with a signed snapshot or state-root anchor; drop the avoid-when bullet that ruled PIR out of every oracle use - TEE sub-approach: operator still sees which consumer connects and when; drop pattern-tee-key-manager (signing-key misuse, same as ethsystems#218); add pattern-network-anonymity for the source; single-operator score set CR low/O partial/P partial/S medium - batched delivery: pattern-commit-and-prove replaced with pattern-mixnet-anonymity; pattern-zk-tls dropped from frontmatter; disclosure-keys pattern added for scoped regulator access - cross-provider aggregation moved to an open question - default and decision-factor summaries aligned with the review's suggested wording - changelog entry gains its PR link
- scenario: peers never see RPC reads; the eth wire protocol carries no read messages - institution-run nodes: transaction history needs a self-hosted indexer; third-party indexer queries added to the threat model; broadcasts reveal the node IP, paired with pattern-private-transaction-broadcasting - TEE-hosted RPC: provider sees who queries, when and how much; ORAM needed to hide which state the enclave reads; drop pattern-tee-key-manager (signing-key misuse); add pattern-tee-network-anonymity and link it - single-operator TEE score set (CR low/O partial/P partial/S medium), consistent with ethsystems#217; rationale and matrix updated - obfuscated aggregate reads: gateway sees sender and timing; PIR hides only the record; honest no-deployments maturity and high server-compute cost - use-case recommended-approaches section rewritten per review; changelog entry gains its PR link
…acles # Conflicts: # CHANGELOG.md
Fills the "Approach TBD" gap on the Private Oracles use case from issue #138.
What this adds
New approach card Private Oracles (
approaches/approach-private-oracles.md) comparing three sub-approaches:Each sub-approach carries CROPS scores with written justification; the card follows the v2 template (issue #151) with the 10-row comparison matrix, persona perspectives, a conditional recommendation and open questions.
Accompanying changes
use-cases/private-oracles.md: the "Approach TBD" recommended-approaches section now links the card (architectural considerations kept).CHANGELOG.md:[Unreleased]entry in the style of the recent approach PRs.Checks
All six required v2 sections present, title prefix and frontmatter complete, body word count within the documented approach limit. The Vale prose gate runs in CI.
Part of #138.