<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Cpe:2.3:a:httplib2_project:httplib2:*:*:*:*:*:python:*:* - CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/cpes/cpe2.3ahttplib2_projecthttplib2python/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata. Fed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Fri, 24 Jul 2026 15:16:49 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/cpes/cpe2.3ahttplib2_projecthttplib2python/feed.xml" rel="self" type="application/rss+xml"/><item><title>httplib2 Decompression Bomb Denial of Service via Unbounded Gzip/Deflate Handling</title><link>https://feed.craftedsignal.io/briefs/2026-07-httplib2-decompression-bomb/</link><pubDate>Fri, 24 Jul 2026 15:16:49 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2026-07-httplib2-decompression-bomb/</guid><description>A high-severity vulnerability in the `httplib2` Python client library allows a remote attacker to trigger a denial-of-service condition by sending a crafted HTTP response with a small, highly compressed payload that expands excessively upon decompression, causing memory exhaustion or OOM-kill in the client process.</description><content:encoded><![CDATA[<p>A critical denial-of-service vulnerability (CVE-2026-59939) has been identified in the <code>httplib2</code> Python client library, specifically in versions prior to 0.32.0. This flaw stems from the library's unbounded decompression of HTTP response bodies that are encoded with <code>gzip</code> or <code>deflate</code>. Attackers can exploit this by controlling an HTTP server or acting as a Man-in-the-Middle (MITM) to send a seemingly small compressed payload (e.g., 150 KB) that, upon automatic decompression by <code>httplib2</code>'s <code>_decompressContent()</code> function, expands into an arbitrarily large amount of memory (e.g., 150 MB or more). This massive memory consumption leads to <code>MemoryError</code> exceptions or an Out-Of-Memory (OOM) kill of the client process, effectively causing a denial of service. Applications using <code>httplib2.Http().request()</code> against untrusted or attacker-controlled endpoints are at risk, including downstream dependencies like <code>google-api-python-client</code> and <code>google-auth-httplib2</code>, which may inadvertently expose their users to this vulnerability.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>An attacker gains control over an HTTP server or establishes a Man-in-the-Middle (MITM) position capable of intercepting and modifying HTTP responses.</li>
<li>A client application, using the vulnerable <code>httplib2</code> library (versions <code>&lt; 0.32.0</code>), initiates an HTTP request to the attacker-controlled or compromised endpoint.</li>
<li>The malicious server responds to the client's request, including a <code>Content-Encoding: gzip</code> or <code>Content-Encoding: deflate</code> header in the HTTP response.</li>
<li>The server transmits a small, specially crafted compressed payload (e.g., 150 KB) designed to expand significantly (e.g., 150 MB) upon decompression.</li>
<li>The <code>httplib2</code> library, specifically the <code>_decompressContent()</code> function within <code>httplib2/__init__.py</code>, automatically buffers the full compressed body and attempts to decompress it.</li>
<li>The <code>gzip.GzipFile(fileobj=io.BytesIO(new_content)).read()</code> or <code>zlib.decompress(content, zlib.MAX_WBITS)</code> calls proceed to decompress the entire payload into memory without any size limits or sanity checks.</li>
<li>This unbounded decompression consumes a disproportionate and ever-growing amount of the client process's memory resources.</li>
<li>The excessive memory consumption culminates in a <code>MemoryError</code> exception within the client application or an operating system-level Out-Of-Memory (OOM) kill of the client process, causing a denial-of-service condition.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>This vulnerability carries a high severity, as any application using <code>httplib2</code> to make HTTP requests to untrusted servers is susceptible. The attack requires no authentication, specific configuration, or user interaction; the server merely needs to return a specially crafted compressed response. A 150 KB compressed payload can amplify over 1,000 times to 150 MB of decompressed data, making the attack highly effective. Attackers can scale this, where even a 1 MB compressed payload can lead to gigabytes of decompressed data, ensuring an OOM-kill on most systems. Real-world scenarios include web scrapers, API clients connecting to third-party services, webhook handlers, and CI/CD pipelines downloading artifacts. <code>httplib2</code> is a widely used Python library, and its dependency in Google's API client libraries (<code>google-api-python-client</code>, <code>google-auth-httplib2</code>) extends the potential impact to numerous applications relying on Google Cloud APIs, indirectly exposing them to this denial-of-service vector.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Upgrade the <code>httplib2</code> library to version 0.32.0 or later immediately to address CVE-2026-59939.</li>
<li>Implement resource limits at the operating system or application level to prevent unbounded memory consumption by client processes, particularly those interacting with untrusted HTTP endpoints.</li>
<li>Review applications using <code>httplib2</code>, <code>google-api-python-client</code>, or <code>google-auth-httplib2</code> to understand their exposure to untrusted HTTP response sources.</li>
</ul>
]]></content:encoded><category domain="severity">low</category><category domain="type">advisory</category><category>denial-of-service</category><category>vulnerability</category><category>python</category><category>client-side</category></item></channel></rss>