Expand description
Signed atproto repository commits.
A commit is the signed mutable pointer: it binds an MST root CID (the
immutable record-store snapshot) to a DID at a revision, signed by the DID’s
#atproto P-256 key. This is what federation verifies to trust a host’s
claim about an account’s state — the consensus-free versioning primitive.
§Structure (atproto v3)
Commit {
did: String, // account DID (did:web / did:plc)
version: u64 = 3, // protocol version
data: Cid (link), // MST root
rev: String, // TID revision
prev: Option<Cid>, // previous commit (None for genesis)
sig: Vec<u8>, // ES256 signature over the unsigned commit
}§Signing
sig is ES256 (P-256 ECDSA over SHA-256) of the DAG-CBOR encoding of the
unsigned commit — the commit object with the sig field omitted (not
present-and-empty). The verifier re-encodes the unsigned form and checks the
signature against the DID’s published #atproto P-256 verifying key.
Structs§
- Commit
- A signed commit — the unsigned commit plus its ES256
sig. - Published
Atproto Key - A P-256 key published for commit verification, with a half-open validity interval. The active slot is unbounded; drain and lead slots must carry explicit document bounds.
- Published
Atproto Keys - A small, authority-checked set of verification keys from a DID document:
exactly one active
#atprotoslot and at most one bounded drain and lead slot. Unknown DID verification methods are intentionally ignored. - Unsigned
Commit - An unsigned commit — the form that gets DAG-CBOR-encoded and signed.
Constants§
- COMMIT_
VERSION - The commit version number (atproto v3).
Functions§
- atproto_
verifying_ key_ from_ did_ document - Resolve the active
#atprotoP-256 verifying key forexpected_did.