Wire real permissions into collab tokens and revocation #53
Labels
No Label
area:auth
area:docs
area:export
area:ops
area:storage
area:supply-chain
auth
backend
blocked
collab
deployment
docs
effort:L
effort:M
effort:S
frontend
plugins
qa
vs-nfd
vs-nfd:blocker
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: stwaidele/dorfteich#53
Loading…
Reference in New Issue
Block a user
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?
Context
Live editing must obey the same rules as REST: token mode from the shared resolution, revocation via the M3 notify path.
Scope
Replace the interim check in the collab-token endpoint with the shared algorithm (mode
rwrequires editor+,rofor readers/public where granted); emit the pond-level NOTIFY on grant/label changes (#39's generic path); collab revalidates affected connections via a resolution call through an internal API endpoint (collab holds no own copy of the algorithm inputs).Acceptance criteria
rotoken where a public grant exists, none otherwiseTechnical notes
Dependencies
Depends on #39, #51, #52.
Size: ~1 day
Conventions: English code/comments, clear human-readable code, no hard-coded UI strings (ADR 0012, add
deanden), permission checks only via the shared guard (docs/architecture/permissions.md). Read the referenced ADRs before starting.Umgesetzt in
9d288b2(Claude Opus 4.8), Pipeline komplett grün (CI + CD: Deploy Test, Smoke, Int-Promotion), live auf Test und Int verifiziert.Was #53 liefert
rwab Editor,rofür Reader/Public — jetzt inkl. anonymer Besucher.GET /pages/:id/collab-tokenist@Public(), bleibt aber permission-guarded: ohne lesbaren Zugriff → 404 (Existenz versteckt), sonstro. Token-userIdist für anonyme Subjekte nullable (shared-Schema + collab-Context).pond_access_changed(#39) feuert jetzt auch bei Label-Tree-/Zuordnungs-Änderungen (LabelsServicemove/remove/assign/unassign).closeConnectionssendet nur eine App-Level-Close-Message — der Client bemerkte den Entzug erst nach seinem ~30 s Message-Timeout. NeucloseDocumentConnectionsschließt den echten WebSocket, sodass der Client sofort reconnectet und mit frisch aufgelöstem Token re-authentifiziert. Damit wird ein degradierter Editor innerhalb von Sekunden read-only — das AC, das der bisherige Mechanismus faktisch nicht erfüllte.Acceptance criteria
access-listener.db.test.ts: Edits des Degradierten erreichen den Peer nicht mehr) und im Browser-e2e-Packcollab-permissions(≈1 s).rowo ein Public-Grant existiert, sonst keinen (404). Live auf Int gegengeprüft (Anna legt Public-Reader-Grant an → anonymro→ Grant entfernt → 404).ro/404 ergänzt).Live-Checks
rw; anonym auf privater Seite → 404.collab-ben(Editor) →rw; anonym ohne Grant → 404; nach Public-Reader-Grant →ro; nach Entzug → 404. INT wieder auf Baseline (Grant entfernt).Tests: shared 107, web 50, api 152→+anon-Fälle, collab +Downgrade-Test; neuer Browser-Pack
collab-permissions(Reader-ro + Live-Downgrade) mit neuem regulärem Kontofixture-editor; alle grün in CI.