CVE-2023-22645

8.0 HIGH

📋 TL;DR

This vulnerability allows attackers with access to the kubewarden-controller ServiceAccount to read arbitrary Kubernetes secrets. It affects SUSE kubewarden deployments with kubewarden-controller versions prior to 1.6.0, potentially exposing sensitive cluster data.

💻 Affected Systems

Products:
  • SUSE kubewarden
Versions: kubewarden-controller versions prior to 1.6.0
Operating Systems: Linux
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects deployments where kubewarden-controller is installed and running with vulnerable versions.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete compromise of all Kubernetes secrets in the cluster, leading to credential theft, data exfiltration, and lateral movement across the entire environment.

🟠

Likely Case

Unauthorized access to specific secrets that could contain API keys, passwords, certificates, or other sensitive configuration data.

🟢

If Mitigated

Limited impact if proper RBAC controls and network segmentation prevent unauthorized access to the kubewarden-controller ServiceAccount.

🌐 Internet-Facing: LOW - This vulnerability requires access to the ServiceAccount, which is typically not internet-facing.
🏢 Internal Only: HIGH - Internal attackers or compromised pods with access to the ServiceAccount can exploit this vulnerability to escalate privileges.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires access to the kubewarden-controller ServiceAccount, which could be obtained through other vulnerabilities or misconfigurations.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 1.6.0

Vendor Advisory: https://bugzilla.suse.com/show_bug.cgi?id=1210218

Restart Required: Yes

Instructions:

1. Update kubewarden-controller to version 1.6.0 or later. 2. Use kubectl apply with the updated manifests. 3. Verify the new version is running with kubectl get pods -n kubewarden.

🔧 Temporary Workarounds

Restrict ServiceAccount Access

linux

Apply strict RBAC controls to limit which entities can access the kubewarden-controller ServiceAccount.

kubectl create rolebinding restricted-kubewarden --clusterrole=view --serviceaccount=kubewarden:kubewarden-controller --namespace=kubewarden

🧯 If You Can't Patch

  • Implement network policies to isolate kubewarden-controller pods from other sensitive workloads.
  • Regularly rotate all Kubernetes secrets and monitor for unauthorized access attempts.

🔍 How to Verify

Check if Vulnerable:

Check kubewarden-controller version with: kubectl get deployment -n kubewarden kubewarden-controller -o jsonpath='{.spec.template.spec.containers[0].image}'

Check Version:

kubectl get deployment -n kubewarden kubewarden-controller -o jsonpath='{.spec.template.spec.containers[0].image}' | grep -o ':[0-9.]*'

Verify Fix Applied:

Confirm version is 1.6.0 or higher with: kubectl get pods -n kubewarden -l app=kubewarden-controller -o jsonpath='{.items[*].spec.containers[*].image}'

📡 Detection & Monitoring

Log Indicators:

  • Unusual secret access patterns from kubewarden-controller ServiceAccount
  • Failed RBAC authorization attempts for secret resources

Network Indicators:

  • Unexpected outbound connections from kubewarden-controller pods to external services

SIEM Query:

source="kubernetes" AND (resource="secrets" AND user="system:serviceaccount:kubewarden:kubewarden-controller")

🔗 References

📤 Share & Export