🇰🇷 한글 설명
STIX 2 가져오기 및 MISP-to-STIX 2 내보내기 과정에서 MISP 객체 템플릿 이름을 처리할 때 경로 탐색(Path Traversal) 취약점이 존재합니다. 공격자가 조작된 객체 이름을 사용하여 의도된 디렉토리를 벗어나 시스템의 다른 위치에 있는 definition.json 파일을 로드하도록 유도할 수 있습니다. 이를 통해 로컬 데이터가 유출되거나 객체의 메타데이터 및 의미가 변조될 위험이 있습니다.
💡 쉬운 설명
파일 경로를 조작하는 특수 문자를 이용해 프로그램이 허용되지 않은 폴더의 파일을 읽게 만드는 보안 약점입니다. 악성 데이터가 포함된 파일을 업로드하거나 내보낼 때 시스템 내부의 중요한 정보가 노출될 수 있습니다.
🇺🇸 원문 (English)
A path traversal vulnerability existed in the handling of MISP object template names during STIX 2 import and MISP-to-STIX 2 export.
MISP object names are passed to PyMISP's object-template resolution mechanism, which constructs a filesystem path by joining the configured MISP object-template directory, the object name, and definition.json. An object name originating from untrusted STIX or MISP content was not sufficiently restricted before being used in this filesystem path.
An attacker able to supply a crafted object name containing path separators or traversal sequences such as ../ could therefore cause template resolution to escape the expected template directory and attempt to load a definition.json file from another location accessible to the process.
During STIX 2 import, an attacker-controlled x_misp_name from a custom STIX object could directly reach this template-resolution mechanism.
The issue could also become persistent. A malicious object name stored in a MISP event could later be processed again during STIX 2 export. Consequently, content originally introduced in one security context could trigger filesystem access later when the event is exported by a process operating with different or greater privileges.
If a suitable definition.json file exists outside the intended template directory, its contents may be interpreted as a MISP object template and fields from that file copied into the converted object. This can result in unintended disclosure of locally accessible data represented by the template file and modification of the resulting object's metadata or semantics.
The patches introduce strict validation of object-template names. Valid names are restricted to a single path component containing letters, digits, hyphens, or underscores. Names that do not meet these requirements are replaced with the generic unknown-template name before reaching PyMISP template resolution. The original rejected name is preserved in the object's comment and a warning is generated, preventing traversal while retaining the source information.
📍 영향받는 시스템
PyMISP 라이브러리를 사용하여 STIX 2 데이터 임포트/익스포트를 수행하는 시스템
⚔️ 공격 벡터
조작된 x_misp_name(../ 포함)이 포함된 STIX 2 객체를 통해 경로 탐색 공격 수행
🛡️ 대응 방법
PyMISP를 최신 패치 버전으로 업데이트하여 객체 템플릿 이름에 대한 엄격한 검증 적용
🔧 검증 코드
출력된 PyMISP 버전을 확인하여 취약점이 해결된 패치 버전인지 대조합니다.
pip show pymisp | grep -E 'Version'