You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 2a0afc1
Browse filesBrowse the repository at this point in the historyBrowse files
Five real-bug fixes from CodeRabbit + Devin review of #3499:
#1 personalAccessToken.server.ts: FALLBACK_NOT_INSTALLED_ERROR string
was 'RBAC fallback not installed' but the OSS fallback actually
returns 'RBAC plugin not installed'. The mismatch made every PAT
creation with a roleId hit the compensating-delete branch on
self-hosters with no plugin installed — including the dashboard
PAT-creation flow. Aligns the constant with the canonical string.
#2 internal-packages/rbac/src/fallback.ts: authenticateBearer skipped
the revoked-API-key grace window (RevokedApiKey table), so a
freshly-rotated env API key would 401 immediately on the new auth
path. Mirrors findEnvironmentByApiKey's fallback-to-RevokedApiKey
logic so the auth-cross-cutting e2e tests pass.
#3 api.v1.query.ts: multi-table queries built a plain RbacResource
array, which checkAuth treats as 'any element passes'. A JWT
scoped to one detected table could submit a query that also reads
another table it isn't scoped to. Wrap with everyResource — same
AND-semantics fix as the batch trigger routes.
#4 account.tokens/route.tsx: defaultRoleId could land on a custom or
plan-blocked role when userRoleId wasn't in the picker's assignable
set. The action's submit-revalidation would then 400 until the user
manually changed the dropdown. Clamp the default to roles the picker
actually renders.
#5 settings.team/route.tsx: the role Select used defaultValue, so a
failed set-role submit left the attempted role visible while the
server kept the old one. Switch to a controlled value bound to
currentRoleId.
0 commit comments