security(scoring): drop scoring-viewer read on program membership PII#351
security(scoring): drop scoring-viewer read on program membership PII#351gonzalesedwin1123 wants to merge 3 commits into
Conversation
The auto-installed spp_scoring_programs bridge granted spp_scoring.group_scoring_viewer read on spp.program.membership. That model _inherits res.partner, so the grant exposed registrant PII (identity, contacts, IDs, bank details, relationships, other programs/entitlements, enrollment state) to any scoring viewer via direct RPC, with no program or registry role and no record rule scoping to scoring-linked programs. Remove the membership ACL row. group_scoring_viewer's remit is scoring models and results; membership access is governed by spp_programs ACLs (as the module docs already state), so a scoring+program viewer is unaffected and a pure scoring viewer no longer reaches membership PII. The spp.program read grant is kept (scoring viewers legitimately see which programs use a scoring model). Bump 19.0.2.0.1 -> 19.0.2.0.2 + HISTORY. No migration (module unreleased; ACL changes reload on update). 11 tests (3 new, run as a pure scoring viewer).
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## 19.0 #351 +/- ##
==========================================
- Coverage 74.28% 67.40% -6.88%
==========================================
Files 372 98 -274
Lines 25385 8413 -16972
==========================================
- Hits 18857 5671 -13186
+ Misses 6528 2742 -3786
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
…rmat test Applies CI's pinned oca-gen output for the 19.0.2.0.2 changelog and ruff-format's formatting of the new access test.
…sers Add base.group_user so the AccessError on the membership read is provably attributable to the missing membership ACL (and matches a realistic scoring viewer, who is an internal user). Per staff-review nit.
|
Two independent staff reviews completed: SHIP / SOLID — membership PII vector fully closed, no regressions, clean implication chain, kept Review surfaced a separate, pre-existing PII exposure outside this PR's scope: a pure scoring viewer can read all |
Summary
The auto-installed bridge
spp_scoring_programsgrantedspp_scoring.group_scoring_viewerread onspp.program.membership. Thatmodel
_inheritsres.partner, so the grant exposed registrant PII — identity,addresses, email/phone, birth data, bank details, IDs, relationships, group
memberships, other programs, entitlements, enrollment state — to any
authenticated scoring viewer via direct RPC (
search_read), with no program orregistry role.
group_scoring_viewerimplies onlygroup_scoring_read, so thisACL was the sole source of the access, and the only membership record rules
(disabled-partner) do not scope it to scoring-linked programs or non-PII fields.
Fix
Remove the
access_spp_program_membership_scoring_viewerACL row. Membershipaccess is then governed solely by
spp_programsACLs — exactly as the module'sown docs state ("
spp.program.membershipaccess controlled byspp_programsmodule ACLs"):
AccessError).unaffected (access via
spp_programs), and still sees the score columns thebridge adds to the membership views.
spp.programread grant is kept — scoring viewers legitimately needto see which programs use a scoring model (
action_view_programs).No scoring-viewer flow needs membership read: the bridge's membership views are
inherited additions to
spp_programs' own form/list (reached via program-viewermenus), and the enrollment-score write path runs as a program manager, not a
scoring viewer.
Testing
./spp t spp_scoring_programs→ 11 passed, 0 failed, 0 errors (3 new, runas a pure
group_scoring_viewer).AccessErrorreading a membership(fails before the fix); can still read
spp.program; and a scoring+programviewer can still read memberships.
Notes for reviewers
spp_scoring_programsis not in any released tag, and ACLchanges reload on module update regardless (removing the row drops the access).
scoping to scoring-linked programs would still expose full
res.partnerPIIfor those members; a non-PII summary surface is a feature, not a fix, and
would belong in its own change. Removal matches the documented access model.
Draft: awaiting human security review before undraft/merge.