🇰🇷 한글 설명
DeepDiff 라이브러리 5.0.0~8.6.0 버전에서 Delta 클래스 생성자의 클래스 오염 취약점으로 인해 insecure Pickle deserialization을 통한 원격 코드 실행(RCE) 및 서비스 거부(DoS)가 가능합니다. deepdiff.serialization.SAFE_TO_IMPORT를 조작하여 posix.system 같은 위험한 클래스를 import하고 사용자 입력을 Delta에 전달하면 임의의 Python 코드 실행이 가능합니다.
💡 쉬운 설명
DeepDiff 라이브러리에서 특정 데이터를 처리할 때 공격자가 악의적인 코드를 몰래 숨길 수 있는 보안 구멍이 있습니다. 이를 악용하면 서버가 멈추거나 공격자가 원하는 코드를 실행할 수 있습니다.
🇺🇸 원문 (English)
DeepDiff is a project focused on Deep Difference and search of any Python data. Versions 5.0.0 through 8.6.0 are vulnerable to class pollution via the Delta class constructor, and when combined with a gadget available in DeltaDiff, it can lead to Denial of Service and Remote Code Execution (via insecure Pickle deserialization) exploitation. The gadget available in DeepDiff allows `deepdiff.serialization.SAFE_TO_IMPORT` to be modified to allow dangerous classes such as posix.system, and then perform insecure Pickle deserialization via the Delta class. This potentially allows any Python code to be executed, given that the input to Delta is user-controlled. Depending on the application where DeepDiff is used, this can also lead to other vulnerabilities. This is fixed in version 8.6.1.
📍 영향받는 시스템
DeepDiff 5.0.0 ~ 8.6.0 (8.6.1 이상에서 수정됨)
⚔️ 공격 벡터
SAFE_TO_IMPORT 수정을 통해 위험한 클래스 import 허용 후 Delta 클래스에 사용자 제어 입력을 전달하여 insecure Pickle deserialization 실행
🛡️ 대응 방법
DeepDiff를 8.6.1 이상 버전으로 즉시 업그레이드
🔧 검증 코드
Version이 8.6.1 이상이면 안전하고, 5.0.0~8.6.0이면 취약합니다.
pip show deepdiff | grep Version