[security] Mass assignment fix sweep
fix: [security] Mass assignment fix sweep
[security] Mass assignment fix sweepab9619-fix-security-mass-assignment-fix-sweep-cve-2026-56422fixsecurity mass assignment fix sweep
Committed by iglocska
commit message
fix: [security] Mass assignment fix sweep
EventReports: editReport() saved a body-supplied sharing_group_id without
validating the user's access to it (milestone EventReports of the
mass-assignment audit).
- editReport() saves with fieldList CAPTURE_FIELDS (which includes
sharing_group_id) but, unlike the add path (captureReport->captureSG), never
ran the sharing-group access check. A perm_add user editing a report on their
own event could set distribution=4 + an arbitrary sharing_group_id they have
no access to, re-scoping the report to a sharing group they cannot see (the
add path correctly downgrades such a report to distribution=0/sg=0 via
captureSGForElement->checkIfAuthorised). Fixed by running the same
captureSG($user, $report) before the save in editReport, matching
captureReport. Live before/after proven (inaccessible SG -> downgraded to
0/0; an accessible SG is preserved, so legitimate edits still work).
- as reported by Jeroen Pinoy
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>Editor assessment
This commit patches CVE-2026-56422. The body focuses on editReport(), where saving with CAPTURE_FIELDS included sharing_group_id but skipped the sharing-group access check that the add path performs through captureSG. It states the consequence plainly, allowing a user to re-scope a report to a group they cannot see, and presents the fix as running the same captureSG call before save. The before-and-after proof covers both the downgraded inaccessible group and the preserved accessible one, so the edge behavior is verified. A clear, well-evidenced entry; only the repeated sweep title dates it.