CVE-2021-41868: Remote unauthenticated attackers able to upload files in Onionshare
9.8
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.71356%
CWE
-
Published
11/19/2021
Updated
1/27/2023
KEV Status
No
Technology
Python
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
onionshare-cli | pip | >= 2.3, < 2.4 | 2.4 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stemmed from improper order of operations in authentication checks. Evidence from GHSA-7g47-xxff-9p85 and issue #1396 shows that: 1) The receive_mode.py file contained HTTP handlers that processed file uploads before validating credentials via Flask-HTTPAuth 2) The fix in PR #1404 removed Flask-HTTPAuth entirely and implemented Tor ClientAuth at the network layer 3) The original implementation's 'upload first, authenticate later' pattern is explicitly called out in the vulnerability reports. The handle_upload and upload_ajax functions are the primary upload entrypoints in receive_mode.py that would contain this flawed logic.