Skip to content

test(e2e): app-role grant helper + the finding that blocks role-scoped coverage - #77

Merged
rubenvdlinde merged 1 commit into
developmentfrom
wip/e2e-app-role-grants
Aug 1, 2026
Merged

test(e2e): app-role grant helper + the finding that blocks role-scoped coverage#77
rubenvdlinde merged 1 commit into
developmentfrom
wip/e2e-app-role-grants

Conversation

@rubenvdlinde

Copy link
Copy Markdown
Contributor

Groundwork for the role-scoped permission suites, plus the measured reason they remain blocked — see #76.

grantAppRoles() writes an Application's permissions block through OpenRegister's object API (there is no openbuild permissions endpoint), carrying the whole record forward because OR saves are PUT-semantic and omitted properties are dropped.

It works, and it is not enough. The grant lands and reads back correctly, group membership is right, and PermissionResolver::matchesCaller() handles group: principals — yet GET /api/applications returns 200 with an empty list for both the editor and the viewer. Something below openbuild's permission layer filters the object out, most likely OpenRegister-level object visibility. Full evidence in #76 and inline in the file.

Committed as groundwork rather than held back: it encodes the verified permission shape and the PUT-semantics trap, so whoever picks up #76 starts from measured facts. The role-scoped scenarios stay skipped until a member can actually see the app.

…d coverage

Groundwork for the role-scoped permission suites (versionRouting 9.2,
schema-access-scopes-rbac). Adds grantAppRoles(), which writes an Application's
`permissions` block through OpenRegister's object API — there is no openbuild
permissions endpoint — carrying the WHOLE record forward, because OR saves are
PUT-semantic and omitted properties are dropped rather than left alone.

It works, and is not enough. Measured on a live instance:

  - the grant lands and reads back as {owners:[user:admin],
    editors:[group:rbac-editors], viewers:[group:rbac-viewers]};
  - rbac-viewer is in rbac-viewers and rbac-editor in rbac-editors per OCS,
    and both groups exist;
  - PermissionResolver::matchesCaller() classifies `group:` principals and
    intersects them against the caller's groups, so the grammar is right;
  - yet GET /api/applications returns 200 with an EMPTY list for BOTH users.

Something below openbuild's permission layer filters the object out, most
likely OpenRegister-level object visibility — a separate grant from the manifest
permissions block. Filed as #76.

Committed as groundwork rather than held back: it encodes the verified
permission shape and the PUT-semantics trap, so whoever picks up #76 starts from
measured facts instead of re-deriving them. The role-scoped scenarios stay
skipped until a member can actually see the app.
@rubenvdlinde
rubenvdlinde merged commit 546a8c5 into development Aug 1, 2026
2 checks passed
@rubenvdlinde
rubenvdlinde deleted the wip/e2e-app-role-grants branch August 1, 2026 08:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants