Requiring collateral to be in cache on verification causes problems
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 35/100
- Issue type
- Feature
- Clarity
- Needs clarification
- Activity status
- Quiet
- Tech stack
- rust
- Domain
- networking, security
Research direction
Start by tracing the verifier function and how it currently requires collateral to be cached. Compare the synchronous-fetch and attester-side-fetch approaches described in the issue, including their effects on retries, payloads, and planned network-backed verification checks. Done means verification no longer requires a pre-warmed collateral cache and the chosen approach is covered by tests.
Written by the indexing model from the issue text.
Description
I've been trying to use this library to replace cvm-reverse-proxy for Flashbox. And needing to have the collateral already in cache for verification to pass is quite annoying. In the end i decided its safest to use the older EKM-based protocol for Flashbox.
The proxy client is generally targeting a single host (the proxy server) so it doesn't make sense to do a full PCCS 'pre-warm' and fetch all available collateral when we will only need one of them. So we rather have to do a failed connection (missing collateral), and then keep waiting and retrying. With a one second delay between retries, i currently need to wait till the third attempt to get a successful connection.
This feels cumbersome, inefficient and error prone, and like there must be a better way.
Worse still, we have planned additions to verification which will also require network fetch:
- Proof of cloud (fetch to GCP bucket to check if PPID present): https://github.com/flashbots/attested-tls/pull/54
- Checking for GCP signed firmware associated with an MRTD: https://github.com/flashbots/attested-tls/pull/47
Related issue: https://github.com/flashbots/attested-tls/issues/2
Possible solutions i am considering:
- Just doing a synchronous fetch during the verifier function. This is not ideal, but its made slightly better with
dcap-qvl's newColleratalClientapi which allows us to pass in a custom HTTP client (eg:ureq) and still use dcap-qvl collateral fetch code. Implemented in https://github.com/flashbots/attested-tls/pull/63 - Do collateral fetching on the attester side. That is, when generating an attestation, we also fetch collateral and include it in the payload. Good because we do just one fetch regardless of how verifications, even if the verifications are by different peers. Bad, because this is an API breaking change, increases payload size/complexity, diverges from standards, and is quite opinionated / use-case-specific. https://github.com/flashbots/attested-tls/pull/65
Personally i am leaning towards option 1.
cc: @0x416e746f6e
- Dominant language
- Rust
- Stars
- 6
- Forks
- 3
- Avg merge
- 4d 5h
- Merged PRs (30d)
- 7
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from flashbots/attested-tls
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
flashbots/attested-tls#97 ·
-
Difficulty 5/5 Over a week Newbie friendliness 45/100
flashbots/attested-tls#92 · 4 comments ·
-
Difficulty 3/5 1-2 days Newbie friendliness 68/100
flashbots/attested-tls#87 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
flashbots/attested-tls#84 · 7 comments ·
-
Difficulty 3/5 1-2 days Newbie friendliness 58/100
flashbots/attested-tls#82 · 1 comment ·
All issues in flashbots/attested-tls
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
stratum-mining/stratum#2404 ·
-
bug ci good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100