AtProtoOAuthClient: dead unreachable 401 checks in PAR, token exchange, refresh #43
Labels
No labels
auth
bug
composer
correctness
database
durability
enhancement
feeds
interactions
notifications
performance
reliability
safety
security
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starsetbyte/peregrine#43
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
Three sites in
AtProtoOAuthClienthave redundant/unreachable 401 checks after the outer if-else already handles all 400/401 cases:beginLogin()line 164 — outer if caught 400||401, inner if caught use_dpop_nonce, so line 164 is always-truecompleteLogin()line 254 — same patternrefreshSession()lines 313+316-319 — same outer pattern plus a second unreachable 401 block after the firstFix
Removed the redundant 401-only checks. Now all three sites use a single
throwafter the use_dpop_nonce retry path:Fixed in PR #36.