🇰🇷 한글 설명
Spring Cloud Config 서버의 Git 저장소 복제용 기본 디렉토리(spring.cloud.config.server.git.basedir)가 TOCTOU(Time-of-Check-Time-of-Use) 공격에 취약합니다. 공격자가 파일 시스템 경쟁 조건을 악용하여 권한 없는 파일 접근 또는 악의적 코드 실행이 가능합니다.
💡 쉬운 설명
Spring Cloud Config 서버가 Git 설정 파일을 확인하고 사용하는 찰나의 순간에 공격자가 파일을 조작할 수 있는 보안 허점입니다. 이를 통해 악의적인 설정을 주입하거나 민감한 정보가 유출될 수 있습니다.
🇺🇸 원문 (English)
The base directory (`spring.cloud.config.server.git.basedir`) used by the Spring Cloud Config Server to clone Git repositories to is susceptible to time-of-check-time-of-use (TOCTOU) attacks.
Spring Cloud Config 3.1.x: affected from 3.1.0 through 3.1.13 (inclusive); upgrade to 3.1.14 or greater (Enterprise Support Only). Spring Cloud Config 4.1.x: affected from 4.1.0 through 4.1.9 (inclusive); upgrade to 4.1.10 or greater (Enterprise Support Only). Spring Cloud Config 4.2.x: affected from 4.2.0 through 4.2.6 (inclusive); upgrade to 4.2.7 or greater (Enterprise Support Only). Spring Cloud Config 4.3.x: affected from 4.3.0 through 4.3.2 (inclusive); upgrade to 4.3.3 or greater. Spring Cloud Config 5.0.x: affected from 5.0.0 through 5.0.2 (inclusive); upgrade to 5.0.3 or greater.
📍 영향받는 시스템
Spring Cloud Config 3.1.0-3.1.13, 4.1.0-4.1.9, 4.2.0-4.2.6, 4.3.0-4.3.2, 5.0.0-5.0.2
⚔️ 공격 벡터
Git 저장소 복제 시 발생하는 파일 시스템 경쟁 조건을 악용하여 심볼릭 링크 공격 또는 파일 치환 공격 수행
🛡️ 대응 방법
Spring Cloud Config를 3.1.14+, 4.1.10+, 4.2.7+, 4.3.3+ 또는 5.0.3+ 버전으로 즉시 업그레이드
🔧 검증 코드
출력된 버전번호가 영향받는 범위(3.1.0-3.1.13, 4.1.0-4.1.9, 4.2.0-4.2.6, 4.3.0-4.3.2, 5.0.0-5.0.2)에 해당하면 취약; 패치된 버전 이상이면 안전합니다.
grep -A1 'spring-cloud-config-server' pom.xml 2>/dev/null | grep -oE '[0-9]+\.[0-9]+\.[0-9]+'