discourse/app/services/user
Isaac Janzen 4b9ee0bc05 SECURITY: Enforce edit permissions and audit trail in TriggerPostAction
The suspend/silence endpoint accepted an arbitrary post_id with
post_action "edit". Because the edit action had no guardian check,
a moderator could target any static doc post (ToS, guidelines, privacy
policy) — posts moderators are explicitly blocked from editing — even
ones unrelated to the user being suspended.

Add the missing can_edit_post? guardian check to the edit action,
consistent with the existing checks on delete and delete_replies.
2026-03-19 15:21:28 +00:00
..
action SECURITY: Enforce edit permissions and audit trail in TriggerPostAction 2026-03-19 15:21:28 +00:00
policy
bulk_destroy.rb DEV: Replace Ruby numbered parameters by it where applicable (#37810) 2026-02-13 13:59:07 +01:00
silence.rb DEV: Replace Ruby numbered parameters by it where applicable (#37810) 2026-02-13 13:59:07 +01:00
suspend.rb DEV: Replace Ruby numbered parameters by it where applicable (#37810) 2026-02-13 13:59:07 +01:00