<?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>Pickle — CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/tags/pickle/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata — refreshed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Sat, 04 Apr 2026 06:43:37 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/tags/pickle/feed.xml" rel="self" type="application/rss+xml"/><item><title>pyLoad Arbitrary Code Execution via Malicious Session Deserialization</title><link>https://feed.craftedsignal.io/briefs/2026-04-pyload-rce/</link><pubDate>Sat, 04 Apr 2026 06:43:37 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2026-04-pyload-rce/</guid><description>pyLoad is vulnerable to arbitrary code execution via an unprotected `storage_folder` configuration option, allowing an attacker with `SETTINGS` and `ADD` permissions to write a malicious pickle payload to the Flask session store and execute arbitrary code upon subsequent HTTP requests.</description><content:encoded><![CDATA[<p>pyLoad, a download manager, is susceptible to arbitrary code execution due to an insecure configuration option related to the storage folder. This vulnerability arises from the incomplete fix for CVE-2026-33509. Specifically, the <code>storage_folder</code> option is not included in the <code>ADMIN_ONLY_OPTIONS</code> set, which allows users with <code>SETTINGS</code> and <code>ADD</code> permissions to modify it. By redirecting downloads to the Flask filesystem session store, an attacker can plant a malicious pickle payload as a predictable session file. Subsequently, any HTTP request containing the corresponding crafted session cookie will trigger the deserialization of the payload, resulting in arbitrary code execution. This issue affects pyLoad versions up to and including 0.5.0b3. The observed exploitation involves manipulating the download directory to write malicious files into the Flask session store, ultimately leading to code execution on the host.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>An attacker gains a non-admin user account with both <code>SETTINGS</code> and <code>ADD</code> permissions in pyLoad.</li>
<li>The attacker uses the <code>/api/set_config_value</code> endpoint to modify the <code>storage_folder</code> option, setting its value to the Flask session store directory: <code>/tmp/pyLoad/flask</code>. This bypasses existing path restrictions.</li>
<li>The attacker calculates the target session filename by computing the MD5 hash of the string &ldquo;session:ATTACKER_SESSION_ID&rdquo;.</li>
<li>The attacker hosts a malicious pickle payload (e.g., <code>92912f771df217fb6fbfded6705dd47c</code>) on a remote server.</li>
<li>The attacker uses the <code>/api/add_package</code> endpoint to add a download package. The download link points to the hosted malicious pickle payload on the attacker&rsquo;s server: <code>http://attacker.com/92912f771df217fb6fbfded6705dd47c</code>. The <code>dest</code> parameter specifies where to store the downloaded file.</li>
<li>pyLoad downloads the malicious pickle payload and saves it to the Flask session store directory, naming it according to the MD5 hash calculated earlier.</li>
<li>The attacker crafts an HTTP request to the pyLoad server, including a cookie named <code>pyload_session_{port}</code> with the value <code>ATTACKER_SESSION_ID</code>.  The port number is derived from the pyLoad configuration.</li>
<li>Upon receiving the request with the crafted cookie, Flask attempts to load the session data from the corresponding file. The <code>cachelib</code> library deserializes the malicious pickle payload using <code>pickle.load()</code>, triggering arbitrary code execution.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>Successful exploitation allows a non-admin user with SETTINGS and ADD permissions to achieve arbitrary code execution as the pyload service user. This grants the attacker the ability to execute arbitrary commands, read environment variables (potentially exposing API keys and credentials), access the filesystem (including download history and user databases), and potentially pivot to other network resources. The vulnerability requires no authentication to trigger the final stage of exploitation, increasing its severity and potential impact.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Deploy the following Sigma rule to detect attempts to modify the <code>storage_folder</code> configuration option to point to the Flask session directory (<code>/tmp/pyLoad/flask</code>): <code>Suspicious pyLoad Storage Folder Modification</code>.</li>
<li>Apply the suggested fix by adding <code>storage_folder</code> to the <code>ADMIN_ONLY_OPTIONS</code> set in the pyLoad configuration to prevent non-admin users from modifying it.</li>
<li>Block the malicious URLs used to deliver the pickle payload, specifically <code>http://attacker.com/92912f771df217fb6fbfded6705dd47c</code>, at your network perimeter.</li>
<li>Monitor for HTTP requests containing the crafted session cookie (<code>pyload_session_{port}=ATTACKER_SESSION_ID</code>), using a webserver or proxy log source, as it triggers the final stage of the attack.</li>
</ul>
]]></content:encoded><category domain="severity">critical</category><category domain="type">advisory</category><category>pyLoad</category><category>rce</category><category>pickle</category><category>deserialization</category><category>webserver</category></item></channel></rss>