{"id":"IL-0065","org":"Cycode","date":"2024-01-18","docs":[],"title":{"en":"Any pod could take over the cluster by rewriting Argo CD's unauthenticated Redis cache (CVE-2024-31989)","ko":"Argo CD의 Redis 캐시가 기본으로 암호 없이 클러스터 안 모든 파드에 열려 있어, 캐시된 매니페스트를 바꿔치기해 클러스터를 장악할 수 있었다"},"domain":["kubernetes","security"],"impact":{"scope":"Kubernetes clusters running Argo CD whose Redis server is reachable from other pods; full cluster takeover and access to Secrets","users":"unknown","region":"unknown"},"review":{"written_by":"session","reviewed_at":null,"reviewed_by":null},"lessons":{"en":"The hash that checks the cached manifests is computed without a secret key, so anyone who can write to Redis can recompute it and make Argo CD deploy an altered manifest. Cycode recommends upgrading to the fixed versions, checking that the argocd-redis-network-policy NetworkPolicy exists and that a CNI enforces it, using controller-based secret management instead of injecting secrets through Argo CD plugins so secrets never reach Redis, and running Argo CD on a dedicated cluster.","ko":"Argo CD를 2.11.1, 2.10.10, 2.9.15, 2.8.19 이상으로 올린다. argocd-redis-network-policy 네트워크 정책이 있고 켜져 있는지 확인한다. 네트워크 정책이 실제로 적용되려면 CNI가 제대로 설정돼 동작해야 한다. Argo CD 플러그인으로 Secret을 넣지 말고 컨트롤러 방식의 Secret 관리 도구를 써서 Secret이 Redis에 남지 않게 한다. 보안을 더 챙기려면 Argo CD를 다른 애플리케이션과 분리된 전용 클러스터에 둔다.\n\n비밀 키 없이 만든 해시는 아무나 다시 계산할 수 있어서 무결성을 지켜 주지 못한다."},"related":[],"sources":[{"url":"https://cycode.com/blog/revealing-argo-cd-critical-vulnerability/","kind":"blog","license":"unknown","archived":null}],"summary":{"en":"Argo CD keeps a cache in Redis to reduce calls to the Kubernetes API and the Git provider. In the default installation that Redis had no password and any pod in the cluster could reach it unless a network policy stopped it. The cache holds application manifests and, when users commit manifests with secrets or plugins generate manifests with secrets, those secrets as well.\n\nEach cached manifest carries a cacheEntryHash that the repo server uses to detect changes: when Cycode first edited a manifest, the repo server restored the original. The hash, however, is an fnv64a checksum computed without any secret key. Cycode recomputed it for an altered manifest, and at its next comparison the application controller found the application out of sync and deployed the altered version. As proof of concept they deployed a privileged pod that mounted the host file system and added their SSH key to the node. The report says the same path gives access to Kubernetes Secrets and allows removing the evidence.\n\nThe vulnerability is CVE-2024-31989 with a score of 9.1. Cycode reported it through GitHub Security Advisories on 18 January 2024; Argo CD confirmed it on 25 January, created the CVE on 9 April and on 21 May 2024 released 2.11.1, 2.10.10, 2.9.15 and 2.8.19, which initialize a password for Redis. The report calls this a partial fix: connecting without prior information is no longer possible.","ko":"Argo CD는 Git 저장소의 설정 변화를 감시해 쿠버네티스 클러스터에 반영하는 GitOps 도구라서 클러스터 권한이 높다. Argo CD의 Redis는 쿠버네티스 API와 Git 공급자로 가는 요청을 줄이는 캐시다. 기본 설치에서 Redis에는 암호가 없고, 네트워크 정책을 제대로 걸어 두지 않으면 어느 파드에서나 접근할 수 있다. Cycode는 기본 설정의 Argo CD를 새 Amazon EKS 클러스터에 올리고, 파드 두 개짜리 배포와 서비스 하나로 된 데모 애플리케이션으로 실험했다.\n\nCycode는 다른 네임스페이스에 권한 낮은 파드를 만들어 침해된 파드를 흉내 냈고, 이 파드에서 Redis에 접속했다. gzip으로 압축된 값을 풀어 보니 애플리케이션 매니페스트와 클러스터 정보가 들어 있었다. 사용자가 Secret이 든 매니페스트를 커밋했거나 관리자가 플러그인으로 Secret을 넣어 매니페스트를 만들면 Secret도 이 캐시에 남는다. Redis 프로파일러로 보니 Application Controller가 'mfst|app.kubernetes.io/instance|myapp|42…|1.8.3.gz' 키를 읽고 있었다. 이 값을 바꾸자 Repo Server가 곧 원래 값으로 되돌렸지만, cacheEntryHash를 fnv64a로 다시 계산해 함께 넣자 변경이 받아들여졌다.\n\nApplication Controller는 다음 상태 점검에서 동기화가 어긋난 것을 감지하고 바뀐 매니페스트를 배포했다. Cycode는 BadPods 프로젝트의 설정으로 권한 높은 파드를 띄워 노드 파일 시스템을 마운트했고, 노드의 authorized keys에 SSH 공개 키를 넣어 노드에 접속했다. Cycode는 2024년 1월 18일 GitHub Security Advisories로 Argo CD 팀에 알렸고, Argo CD 팀은 1월 25일 문제를 확인하고 4월 9일 CVE를 등록했다."},"trigger":{"en":"Cycode Labs installed Argo CD with the default configuration on a new Amazon EKS cluster and connected to its Redis server from a low-privilege pod in another namespace, simulating a compromised pod.","ko":"클러스터 안의 권한 낮은 파드 하나가 kube-DNS로 Argo CD Redis 주소를 찾아 6379 포트로 암호 없이 접속할 수 있었다. Argo CD는 캐시에 든 매니페스트를 cacheEntryHash로 검증했는데, 이 해시는 비밀 키 없이 fnv64a로 만든 값이라 누구나 다시 계산할 수 있었다."},"severity":"unknown","symptoms":["unauthorized-access"],"timeline":{"detected_after":null,"resolved_after":null},"date_kind":"incident","detection":{"en":"Found by Cycode Labs security research, not by an operator.","ko":"Cycode Labs가 Argo CD의 쿠버네티스 구성 요소를 조사하다 찾았다. 2024년 1월 18일 GitHub Security Advisories로 Argo CD 팀에 알렸다."},"components":["argocd"],"root_cause":"software-bug","remediation":[{"text":{"en":"Argo CD released 2.11.1, 2.10.10, 2.9.15 and 2.8.19 with an initialized password for the Redis server","ko":"Argo CD 팀이 2024년 5월 21일 Redis 서버 암호를 미리 정해 두는 2.11.1, 2.10.10, 2.9.15, 2.8.19 버전을 냈다. 사전 정보 없이는 Redis에 접속할 수 없게 됐지만, 문제를 일부만 막는 조치였다."}}],"action_items":[],"contributing":["default-config-unchanged","blast-radius-too-wide","credential-coupled-to-config"],"recurrence_of":null,"symptoms_text":{"en":"This is a vulnerability report, not an outage, so nothing failed visibly. What an engineer can check is whether the Argo CD Redis server accepts connections without a password from a pod in another namespace, on port 6379 at the address kube-dns returns. In the default installation it did.\n\nIts keys hold gzip-compressed cached data about the applications Argo CD manages, including their manifests, under names such as `mfst|app.kubernetes.io/instance|myapp|42…|1.8.3.gz`. Whether other pods can reach it depends on the NetworkPolicy checked with `kubectl -n argocd get networkpolicy argocd-redis-network-policy`, and on a CNI that actually enforces network policies.","ko":"운영 중 장애로 드러난 증상은 없다. 이 사례는 Cycode Labs가 Argo CD를 조사하다 찾은 취약점 CVE-2024-31989이고, 심각도 점수는 9.1이다.\n\n공격이 성공하면 Argo CD Application Controller는 Redis에서 바뀐 매니페스트를 읽고 애플리케이션의 동기화가 어긋났다고 판단한다. 그래서 공격자가 넣은 변경을 클러스터에 배포한다. 공격자는 이 방법으로 권한 높은 파드를 띄워 노드에서 코드를 실행하고 Secret을 읽을 수 있다. 흔적도 모두 지울 수 있다. Redis 접근을 막는 네트워크 정책이 있는지는 kubectl -n argocd get networkpolicy argocd-redis-network-policy 로 확인할 수 있다."},"updated_at":"2026-11-08T19:10:31.636449Z","url":"https://benchlet.com/incidentlib/app/cases/IL-0065","org_slug":"cycode"}