-
Notifications
You must be signed in to change notification settings - Fork 3.7k
PASS verdict broken for non-consecutive tiers and with default-allow #43916
Copy link
Copy link
Closed
Labels
affects/mainThis issue affects main branchThis issue affects main brancharea/agentCilium agent related.Cilium agent related.kind/bugThis is a bug in the Cilium logic.This is a bug in the Cilium logic.kind/community-reportThis was reported by a user in the Cilium community, eg via Slack.This was reported by a user in the Cilium community, eg via Slack.sig/policyImpacts whether traffic is allowed or denied based on user-defined policies.Impacts whether traffic is allowed or denied based on user-defined policies.
Description
Is there an existing issue for this?
- I have searched the existing issues
Version
equal or higher than v1.18.6 and lower than v1.19.0
What happened?
There are two issues with the newly implemented policy rule priorities and pass verdict for policies:
-
When a PASS and ALLOW/DENY rule exist for the same identity at non-consecutive tiers (e.g. tier 0 and tier 2), the policy engine throws an error (
endpoint policy direction has more than 2^24 distinct priorities) -
When a PASS rule exists for a specific identity at a higher tier with a wildcard ALLOW rule at a lower tier, the policy engine incorrectly retains the PASS rule as an invalid rule, which throws off the policy evaluation. The wildcard ALLOW is never added for the affected identity.
How can we reproduce the issue?
See the added test cases in the PR.
Cilium Version
1.19
Kernel Version
N/A
Kubernetes Version
N/A
Regression
No response
Sysdump
No response
Relevant log output
Anything else?
No response
Cilium Users Document
- Are you a user of Cilium? Please add yourself to the Users doc
Code of Conduct
- I agree to follow this project's Code of Conduct
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
affects/mainThis issue affects main branchThis issue affects main brancharea/agentCilium agent related.Cilium agent related.kind/bugThis is a bug in the Cilium logic.This is a bug in the Cilium logic.kind/community-reportThis was reported by a user in the Cilium community, eg via Slack.This was reported by a user in the Cilium community, eg via Slack.sig/policyImpacts whether traffic is allowed or denied based on user-defined policies.Impacts whether traffic is allowed or denied based on user-defined policies.