Skip to content

Improve approval deduplication SEC-11851 - #521

Merged
leonard-tesnov merged 1 commit into
masterfrom
prevent-double-approval-v2
Sep 21, 2026
Merged

leonard-tesnov merged 1 commit into
masterfrom
prevent-double-approval-v2

Conversation

@leonard-tesnov

Copy link
Copy Markdown
Contributor

Improve approval so that comparisons are done based only on the user's name; other types of k8s resources are failing, and the namespace is being ignored.

Follow-up from PR #520

…e name of the user, and the other types of k8s resources are failing, and the namespace is disregarded.
@leonard-tesnov
leonard-tesnov requested review from a team and asilde September 10, 2026 07:54
@leonard-tesnov leonard-tesnov changed the title Improve approval dedoublication SEC-11851 Improve approval deduplication SEC-11851 Sep 10, 2026

@goelozev goelozev left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, just a little suggestion on the length of code comments!

// attach DirectoryRoleBinding, where the kind decides how the name is
// interpreted - a GoogleGroup subject, for example, is expanded into that
// group's members - so a non-User kind would grant attach access to
// identities that never authenticated.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A bit verbose IMO

// namespace - so it must not be usable to make the same approver count as
// more than one authoriser. Reject the update outright if this user
// already appears in the existing authorisations, whatever the other
// fields of those entries say.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto

@leonard-tesnov
leonard-tesnov merged commit c9c35b3 into master Sep 21, 2026
9 checks passed
@leonard-tesnov
leonard-tesnov deleted the prevent-double-approval-v2 branch September 21, 2026 11:15
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.

3 participants