chadtmiller.com/group-host
atmosphere group host
0
0
Service auth is checked with atproto-client 0.7.1's verify_with
Merged Approved
This moves service_caller and the import token's proof from verify_any to atproto-client 0.7.1's verify_with, and makes Resolver::with_key report an unresolvable issuer as BadJwtIss. I read every changed file and found nothing that needs changing.
service_caller: Theoursclosure isFn(&str)now. Its refusal is kept in aMutexand returned in place of the crate's generic error, soBadJwtAudienceandForbiddenstill come out as before.UnresolvedandNoKeyboth becomeBadJwtIss.proof: Dropping the pre-check ofaudandlxmis fine.verify_withtakes the audience predicate andCREATE_ACCOUNT, so a wrong audience or method is still refusedInvalidToken. Only the message text differs.UnresolvedisInvalidRequestagain, and the test now expects that.- Space credentials:
checked.map_err(no_key)?.map_err(refused)?matches the new nested result. - Change file and lockfile: The change file is present.
Cargo.lockmovesatprototo 0.4.4 andatproto-clientto 0.7.1, andCargo.tomlasks foratproto-client0.7.1.
The PR body says nothing was compiled locally. The check, test and e2e runs were still queued or running when I looked, so I haven't seen them pass. Please read check and test (fmt, clippy and the 100% coverage gate) before merging. The new Unresolved arm in proof and the (Some(refused), _) and BadJwtIss arms in service_caller each need a test that reaches them.
All checks have passed
9 passed
Merged as 184f600
What changes
Service auth by
verify_with.service_caller(the host's own methods,notifyRepoUpdate,notifyCredentialsRevoked) and the account-import token are checked with atproto-client 0.7.1'sverify_with, which judges the audience itself, in place of reading the token's unverified audience and passing it toverify_any.service_caller'soursnow takes the audience; its refusal (BadJwtAudience,Forbidden) is still the answer for an audience it does not take. An issuer that can't be resolved, or names no key, isBadJwtIss.The import token answers as before 0.6. An account's token for moving here whose DID can't be resolved is
InvalidRequestagain (Error::Unresolved); one naming no key, or not signed by it, staysInvalidToken. The test changed for 0.6 expectsInvalidRequestagain.Space credentials.
Resolver::with_keynow answersResult<Result<..>, identity::Error>: an unresolvable issuer isBadJwtIss, with why.Why
0.6's
verify_anycould not tell an unresolvable issuer from one with no key, and took only a list of audiences, so the host pre-read unverified claims to build one. 0.7 adds both; 0.7.1 makes its futuresSend.How it was checked
cargo checkwas blocked locally by the registry's rate limit on the 0.7.1 download; build, tests and the gate are left to CI.