-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(CSI-244): match subnets if existing in client rule #315
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This was referenced Sep 3, 2024
Graphite Automations"Request reviewers once CI passes" took an action on this PR • (09/03/24)1 reviewer was added to this PR based on Sergey Berezansky's automation. |
This was referenced Sep 3, 2024
sergeyberezansky
force-pushed
the
sergey/nfs_support
branch
from
September 11, 2024 10:11
b513ff0
to
bd972d2
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_superset_rules
branch
from
September 11, 2024 10:11
4b0b152
to
98b4980
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_support
branch
from
September 11, 2024 11:11
bd972d2
to
26b47a2
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_superset_rules
branch
from
September 11, 2024 11:11
98b4980
to
ce8fe93
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_support
branch
from
September 11, 2024 11:34
26b47a2
to
13e5ee0
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_superset_rules
branch
from
September 11, 2024 11:34
ce8fe93
to
59dd6b6
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_support
branch
from
September 11, 2024 11:51
13e5ee0
to
7d73023
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_superset_rules
branch
2 times, most recently
from
September 11, 2024 13:01
66c002c
to
a718c35
Compare
sergeyberezansky
changed the base branch from
sergey/nfs_support
to
sergey/modify-default-hostports
September 11, 2024 13:01
sergeyberezansky
force-pushed
the
sergey/modify-default-hostports
branch
from
September 11, 2024 14:24
4a6085c
to
a445cd7
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_superset_rules
branch
from
September 11, 2024 14:24
a718c35
to
b38ce46
Compare
Merge activity
|
sergeyberezansky
changed the base branch from
sergey/modify-default-hostports
to
graphite-base/315
September 12, 2024 10:35
sergeyberezansky
force-pushed
the
sergey/nfs_superset_rules
branch
from
September 12, 2024 10:56
b38ce46
to
d685386
Compare
sergeyberezansky
force-pushed
the
sergey/nfs_superset_rules
branch
from
September 12, 2024 10:58
d685386
to
2006fda
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
TL;DR
Improved NFS client group rule matching to include superset IP networks.
What changed?
IsSupersetOf
method toNfsClientGroupRule
to check if a rule covers a larger IP range.FindNfsClientGroupRulesByFilter
to include rules that are supersets of the query.GetMaskBits
method forNetwork
to calculate CIDR notation.ContainsIPAddress
method to handle cases where CIDR parsing fails.IsSupersetOf
functionality.How to test?
nfs_test.go
.FindNfsClientGroupRulesByFilter
function with various IP ranges and ensure it returns both exact matches and superset rules.ContainsIPAddress
method correctly identifies IP addresses within a given network range.Why make this change?
This change improves the flexibility and accuracy of NFS client group rule matching. By including superset IP networks, the system can now identify and apply rules that cover a broader range of IP addresses, enhancing the overall functionality of the NFS access control system.
When having an extremely large Kubernetes clusters, adding node IP addresses to client group could harm the rule matching performance or hit limits on max. number of rules. This allows using a subnet addresses (those should be configured by administrator)