CVE-2024-31989
📋 TL;DR
This vulnerability allows unprivileged pods in different Kubernetes namespaces to connect to Argo CD's Redis server on port 6379, potentially leading to privilege escalation to cluster controller level or information leakage. It affects Argo CD users who haven't manually enabled network policies in their EKS clusters, even with the latest VPC CNI plugin installed.
💻 Affected Systems
- Argo CD
📦 What is this software?
Argo Cd by Argoproj
Argo Cd by Argoproj
Argo Cd by Argoproj
Argo Cd by Argoproj
⚠️ Risk & Real-World Impact
Worst Case
An attacker gains cluster controller privileges, enabling full control over the Kubernetes cluster and all workloads.
Likely Case
Information leakage from Redis containing sensitive configuration data, potentially exposing credentials and deployment secrets.
If Mitigated
With proper network policies enabled, the risk is limited to authorized pods only, preventing cross-namespace access.
🎯 Exploit Status
Exploitation requires access to a pod within the cluster but doesn't require authentication to Redis. The attack involves simple network connections to port 6379.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: 2.8.19, 2.9.15, or 2.10.10
Vendor Advisory: https://github.com/argoproj/argo-cd/security/advisories
Restart Required: Yes
Instructions:
1. Identify your Argo CD version. 2. Upgrade to 2.8.19, 2.9.15, or 2.10.10 based on your current major version. 3. Restart Argo CD components. 4. Verify network policies are properly configured in your EKS cluster.
🔧 Temporary Workarounds
Enable Network Policies in EKS
linuxManually enable network policies in EKS cluster to restrict pod-to-pod communication
eksctl utils enable-network-policy --cluster=<cluster-name> --region=<region>
Configure NetworkPolicy for Redis
allCreate Kubernetes NetworkPolicy to restrict access to Redis port 6379
kubectl apply -f - <<EOF
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: redis-access
namespace: argocd
spec:
podSelector:
matchLabels:
app: redis
policyTypes:
- Ingress
ingress:
- from:
- podSelector:
matchLabels:
app: argocd-server
ports:
- protocol: TCP
port: 6379
EOF
🧯 If You Can't Patch
- Implement strict network policies to isolate Redis from other namespaces
- Monitor network traffic to Redis port 6379 for unauthorized access attempts
🔍 How to Verify
Check if Vulnerable:
Check if pods in other namespaces can connect to Redis: kubectl run test-pod --image=alpine --rm -it --restart=Never -- sh -c 'nc -zv argocd-redis.argocd.svc.cluster.local 6379'
Check Version:
kubectl get deployment -n argocd argocd-server -o jsonpath='{.spec.template.spec.containers[0].image}' | grep -o 'v[0-9.]*'
Verify Fix Applied:
After patching, verify the same test fails and network policies are properly configured
📡 Detection & Monitoring
Log Indicators:
- Unauthorized connection attempts to Redis in Argo CD logs
- Redis authentication failures from unexpected sources
Network Indicators:
- Network connections to port 6379 from pods outside the Argo CD namespace
- Unusual Redis command patterns from unauthorized sources
SIEM Query:
source="kube-audit" AND verb="connect" AND objectRef.resource="pods" AND objectRef.subresource="portforward" AND responseStatus.code=200 AND requestURI LIKE "%6379%"
🔗 References
- https://github.com/argoproj/argo-cd/commit/2de0ceade243039c120c28374016c04ff9590d1d
- https://github.com/argoproj/argo-cd/commit/35a7d6c7fa1534aceba763d6a68697f36c12e678
- https://github.com/argoproj/argo-cd/commit/4e2fe302c3352a0012ecbe7f03476b0e07f7fc6c
- https://github.com/argoproj/argo-cd/commit/53570cbd143bced49d4376d6e31bd9c7bd2659ff
- https://github.com/argoproj/argo-cd/commit/6ef7b62a0f67e74b4aac2aee31c98ae49dd95d12
- https://github.com/argoproj/argo-cd/commit/9552034a80070a93a161bfa330359585f3b85f07
- https://github.com/argoproj/argo-cd/commit/bdd889d43969ba738ddd15e1f674d27964048994
- https://github.com/argoproj/argo-cd/commit/f1a449e83ee73f8f14d441563b6a31b504f8d8b0
- https://github.com/argoproj/argo-cd/security/advisories/GHSA-9766-5277-j5hr
- https://github.com/argoproj/argo-cd/commit/2de0ceade243039c120c28374016c04ff9590d1d
- https://github.com/argoproj/argo-cd/commit/35a7d6c7fa1534aceba763d6a68697f36c12e678
- https://github.com/argoproj/argo-cd/commit/4e2fe302c3352a0012ecbe7f03476b0e07f7fc6c
- https://github.com/argoproj/argo-cd/commit/53570cbd143bced49d4376d6e31bd9c7bd2659ff
- https://github.com/argoproj/argo-cd/commit/6ef7b62a0f67e74b4aac2aee31c98ae49dd95d12
- https://github.com/argoproj/argo-cd/commit/9552034a80070a93a161bfa330359585f3b85f07
- https://github.com/argoproj/argo-cd/commit/bdd889d43969ba738ddd15e1f674d27964048994
- https://github.com/argoproj/argo-cd/commit/f1a449e83ee73f8f14d441563b6a31b504f8d8b0
- https://github.com/argoproj/argo-cd/security/advisories/GHSA-9766-5277-j5hr