CVE-2026-47734: Dulwich Dulwich Has Unbounded Memory Allocation Vulnerability
MODERATECVE-2026-47734 is a MODERATE (CVSS 5.7) dulwich has unbounded memory allocation vulnerability (CWE-789: Memory Allocation with Excessive Size Value) affecting Dulwich libraries in the PyPI ecosystem. The issue involves dulwich has unbounded memory allocation in receive-pack from crafted thin packs. Remediation is available by upgrading affected packages to version 1.2.5.
CVE-2026-47734 at a Glance
Security Impact
CVSS: 5.7
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:N/I:N/A:H).
How to Fix CVE-2026-47734
To remediate this vulnerability, upgrade all affected Dulwich dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install dulwich>=1.2.5
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show dulwich
How to Check if You Are Affected
To determine whether your Python environment is affected by CVE-2026-47734, inspect your installed packages using pip:
pip show dulwich
Analyze the terminal output to locate any version of Dulwich in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.2.5), your application is affected.
Note: The pip show dulwich command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-789: Memory Allocation with Excessive Size Value, where the product allocates memory based on an untrusted, large size value, but it does not ensure that the size is within expected limits, allowing arbitrary amounts of memory to be allocated. In Dulwich, 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
CVE-2026-47734 Affected Dulwich Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
dulwich
|
PyPI |
≥ 0.1.0
< 1.2.5
|
1.2.5
|
References
Frequently Asked Questions
What is CVE-2026-47734?
Which Dulwich versions are affected?
What version fixes CVE-2026-47734?
Is dulwich affected?
What is the CVSS score of CVE-2026-47734?
What CWE is associated with CVE-2026-47734?
How can I check PyPI dependencies for CVE-2026-47734?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-xrvj-v92f-53gj",
"modified" : "2026-06-11T14:07:18Z",
"published" : "2026-06-08T23:43:42Z",
"aliases" : [ "CVE-2026-47734" ],
"summary" : "Dulwich has unbounded memory allocation in receive-pack from crafted thin packs",
"details" : "## Impact\n\nAn uncontrolled-resource-consumption (memory exhaustion) denial-of-service vulnerability (CWE-400 / CWE-789).\n\nA client with push access could push a tiny crafted thin pack (~174 bytes) whose delta header declares a huge dest_size. When dulwich ingested it via add_thin_pack / apply_delta, it would allocate hundreds of MB of memory based on that attacker-controlled size, with no relationship to the actual bytes received.\n\nWho is impacted: Operators running a Dulwich-based Git server that exposes git-receive-pack (i.e. accepts pushes) -\nfor example via dulwich.server functionality, the HTTP smart server, or anything built on ReceivePackHandler. \n\n## Patches\n\nPatched in 1.2.5.\n\nadd_thin_pack now accepts a max_input_size keyword (bytes; 0/None = unlimited, matching git's semantics), and ReceivePackHandler reads receive.maxInputSize from the repository config and passes it through. Wire reads are counted and a PackInputTooLarge exception is raised once the cap is exceeded - equivalent to git index-pack --max-input-size.\n\nUsers should upgrade to Dulwich 1.2.5 or later and set receive.maxInputSize in their server's repository config to a sane bound for their environment.\n\n## Workarounds\n\nOn unpatched versions, receive.maxInputSize has no effect, so it cannot be used as a workaround. Until upgrading, operators should:\n\n- Restrict dulwich-receive-pack (push) access to trusted, authenticated clients only, or disable it entirely on servers that only need to serve fetches.\n- Run the server under an OS-level memory limit (e.g. ulimit, cgroups/MemoryMax, or a container memory limit) so a malicious push is killed rather than taking down the host.\n\n## Resources\n\n- git's receive.maxInputSize / git index-pack --max-input-size documentation \n- Reported by Liyi, Ziyue, Strick, Maurice and Chenchen @ University of Sydney",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:N/I:N/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "dulwich"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0.1.0"
}, {
"fixed" : "1.2.5"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/jelmer/dulwich/security/advisories/GHSA-xrvj-v92f-53gj"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-47734"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/jelmer/dulwich"
}, {
"type" : "WEB",
"url" : "https://github.com/jelmer/dulwich/releases/tag/dulwich-1.2.5"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-400", "CWE-789" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2026-06-08T23:43:42Z",
"nvd_published_at" : "2026-06-10T23:16:48Z"
}
}