GHSA-g35x-j6jj-8g7j @mittwald/kubernetes's secret contents leaked via debug logging
Enabling debug logging in the Kubernetes client library leaks sensitive Secret data to logs, exposing it to unauthorized users with log access.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is GHSA-g35x-j6jj-8g7j?
GHSA-g35x-j6jj-8g7j is a vulnerability in @mittwald/kubernetes, published on 2 May 2023. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
Impact
When debug logging is enabled (via DEBUG environment variable), the Kubernetes client may log all response bodies into the debug log – including sensitive data from Secret resources.
When running in a Kubernetes cluster, this might expose sensitive information to users who are not authorised to access secrets, but have access to Pod logs (either directly using kubectl, or by Pod logs being shipped elsewhere).
Patches
Upgrade to 3.5.0 or newer.
Workarounds
Disable debug logging entirely, or exclude the kubernetes:client debug item (for example, using DEBUG=*,-kubernetes:client).
References
Which versions are affected by GHSA-g35x-j6jj-8g7j?
2 open source packages ship an affected version, including @mittwald/kubernetes.
| Package | Affected | Fixed in |
|---|---|---|
@mittwald/kubernetes npm | All versions | 3.5.0 |
@mittwald/kubernetes npm | All versions | 3.5.0 |
How do I fix GHSA-g35x-j6jj-8g7j?
Upgrade @mittwald/kubernetes to 3.5.0 or later.
Is GHSA-g35x-j6jj-8g7j being exploited?
There is no known exploitation of GHSA-g35x-j6jj-8g7j in the wild and no public exploit code.