🔍 CVE-2024-48924

0.0
CVSS Score
UNKNOWN
2024-10-17
2026-06-17 07:59
✅ 완료

🇰🇷 한글 설명

신뢰할 수 없는 소스로부터 MessagePack 데이터를 역직렬화할 때, 해시 충돌을 유도하는 데이터를 전송하여 CPU 사용량을 급증시키는 서비스 거부(DoS) 공격 위험이 있습니다. 이는 이전 보안 권고 사항에 대한 수정이 불충분하여 발생한 문제입니다.

💡 쉬운 설명

해커가 특수하게 조작된 데이터를 보내 컴퓨터의 계산 능력을 과도하게 사용하여 시스템을 멈추게 만들 수 있습니다. 마치 똑같은 이름의 서류를 수만 장 보내서 분류 작업을 마비시키는 것과 비슷합니다.

🇺🇸 원문 (English)

### Impact When this library is used to deserialize messagepack data from an untrusted source, there is a risk of a denial of service attack by an attacker that sends data contrived to produce hash collisions, leading to large CPU consumption disproportionate to the size of the data being deserialized. This is similar to [a prior advisory](https://github.com/MessagePack-CSharp/MessagePack-CSharp/security/advisories/GHSA-7q36-4xx7-xcxf), which provided an inadequate fix for the hash collision part of the vulnerability. ### Patches The following steps are required to mitigate this risk. 1. Upgrade to a version of the library where a fix is available. 1. Review the steps in [this previous advisory](https://github.com/MessagePack-CSharp/MessagePack-CSharp/security/advisories/GHSA-7q36-4xx7-xcxf) to ensure you have your application configured for untrusted data. ### Workarounds If upgrading MessagePack to a patched version is not an option for you, you may apply a manual workaround as follows: 1. Declare a class that derives from `MessagePackSecurity`. 2. Override the `GetHashCollisionResistantEqualityComparer<T>` method to provide a collision-resistant hash function of your own and avoid calling `base.GetHashCollisionResistantEqualityComparer<T>()`. 3. Configure a `MessagePackSerializerOptions` with an instance of your derived type by calling `WithSecurity` on an existing options object. 4. Use your custom options object for all deserialization operations. This may be by setting the `MessagePackSerializer.DefaultOptions` static property, if you call methods that rely on this default property, and/or by passing in the options object explicitly to any `Deserialize` method. ### References - Learn more about best security practices when reading untrusted data with [MessagePack 1.x](https://github.com/MessagePack-CSharp/MessagePack-CSharp/tree/v1.x#security) or [MessagePack 2.x](https://github.com/MessagePack-CSharp/MessagePack-CSharp#security). - The .NET team's [discussion on hash collision vulnerabilities of their `HashCode` struct](https://github.com/GrabYourPitchforks/runtime/blob/threat_models/docs/design/security/System.HashCode.md). ### For more information If you have any questions or comments about this advisory: * [Start a public discussion](https://github.com/MessagePack-CSharp/MessagePack-CSharp/discussions) * [Email us privately](mailto:[email protected])

📍 영향받는 시스템

MessagePack-CSharp 라이브러리 (이전 패치가 적용되지 않은 버전)

⚔️ 공격 벡터

해시 충돌을 유도하도록 설계된 악의적인 MessagePack 데이터 전송

🛡️ 대응 방법

라이브러리를 최신 패치 버전으로 업그레이드하거나, MessagePackSecurity를 상속받아 충돌 저항성이 있는 사용자 정의 비교기를 구현해야 합니다.

🔧 검증 코드

출력된 MessagePack.CSharp의 버전을 확인하여 보안 패치가 포함된 최신 버전인지 대조합니다.

Shell / Script
dotnet list package | grep MessagePack.CSharp

💻 영향받는 소프트웨어

.NET