Skip to content

Harden MPA approver dedup and action IDs - #635

Open
sfc-gh-ikryvanos wants to merge 1 commit into
mainfrom
ikryvanos/mpa-approval-hardening
Open

Harden MPA approver dedup and action IDs#635
sfc-gh-ikryvanos wants to merge 1 commit into
mainfrom
ikryvanos/mpa-approval-hardening

Conversation

@sfc-gh-ikryvanos

Copy link
Copy Markdown
Collaborator
  • Compare approver groups as an order-independent set so the same principal cannot be recorded as multiple approvers by reordering their groups (previously an order-sensitive reflect.DeepEqual).
  • Use the full 256-bit SHA-256 digest for action IDs instead of a truncated 96-bit prefix, and bind Store/Approve to the exact action content (proto.Equal) so a hash collision cannot let an approval apply to a different action. Existing IDs remain a prefix of the new ones.

- Compare approver groups as an order-independent set so the same
  principal cannot be recorded as multiple approvers by reordering
  their groups (previously an order-sensitive reflect.DeepEqual).
- Use the full 256-bit SHA-256 digest for action IDs instead of a
  truncated 96-bit prefix, and bind Store/Approve to the exact action
  content (proto.Equal) so a hash collision cannot let an approval
  apply to a different action. Existing IDs remain a prefix of the new
  ones.

Co-authored-by: Cursor <cursoragent@cursor.com>
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.

1 participant