🇰🇷 한글 설명
Gerrit Code Review의 ANTLR 3 검색 쿼리 파서에서 발생하는 제어되지 않은 리소스 소비 취약점입니다. 공격자가 깊게 중첩된 괄호를 포함한 특수 검색 쿼리를 전송하면 CPU 고갈 및 HTTP 워커 스레드 고갈을 유발하여 서버를 중단시킬 수 있습니다.
💡 쉬운 설명
검색창에 복잡한 괄호를 아주 많이 넣은 질문을 던져서 서버를 마비시키는 공격입니다. 이 공격을 받으면 서버가 응답을 멈춰서 재시작이 필요할 수 있습니다.
🇺🇸 원문 (English)
Uncontrolled Resource Consumption (CWE-400 / CWE-407) in the ANTLR 3 search query parser (QueryParser / Query.g) in Gerrit Code Review versions 2.0.19 through 3.12.9, 3.13.0 through 3.13.8, and 3.14.0 through 3.14.2 allows an unauthenticated remote attacker (or an authenticated user if anonymous read access is disabled) to cause a persistent denial of service (CPU exhaustion and HTTP worker thread pool starvation requiring a server restart) via crafted search queries containing deeply nested parentheses sent to query evaluation endpoints (/changes/?q=, /accounts/?q=, /groups/?query=, /projects/?query=, /Documentation/?q=, /changes/{id}/query?expression=, or SSH gerrit query). Because syntactic predicates in conditionOr and conditionAnd recurse via conditionBase without memoization prior to capability or visibility checks and worker threads do not abort when the client disconnects, a small number of requests (such as 25 requests matching default httpd.maxThreads) can permanently pin all HTTP worker threads. This issue is fixed in Gerrit Code Review versions 3.12.10, 3.13.9, and 3.14.3.
📍 영향받는 시스템
Gerrit Code Review 2.0.19-3.12.9, 3.13.0-3.13.8, 3.14.0-3.14.2
⚔️ 공격 벡터
인증되지 않은 공격자가 특정 쿼리 엔드포인트에 중첩된 괄호가 포함된 조작된 검색 쿼리를 전송
🛡️ 대응 방법
Gerrit Code Review를 버전 3.12.10, 3.13.9 또는 3.14.3 이상으로 업데이트
🔧 검증 코드
현재 설치된 Gerrit의 버전을 확인하여 취약한 버전 범위에 해당하는지 체크합니다.
gerrit --version 2>/dev/null || curl -s http://<target_ip>:<port>/ | grep -i 'Gerrit'