CVE-2026-48510: MessagePack-CSharp LZ4 Decompression Allocates From Unbounded Vulnerability

MODERATE
Advisory Identifier: GHSA-v72x-2h86-7f8m
CVSS 7.5
CWE-409 CWE-770
Published
Advisory Summary

CVE-2026-48510 is a MODERATE (CVSS 7.5) lz4 decompression allocates from unbounded vulnerability (CWE-409: Improper Handling of Highly Compressed Data (Data Amplification)) affecting MessagePack-CSharp libraries in the NuGet ecosystem. The issue involves lz4 decompression allocates from unbounded declared output lengths. Remediation is available by upgrading affected packages to version 2.5.301, 3.1.7.

CVE-2026-48510 at a Glance

CVE Identifier CVE-2026-48510
GHSA Identifier GHSA-v72x-2h86-7f8m
Severity MODERATE
CVSS v3.1 Base Score 7.5
CWE Classification CWE-409: Improper Handling of Highly Compressed Data (Data Amplification)
Affected Product MessagePack-CSharp
Package Ecosystem NuGet
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity None (I:N)
Availability High (A:H)

How to Fix CVE-2026-48510

To remediate this vulnerability, upgrade all affected MessagePack-CSharp dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

MessagePack fixed: 2.5.301
Upgrade MessagePack to 2.5.301
MessagePack fixed: 3.1.7
Upgrade MessagePack to 3.1.7
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for MessagePack

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-48510, inspect your project dependencies for MessagePack-CSharp:

inspect dependencies for MessagePack

Analyze the terminal output to locate any version of MessagePack-CSharp in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.5.301), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-409: Improper Handling of Highly Compressed Data (Data Amplification), where the product does not handle or incorrectly handles a compressed input with a very high compression ratio that produces a large output. In MessagePack-CSharp, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

## Summary When MessagePack-CSharp decompresses `Lz4Block` or `Lz4BlockArray` payloads, it reads declared uncompressed lengths from the wire and allocates output buffers based on those lengths before validating that the compressed data is valid or that the declared expansion is reasonable. A small payload can claim a very large uncompressed length and force a large allocation before LZ4 decoding begins. ## Impact Applications are affected when they deserialize attacker-controlled MessagePack payloads with `MessagePackCompression.Lz4Block` or `MessagePackCompression.Lz4BlockArray` enabled. In the `Lz4Block` case, an attacker-controlled integer is used to request the destination span. In the `Lz4BlockArray` case, per-block uncompressed lengths and their aggregate can be attacker-controlled. Without a cap, the declared output size can be disproportionate to the input size, producing out-of-memory exceptions, process termination on constrained hosts, or severe memory pressure. This advisory is about unbounded allocation from declared decompressed sizes. It is separate from the LZ4 source-buffer over-read issue, which concerns unsafe decoder reads beyond the compressed input buffer. ## Affected components - Package: `MessagePack` - Feature: LZ4 compressed MessagePack payloads - APIs: `MessagePackSerializer` with `WithCompression(MessagePackCompression.Lz4Block)` or `WithCompression(MessagePackCompression.Lz4BlockArray)` - Internal routine: `MessagePackSerializer.TryDecompress` - Finding ID: `MESSAGEPACKCSHARP-OPEN-004` ## Patches Fixes are prepared and will be released in coordinated patch versions. Upgrade guidance: 1. Upgrade `MessagePack` to the patched version for your release line. 2. Upgrade companion MessagePack packages in the same dependency graph to the coordinated patched versions. The fix should reject negative and excessive uncompressed lengths before allocation. It should also cap aggregate decompressed size for block arrays and expose or honor an appropriate maximum decompressed length policy. ## Workarounds Patching is recommended. Until a patched version is available, do not enable MessagePack-CSharp's built-in LZ4 compression modes for untrusted inputs. If compression is required, enforce strict compressed and decompressed size limits outside MessagePack-CSharp before deserialization. ## Resources - `MESSAGEPACKCSHARP-OPEN-004`: LZ4 decompression allocation from unbounded uncompressed length - `MESSAGEPACKCSHARP-011`: duplicate decompression-bomb finding - CWE-409: Improper Handling of Highly Compressed Data - CWE-770: Allocation of Resources Without Limits or Throttling

CVE-2026-48510 Affected MessagePack-CSharp Versions

2 component(s)
Fixed Versions:
2.5.3013.1.7
Product / Package Ecosystem Affected Versions Fixed Version
MessagePack
NuGet
< 2.5.301
2.5.301
MessagePack
NuGet
≥ 3.0
< 3.1.7
3.1.7

References

Frequently Asked Questions

