slack: enforce reaction notification policy [AI]#80907
Conversation
|
Codex review: needs real behavior proof before merge. Summary Reproducibility: yes. From source inspection, current main reads the Slack reaction policy into context but the reaction handler queues authorized reaction system events without checking it; a focused harness can set Real behavior proof Next step before merge Security Review detailsBest possible solution: Merge the narrow Slack handler fix after redacted real behavior proof is added and a maintainer approves the protected Slack policy change. Do we have a high-confidence way to reproduce the issue? Yes. From source inspection, current main reads the Slack reaction policy into context but the reaction handler queues authorized reaction system events without checking it; a focused harness can set Is this the best way to solve the issue? Yes, subject to proof. Gating in the Slack reaction handler with the existing allowlist helper before What I checked:
Likely related people:
Remaining risk / open question:
Codex review notes: model gpt-5.5, reasoning high; reviewed against f6d787cc5c1f. |
|
Not applicable to this automation stage; changelog/release-note and external real behavior proof requirements are handled outside auto-pr stages. Quoted comment from @clawsweeper:
|
Summary
reactionNotificationsandreactionAllowlistto control which reaction events can reach the agent event queue.off,own,all, andallowlistmodes before queueing system events.AI-assisted: Yes.
Change Type
Scope
Linked Issue/PR
Real Behavior Proof
extensions/slack/src/monitor/events/reactions.test.ts; command output was not collected.off,own, andallowlistbeforeenqueueSystemEvent(...).Root Cause
reactionModeandreactionAllowlist, but the handler did not consume them.Regression Test Plan
extensions/slack/src/monitor/events/reactions.test.tsoffdrops reaction events,ownonly allows reactions on bot-authored messages, andallowlistonly allows configured reaction senders.User-visible / Behavior Changes
Slack reaction webhook events now honor
reactionNotificationsandreactionAllowlistbefore reaching the agent system-event queue.Diagram
Security Impact
Yes/No): NoYes/No): NoYes/No): NoYes/No): NoYes/No): Yes, reducedYes, explain risk + mitigation: Reaction event text is now suppressed before queueing when the configured Slack reaction policy denies it. This narrows event flow and does not expand access.Repro + Verification
Environment
reactionNotificationsmodesoff,own,all, andallowlistSteps
reaction_addedorreaction_removedevent that passes base sender/channel authorization.Expected
Actual
Evidence
No command evidence collected in this constrained step.
Human Verification
off,own, andallowlist.ownmode requires the reacted message author to be the Slack bot user.Review Conversations
Compatibility / Migration
Yes/No): YesYes/No): NoYes/No): NoRisks and Mitigations
ownmode depends on Slack reaction events carrying the original message author.ownmode when the bot-authored message condition is not met, and existingallmode remains available for deployments that intentionally want broader reaction notifications.