Replies: 8 comments 17 replies
-
The API endpoint could just return metadata and location(s) for the binary data, maybe something along the lines of: {
"hash_algorithm": "sha256",
"sources": [
{
"content_type": "application/vnd.bytecodealliance.registry.ledger.packed", // or something
"start_index": 0,
"end_index": 10000,
"urls": ["https://my.blob.store/ledger/abcdefg/0-10000.bin"],
},
{
"content_type": "application/vnd.bytecodealliance.registry.ledger.packed",
"start_index": 10001,
// no end_index; still being "filled"
"urls": ["https://my.blob.store/ledger/abcdefg/10001-latest.bin"],
},
]
} |
Beta Was this translation helpful? Give feedback.
-
Another useful thing a registry can do here (probably a "should" but not "must"): if an invalid checkpoint is received with a valid signature, it should complain loudly, e.g. by sending an email to some list. |
Beta Was this translation helpful? Give feedback.
-
My hunch is that this isn't necessary. A monitor will already need to have replayed history and reconstructed all possible verifiable maps in order to validate correct behavior; it can either store every valid checkpoint or - if necessary - store snapshots of the log/map state every e.g. 1000 updates and replay history from the closest snapshot. |
Beta Was this translation helpful? Give feedback.
-
Proposed API Changes:For Monitors & Registries:
|
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
This is based upon the assumption that only recent checkpoints are sent to a monitor for verify requests. Not sure about the value of verifying old checkpoints, but let me know if you feel otherwise. Monitors respond to client requests to verify a registry's Since registries don't necessarily produce a checkpoint after every Thoughts? |
Beta Was this translation helpful? Give feedback.
-
This structure with |
Beta Was this translation helpful? Give feedback.
-
I'm OK with that. Updated. |
Beta Was this translation helpful? Give feedback.
-
Background
Monitors in Certificate Transparency "watch logs and check that they behave correctly". They verify things that may be impossible or impractical for every client to verify for themselves.
Introduction
In Package Transparency, monitors watch different logs and check different things than in Certificate Transparency but abstractly fill an analogous role.
In the protocol as discussed to this point, monitors are expected to verify two distinct things:
Because the state of the registry could theoretically diverge into two valid histories in the event of a compromised or malicious registry performing a fork attack, checking in with monitors provides a way for everyone to know they are working from the same history.
Proposal
POST /v1/verify/checkpoint
Request body is the signed timestamped checkpoint envelope to be verified. Request header that specifies the the registry domain of the checkpoint. Response is success status code or error status code with an error messsage.
GET /v1/fetch/ledger/{startingRegistryIndex}
Response is the series of
[[RegistryIndex, LogId, RecordId]]
. Or this could be endpoint that provides URLs to binary blobs which support HTTP Range header requests? However, I'm unsure if this would be hash algo independent.Do we require a registry API endpoint to fetch the series of
RegistryLen
values corresponding to thelogLength
for every registry checkpoint?The Warg CLI client can set monitors for a registry. After a new checkpoint is fetched, the client will send a request to a monitor for independent checkpoint verification.
Just a quick thank you to @esoterra for helping with intro and background.
Beta Was this translation helpful? Give feedback.
All reactions