What is CVE-2026-48510?
CVE-2026-48510 is a security vulnerability in MessagePack-CSharp involving LZ4 decompression allocates from unbounded declared output lengths under CWE-409: Improper Handling of Highly Compressed Data (Data Amplification).
Which MessagePack-CSharp versions are affected?
Affected versions include releases prior to 2.5.301, 3.1.7 across affected packages: MessagePack.
What version fixes CVE-2026-48510?
Upgrading to 2.5.301, 3.1.7 (or the latest patched release for your respective branch) resolves the vulnerability.
Is MessagePack affected?
Yes, MessagePack is affected in releases prior to 2.5.301, 3.1.7. Upgrade your dependency to 2.5.301, 3.1.7 or later.
What is the CVSS score of CVE-2026-48510?
CVE-2026-48510 has a CVSS v3.1 base score of 7.5 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
What CWE is associated with CVE-2026-48510?
CVE-2026-48510 is classified under CWE-409: Improper Handling of Highly Compressed Data (Data Amplification) (The product does not handle or incorrectly handles a compressed input with a very high compression ratio that produces a large output.).
How can I check NuGet dependencies for CVE-2026-48510?
Run the dependency tree command: 'inspect dependencies for MessagePack'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-v72x-2h86-7f8m",
  "modified" : "2026-06-25T18:53:44Z",
  "published" : "2026-06-25T18:53:44Z",
  "aliases" : [ "CVE-2026-48510" ],
  "summary" : "MessagePack-CSharp: LZ4 decompression allocates from unbounded declared output lengths",
  "details" : "## Summary\n\nWhen MessagePack-CSharp decompresses `Lz4Block` or `Lz4BlockArray` payloads, it reads declared uncompressed lengths from the wire and allocates output buffers based on those lengths before validating that the compressed data is valid or that the declared expansion is reasonable.\n\nA small payload can claim a very large uncompressed length and force a large allocation before LZ4 decoding begins.\n\n## Impact\n\nApplications are affected when they deserialize attacker-controlled MessagePack payloads with `MessagePackCompression.Lz4Block` or `MessagePackCompression.Lz4BlockArray` enabled.\n\nIn the `Lz4Block` case, an attacker-controlled integer is used to request the destination span. In the `Lz4BlockArray` case, per-block uncompressed lengths and their aggregate can be attacker-controlled. Without a cap, the declared output size can be disproportionate to the input size, producing out-of-memory exceptions, process termination on constrained hosts, or severe memory pressure.\n\nThis advisory is about unbounded allocation from declared decompressed sizes. It is separate from the LZ4 source-buffer over-read issue, which concerns unsafe decoder reads beyond the compressed input buffer.\n\n## Affected components\n\n- Package: `MessagePack`\n- Feature: LZ4 compressed MessagePack payloads\n- APIs: `MessagePackSerializer` with `WithCompression(MessagePackCompression.Lz4Block)` or `WithCompression(MessagePackCompression.Lz4BlockArray)`\n- Internal routine: `MessagePackSerializer.TryDecompress`\n- Finding ID: `MESSAGEPACKCSHARP-OPEN-004`\n\n## Patches\n\nFixes are prepared and will be released in coordinated patch versions.\n\nUpgrade guidance:\n\n1. Upgrade `MessagePack` to the patched version for your release line.\n2. Upgrade companion MessagePack packages in the same dependency graph to the coordinated patched versions.\n\nThe fix should reject negative and excessive uncompressed lengths before allocation. It should also cap aggregate decompressed size for block arrays and expose or honor an appropriate maximum decompressed length policy.\n\n## Workarounds\n\nPatching is recommended.\n\nUntil a patched version is available, do not enable MessagePack-CSharp's built-in LZ4 compression modes for untrusted inputs. If compression is required, enforce strict compressed and decompressed size limits outside MessagePack-CSharp before deserialization.\n\n## Resources\n\n- `MESSAGEPACKCSHARP-OPEN-004`: LZ4 decompression allocation from unbounded uncompressed length\n- `MESSAGEPACKCSHARP-011`: duplicate decompression-bomb finding\n- CWE-409: Improper Handling of Highly Compressed Data\n- CWE-770: Allocation of Resources Without Limits or Throttling",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "NuGet",
      "name" : "MessagePack"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.5.301"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "NuGet",
      "name" : "MessagePack"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3.0"
      }, {
        "fixed" : "3.1.7"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/MessagePack-CSharp/MessagePack-CSharp/security/advisories/GHSA-v72x-2h86-7f8m"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-48510"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/MessagePack-CSharp/MessagePack-CSharp"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-409", "CWE-770" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-06-25T18:53:44Z",
    "nvd_published_at" : "2026-06-22T22:16:47Z"
  }
}