Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2022-21688: CWE-125: Out-of-bounds Read in onionshare onionshare

0
Medium
Published: Tue Jan 18 2022 (01/18/2022, 21:45:11 UTC)
Source: CVE
Vendor/Project: onionshare
Product: onionshare

Description

OnionShare is an open source tool that lets you securely and anonymously share files, host websites, and chat with friends using the Tor network. Affected versions of the desktop application were found to be vulnerable to denial of service via an undisclosed vulnerability in the QT image parsing. Roughly 20 bytes lead to 2GB memory consumption and this can be triggered multiple times. To be abused, this vulnerability requires rendering in the history tab, so some user interaction is required. An adversary with knowledge of the Onion service address in public mode or with authentication in private mode can perform a Denial of Service attack, which quickly results in out-of-memory for the server. This requires the desktop application with rendered history, therefore the impact is only elevated. This issue has been patched in version 2.5.

AI-Powered Analysis

AILast updated: 06/23/2025, 18:18:04 UTC

Technical Analysis

CVE-2022-21688 is a vulnerability identified in OnionShare, an open-source desktop application that enables secure and anonymous file sharing, website hosting, and chat over the Tor network. The vulnerability is classified as CWE-125, an out-of-bounds read, specifically triggered during the parsing of images within the QT framework used by the application. The flaw allows an attacker to cause excessive memory consumption—approximately 2GB per trigger—by supplying roughly 20 bytes of crafted data that is processed when rendering the history tab in the OnionShare desktop client. This memory exhaustion can be triggered multiple times, leading to a denial of service (DoS) condition where the application becomes unresponsive or crashes due to out-of-memory errors. Exploitation requires some user interaction, specifically the rendering of the history tab, and access to the Onion service address. In public mode, the attacker needs knowledge of the Onion service address, while in private mode, authentication is required. The vulnerability affects versions of OnionShare prior to 2.5 and has been patched in version 2.5. There are no known exploits in the wild at the time of reporting. The impact is primarily a denial of service affecting availability rather than confidentiality or integrity. The scope is limited to the desktop application with rendered history, and exploitation requires user interaction and some level of access to the service address, which limits the attack surface somewhat.

Potential Impact

For European organizations using OnionShare versions prior to 2.5, this vulnerability could result in denial of service conditions that disrupt secure file sharing, anonymous communications, or hosting of services over Tor. This could impact organizations relying on OnionShare for privacy-sensitive communications, including journalists, activists, NGOs, or enterprises handling sensitive data. The DoS could degrade operational availability, potentially interrupting critical workflows or communications. While the vulnerability does not directly compromise confidentiality or integrity, the loss of availability in privacy-focused tools can indirectly affect organizational security posture and trust. Given the requirement for user interaction and knowledge of service addresses, the risk is elevated but not trivial. Organizations with high reliance on OnionShare for secure communications may face operational disruptions, especially if they have not updated to the patched version. The impact is more pronounced in environments where OnionShare is integrated into broader privacy or anonymity workflows, as denial of service could force fallback to less secure alternatives or cause delays in sensitive communications.

Mitigation Recommendations

Organizations should immediately verify the version of OnionShare deployed and upgrade to version 2.5 or later, where this vulnerability is patched. Beyond patching, administrators should restrict access to OnionShare service addresses, especially in private mode, to trusted users only, minimizing the risk of unauthorized triggering of the vulnerability. Monitoring and limiting user interaction with the history tab or disabling history rendering where feasible can reduce exposure. Network-level controls such as firewall rules or Tor configuration adjustments can limit access to OnionShare services to known clients. Additionally, organizations should implement resource monitoring on hosts running OnionShare to detect abnormal memory consumption indicative of exploitation attempts. Incident response plans should include procedures for rapid recovery from DoS conditions affecting OnionShare services. Finally, educating users about the risks of interacting with untrusted OnionShare links or services can reduce inadvertent triggering of the vulnerability.

Need more detailed analysis?Upgrade to Pro Console

Technical Details

Data Version
5.1
Assigner Short Name
GitHub_M
Date Reserved
2021-11-16T00:00:00.000Z
Cisa Enriched
true

Threat ID: 682d9842c4522896dcbf22c4

Added to database: 5/21/2025, 9:09:22 AM

Last enriched: 6/23/2025, 6:18:04 PM

Last updated: 2/7/2026, 3:06:33 AM

Views: 37

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console in Console -> Billing for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats