Skip to content

GHSA-4xp2-w642-7mcx BIT-cilium-2023-41333 BIT-cilium-operator-2023-41333 BIT-cilium-proxy-2023-41333 BIT-hubble-2023-41333 BIT-hubble-relay-2023-41333 BIT-hubble-ui-2023-41333 BIT-hubble-ui-backend-2023-41333 CVE-2023-41333 GO-2023-2080

Cilium vulnerable to bypass of namespace restrictions in CiliumNetworkPolicy

High Go
Severity
6.9 / 10
High · CVSS 3.1
Exploit chance (EPSS)
0.48%
Chance of exploitation in the next 30 days. Higher than 41.59% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-306 Missing Authentication for Critical Function
Fix
1.14.2
Upgrade github.com/cilium/cilium to this version or later

Description

Impact

An attacker with the ability to create or modify CiliumNetworkPolicy objects in a particular namespace is able to affect traffic on an entire Cilium cluster, potentially bypassing policy enforcement in other namespaces.

By using a crafted endpointSelector that uses the DoesNotExist operator on the reserved:init label, the attacker can create policies that bypass namespace restrictions and affect the entire Cilium cluster. This includes potentially allowing or denying all traffic.

This attack requires API server access, as described in the Kubernetes API Server Attacker section of the Cilium Threat Model.

Patches

This issue was patched in https://github.com/cilium/cilium/pull/28007

This issue affects:

  • Cilium <= v1.14.1
  • Cilium <= v1.13.6
  • Cilium <= v1.12.13

This issue has been resolved in:

  • Cilium v1.14.2
  • Cilium v1.13.7
  • Cilium v1.12.14

Workarounds

An admission webhook can be used to prevent the use of endpointSelectors that use the DoesNotExist operator on the reserved:init label in CiliumNetworkPolicies.

Acknowledgements

The Cilium community has worked together with members of Palantir and Isovalent to prepare these mitigations. Special thanks to @odinuge for reporting this issue and @joestringer for the fix.

For more information

If you have any questions or comments about this advisory, please reach out on Slack.

If you think you have found a vulnerability in Cilium, we strongly encourage you to report it to our private security mailing list at security@cilium.io first, before disclosing it in any public forum. This is a private mailing list for Cilium's internal security team, and your report will be treated as top priority.

Affected versions

Go

PackageVulnerableFixed in
github.com/cilium/cilium
>= 1.14.0, < 1.14.2
1.14.2
github.com/cilium/cilium
>= 1.13.0, < 1.13.7
1.13.7
github.com/cilium/cilium
< 1.12.14
1.12.14
github.com/cilium/cilium
< 1.12.14
>= 1.13.0, < 1.13.7
>= 1.14.0, < 1.14.2
1.12.14
1.13.7
1.14.2

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

github.com/cilium/cilium Go → 1.14.2

go
go get github.com/cilium/cilium@v1.14.2 && go mod tidy

Severity breakdown

CVSS 3.1 6.9

CVSS:3.1/AV:A/AC:L/PR:H/UI:N/S:C/C:L/I:N/A:H

Attack vector
Adjacent
Attack complexity
Low
Privileges required
High
User interaction
None
Scope
Changed
Confidentiality
Low
Integrity
None
Availability
High

Weakness

CWE-306: Missing Authentication for Critical Function

The product does not perform any authentication for functionality that requires a provable user identity or consumes a significant amount of resources.

How to prevent it
  • Architecture and Design: Divide the software into anonymous, normal, privileged, and administrative areas. Identify which of these areas require a proven user identity, and use a centralized authentication capability. Identify all potential communication channels, or other means of interaction with the software, to ensure that all channels are appropriately protected, including those channels that are assumed to be accessible only by authorized parties. Developers sometimes perform authentication at the primary channel, but open up a secondary channel that is assumed to be private. For example, a login mechanism may be listening on one network port, but after successful authentication, it may open up a second port where it waits for the connection, but avoids authentication because it assumes that only the authenticated party will connect to the port. In general, if the software or protocol allows a single session or user state to persist across multiple connections or channels, authentication and appropriate credential management need to be used throughout.
  • Architecture and Design: For any security checks that are performed on the client side, ensure that these checks are duplicated on the server side, in order to avoid CWE-602. Attackers can bypass the client-side checks by modifying values after the checks have been performed, or by changing the client to remove the client-side checks entirely. Then, these modified values would be submitted to the server.
  • Architecture and Design: Where possible, avoid implementing custom, "grow-your-own" authentication routines and consider using authentication capabilities as provided by the surrounding framework, operating system, or environment. These capabilities may avoid common weaknesses that are unique to authentication; support automatic auditing and tracking; and make it easier to provide a clear separation between authentication tasks and authorization tasks. In environments such as the World Wide Web, the line between authentication and authorization is sometimes blurred. If custom authentication routines are required instead of those provided by the server, then these routines must be applied to every single page, since these pages could be requested directly.
  • Architecture and Design: Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid. For example, consider using libraries with authentication capabilities such as OpenSSL or the ESAPI Authenticator [REF-45].
  • Implementation, System Configuration, Operation: When storing data in the cloud (e.g., S3 buckets, Azure blobs, Google Cloud Storage, etc.), use the provider's controls to require strong authentication for users who should be allowed to access the data [REF-1297] [REF-1298] [REF-1302].

References

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
GHSA-fm8w-2m5w-9j7r
Cilium may unexpectedly allow ingress traffic from the local namespace when a Kubernetes NetworkPolicy is configured with an ipBlock match
Medium Also affects github.com/cilium/cilium
GHSA-w7c2-w76w-5hmj
Cilium: Namespaced HTTPRoutes can redirect traffic to other namespaces
High Also affects github.com/cilium/cilium
GHSA-q6h5-q3q6-f87x
CiliumLocalRedirectPolicy addressMatcher allows cross-namespace service traffic hijacking and can break service translation
Medium Also affects github.com/cilium/cilium
GHSA-3fcv-jvfp-m4q9
Cilium vulnerable to sensitive information disclosure and cluster disruption via local Envoy admin socket access
High Also affects github.com/cilium/cilium
GHSA-gj49-89wh-h4gj
Cillium exposes sensitive information included in the cilium-bugtool debug archive
Medium Also affects github.com/cilium/cilium
GHSA-hxv8-4j4r-cqgv
Cilium L7 proxy may bypass Kubernetes NetworkPolicy for same-node traffic
Medium Also affects github.com/cilium/cilium
GHSA-5r23-prx4-mqg3
Cilium may not enforce host firewall policies when Native Routing, WireGuard and Node Encryption are enabled
Medium Also affects github.com/cilium/cilium
GHSA-38pp-6gcp-rqvm
Cilium with misconfigured toGroups in policies can lead to unrestricted egress traffic
Medium Also affects github.com/cilium/cilium
Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor