operator-video: kanidm writes role=administrator but the PeerTube plugin parseInt()s it #1632
Labels
No labels
agent-blocked
agent-working
autopilot
bug
deferred
deploy-pending
enhancement
landing-pr
model-haiku
model-opus
model-sonnet
needs-design
needs-info
needs-triage
no-triage
out-of-scope
priority
ready-for-agent
ready-for-human
ready-for-session
rehearsal-183
snapshot-pending
standing-drive
wayfinder:grilling
wayfinder:map
wayfinder:prototype
wayfinder:research
wayfinder:task
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Reference
Matou/idss#1632
Loading…
Add table
Add a link
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?
The failure
operator-videois the drive's only red — 36 green, 1 red, 0 skips. This is not the KNOWN own-VPS pairing frontier:pairran green (202 ms) andlegs.jsoncarries no skip reasons at all.The granted operator signs into PeerTube through the community IdP fine, but lands as an ordinary User instead of Administrator, so the admin-only config endpoint refuses them.
artifacts/verdict.json:artifacts/legs.json:The evidence that names the defect
The claim pipeline works end to end — kanidm does emit the
roleclaim for the operator. The plugin then throws it away because of its type.logs/droplet-journal.txt:1822, during the operator's sign-in:…and two seconds later, the same journal at line 1860:
The member's sign-in produces the benign twin at 14:20:25 —
Cannot load role undefined from OpenID: not a number.— which is by design (no claim → plugin default User), and is whymember-videostayed green.Live box (209.38.88.34): the access line given in the prompt was refused —
root@209.38.88.34: Permission denied (publickey,keyboard-interactive)— the box takes only the run's own key, harvested atartifacts/live-box.json→state/rent-operator/id_ed25519. Read-only queries through that key confirm both halves:proof_operatoris role 2 (User). PeerTube'sUserRoleis numeric —0= Administrator (confirmed on this very box byroot|0),1= Moderator,2= User.And the plugin's own parse, read off the closure-placed copy at
/var/lib/peertube/storage/plugins/node_modules/peertube-plugin-auth-openid-connect/dist/main.js:344-353:The emitter is ours,
internal/clan/video.go:619(renderVideoOIDC):So: we write the string
administrator; the pluginparseInts it →NaN→role = null→ PeerTube's default User → 403 on right No. 8. Thessvjoin (line 620) and the operators-group keying are both correct and doing their job; only the claim's value encoding is wrong.The panel meanwhile promises what the deploy doesn't deliver —
artifacts/roles/detail-proof-operator-granted.json:Suspected layer
Product — a one-value defect in the render, not harness flake and not infra. The harness asserted exactly the right thing; the droplet did exactly what the rendered oneshot told it to.
What plugging it needs
internal/clan/video.go:619— write PeerTube's numericUserRoleinstead of the name:kanidm system oauth2 update-claim-map "$client" role operators 0 --name idm_adminMembers keep no
roleclaim, soparseInt(undefined)→NaN→null→ PeerTube default User; that path is already drive-proven green, leave it alone.administrator, plus the prose that encodes the claim value:internal/clan/video.golines 51, 523, 561, 615, and the#1544entry inSTATUS.md.docs/GOTCHAS.mdentry alongside the fix —peertube-plugin-auth-openid-connect'srole-propertyis numeric-only, and it fails silently (logs an error, then signs the user in anyway at the default role), so only an admin-endpoint probe like this leg catches it.operator-videoto confirmproof_operatorcomes back as role0.Secondary observation (not the red, no assertion touches it)
artifacts/roles/detail-proof-operator-after-redeploy.json(14:18:39) lists onlyfilesinaccess[], whiledetail-proof-operator-granted.json(14:13:25) listedfilesandvideo. The video access row vanished from the panel's person detail acrossredeploy-services, even thoughartifacts/roles/world.jsonstill listsvideoamong services. It did not cause this red — the journal proves the operator was still in theoperatorsgroup and still got the claim written at 14:20:16 — but it may be a second, separate drift worth its own look.drive
20260919T132005Zred atoperator-video:video: the granted operator is NOT admin — /api/v1/config/custom answered 403 (not-admin): {"type":"about:blank","title":"Forbidden","detail":"User proof_operator does not have right (No. 8) to acceevidence:
/home/dev/swarm/Matou/idss/test-results/drive-rented-services/20260919T132005Zon matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was capturedswarm-claim host=bens-mac-04 run=27582
(automated multi-host claim — lowest live claim id works this ticket)
close-report for #1632 — status
success✅ close-report gates passed — every claim verified against main; issue closed.
envelope