🔍 CVE-2026-40075

7.5
CVSS Score
HIGH
2026-05-05
2026-07-24 21:10
✅ 완료

🇰🇷 한글 설명

OpenMRS Core의 /openmrs/moduleResources/{moduleid} 엔드포인트에서 사용자 입력을 경로 검증 없이 처리하여 경로 탐색 공격이 가능합니다. 인증이 필요하지 않은 로그인 페이지 리소스 제공 영역이라 누구나 /etc/passwd, 데이터베이스 설정 등 임의 파일을 읽을 수 있습니다.

💡 쉬운 설명

의료 기록 시스템(OpenMRS)이 로그인 없이 접근 가능한 파일 서빙 기능에서 파일 경로를 검증하지 않아, 해커가 서버의 민감한 설정 파일과 시스템 파일을 자유롭게 읽을 수 있습니다. 이는 데이터베이스 암호 탈취로 이어질 수 있습니다.

🇺🇸 원문 (English)

OpenMRS Core is an open source electronic medical record system platform. In versions 2.7.8 and earlier and versions 2.8.0 through 2.8.5, the `/openmrs/moduleResources/{moduleid}` endpoint is vulnerable to a path traversal attack. The ModuleResourcesServlet constructs a filesystem path from user-controlled input without performing path boundary validation — the getFile() method concatenates the user-supplied path into an absolute filesystem path without calling normalize() or checking that the result stays within the allowed module resources directory. Because this endpoint serves static resources required for rendering the login page, it is not protected by authentication filters, allowing unauthenticated exploitation. An attacker can traverse directories and read arbitrary files from the server filesystem, including /etc/passwd and application configuration files containing database credentials. Successful exploitation requires the target deployment to run on Apache Tomcat versions prior to 8.5.31, where the ..; path parameter bypass is not mitigated by the container. Deployments on Tomcat 8.5.31 or later and Tomcat 9.0.10 or later are protected at the container level, though the underlying code defect remains. This issue has been fixed in versions after 2.7.8 (within the 2.7.x branch) and in version 2.8.6 and later.

📍 영향받는 시스템

OpenMRS Core 2.7.8 이하, 2.8.0-2.8.5 (Tomcat 8.5.31 이전 배포)

⚔️ 공격 벡터

GET /openmrs/moduleResources/moduleid?path=../../etc/passwd 형태로 디렉토리 탐색 기호(..)를 통한 경로 조작

🛡️ 대응 방법

OpenMRS를 2.7.9+ 또는 2.8.6+ 버전으로 업그레이드 또는 Tomcat을 8.5.31 이상으로 업그레이드

🔧 검증 코드

반환된 버전이 2.7.8 이하 또는 2.8.0-2.8.5 범위이면 취약하며, Tomcat 버전도 8.5.31 미만인지 확인해야 합니다.

Shell / Script
curl -s http://localhost:8080/openmrs/ws/rest/v1/appui/session 2>/dev/null | grep -o '"openmrsVersion":"[^"]*"'

📊 CVSS Vector String

CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

💻 영향받는 소프트웨어

Apache Tomcat