🇰🇷 한글 설명
Nginx UI 2.3.8 이전 버전에서 GetSettings API가 인증된 사용자에게 40개 이상의 민감한 설정 필드를 노출합니다. protected 태그가 쓰기 시에만 강제되고 읽기 시에는 무시되어, JwtSecret, NodeSecret, OIDC ClientSecret 등의 핵심 암호가 유출될 수 있습니다.
💡 쉬운 설명
Nginx UI의 설정 조회 기능이 관리자 암호, 인증 토큰, OAuth 비밀 같은 민감한 정보를 노출합니다. 접근 권한이 있는 사용자라면 누구나 이 정보를 훔칠 수 있습니다.
🇺🇸 원문 (English)
Nginx UI is a web user interface for the Nginx web server. Prior to version 2.3.8, the GetSettings API handler (api/settings/settings.go:24-65) serializes all settings structs to JSON and returns them to authenticated users. Many sensitive fields are tagged with protected:"true" - however, this tag is only enforced during writes (via ProtectedFill in SaveSettings) and is completely ignored during reads. This exposes 40+ protected fields including JwtSecret (enabling auth token forgery), NodeSecret (enabling cluster node impersonation), OIDC ClientSecret (enabling OAuth account takeover), and the IP whitelist configuration. This issue has been patched in version 2.3.8.
📍 영향받는 시스템
Nginx UI < 2.3.8
⚔️ 공격 벡터
인증된 사용자가 /api/settings/settings 엔드포인트에 GET 요청을 보내 민감한 구성 정보 탈취
🛡️ 대응 방법
Nginx UI를 2.3.8 이상으로 업그레이드하고, 영향받는 시크릿(JwtSecret, NodeSecret, OIDC ClientSecret)을 즉시 회전
🔧 검증 코드
명령어가 JwtSecret, NodeSecret, ClientSecret 등의 값을 반환하면 취약점이 존재합니다. 값이 반환되지 않으면 패치된 상태입니다.
curl -s -H 'Authorization: Bearer $TOKEN' https://nginx-ui-host/api/settings/settings 2>/dev/null | grep -iE 'jwtsecret|nodesecret|clientsecret'