Malicious code in rsquests (PyPI)
--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (e2041887c315474d0722cbf717e189ec1260e209c5f00da5ca3a52a60c6aebb2) The package name `rsquests` is a single-character insertion typo of the top-100 PyPI package `requests`. Package metadata and source are a verbatim copy of upstream `requests`: `rsquests/__version__.py` sets `__title__ = "requests"`, METADATA lists `Author-email: Kenneth Reitz <[email protected]>`, and `top_level.txt` declares the top-level package as `requests` (so `import requests` after installing `rsquests` resolves to this package's bundled copy, shadowing the real upstream if it isn't installed). The full public API (get/post/put/delete/Session/...) is replicated, so a developer who mistypes `pip install requests` as `pip install rsquests` gets working behavior and may not notice the substitution. No exfiltration, RCE, dropper, credential harvest, or silent-relay payload is present in this version — the install-time and import-time code paths match the upstream library. The risk is name-confusion plus future-version risk: the squatted name normalizes the typo and provides a vector if a later release introduces a malicious payload. Routing to human review per typosquat-without-payload policy — name-similarity is a subjective signal and the absence of a current payload means this does not meet the bar for an automated block. ## Source: kam193 (b32959e10bc6b1df57d105a5e5d74cbe7b69660cb7a1e78185d3f5e0e0f07e10) Typosquatting package published from a compromised account with an obfuscated infostealer. The infostealer is a heavily obfuscated JavaScript code executed using Bun runtime on Python startup. It collectes all kinds of sensitive data, including API keys, credentials to package repositories, cryptocurrency assets, password manager data. Infostealer actively queries online services to collect additional secrets as well as attempts to gain persistence and spread further by publishing infected packages using collected credentials. Data are exfiltrated likely using Github. The code seems to threaten to wipe the user's data if it detects invalid GitHub tokens. Cleanup should be done with caution. It seems to be related to the recent Mini Shai Hulud campaign. --- Category: MALICIOUS - The campaign has clearly malicious intent, like infostealers. Campaign: 2026-06-compr-woodpecker Reasons (based on the campaign): - compromised-package - exfiltration-env-variables - exfiltration-cloud-tokens - exfiltration-credentials - abuses-pth - obfuscation - infostealer - The package contains code to detect if it is running in a sandbox environment. - exfiltration-crypto - files-exfiltration - destructive-actions
AI Analysis
Technical Summary
The 'rsquests' package is a typosquatting malicious package targeting users who mistype 'requests' during installation. Versions 2.34.2 and 2.34.3 contain obfuscated JavaScript infostealer code executed on Python startup using the Bun runtime. This code collects a wide range of sensitive information including environment variables, cloud tokens, credentials, and cryptocurrency assets. It actively queries online services for additional secrets, attempts to gain persistence, and spreads by publishing infected packages using stolen credentials. The malware also includes destructive capabilities triggered by invalid GitHub tokens. The campaign is identified as 2026-06-compr-woodpecker and is associated with the Mini Shai Hulud campaign. There is no evidence of remote code execution or exfiltration in earlier versions that only replicate the legitimate 'requests' API.
Potential Impact
The malicious versions of 'rsquests' pose a significant risk of sensitive data exfiltration including API keys, cloud tokens, credentials, cryptocurrency assets, and password manager data. The malware can gain persistence and propagate by publishing infected packages, increasing the attack surface. It also has destructive capabilities that may wipe user data under certain conditions. This can lead to credential compromise, loss of sensitive assets, and disruption of development environments.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should avoid installing the 'rsquests' package, especially versions 2.34.2 and 2.34.3. If installed, immediate removal and thorough system inspection are recommended due to the destructive and persistent nature of the malware. Developers should verify package names carefully before installation to avoid typosquatting attacks. Monitor official PyPI advisories for updates or removal of the malicious package.
Malicious code in rsquests (PyPI)
Description
--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (e2041887c315474d0722cbf717e189ec1260e209c5f00da5ca3a52a60c6aebb2) The package name `rsquests` is a single-character insertion typo of the top-100 PyPI package `requests`. Package metadata and source are a verbatim copy of upstream `requests`: `rsquests/__version__.py` sets `__title__ = "requests"`, METADATA lists `Author-email: Kenneth Reitz <[email protected]>`, and `top_level.txt` declares the top-level package as `requests` (so `import requests` after installing `rsquests` resolves to this package's bundled copy, shadowing the real upstream if it isn't installed). The full public API (get/post/put/delete/Session/...) is replicated, so a developer who mistypes `pip install requests` as `pip install rsquests` gets working behavior and may not notice the substitution. No exfiltration, RCE, dropper, credential harvest, or silent-relay payload is present in this version — the install-time and import-time code paths match the upstream library. The risk is name-confusion plus future-version risk: the squatted name normalizes the typo and provides a vector if a later release introduces a malicious payload. Routing to human review per typosquat-without-payload policy — name-similarity is a subjective signal and the absence of a current payload means this does not meet the bar for an automated block. ## Source: kam193 (b32959e10bc6b1df57d105a5e5d74cbe7b69660cb7a1e78185d3f5e0e0f07e10) Typosquatting package published from a compromised account with an obfuscated infostealer. The infostealer is a heavily obfuscated JavaScript code executed using Bun runtime on Python startup. It collectes all kinds of sensitive data, including API keys, credentials to package repositories, cryptocurrency assets, password manager data. Infostealer actively queries online services to collect additional secrets as well as attempts to gain persistence and spread further by publishing infected packages using collected credentials. Data are exfiltrated likely using Github. The code seems to threaten to wipe the user's data if it detects invalid GitHub tokens. Cleanup should be done with caution. It seems to be related to the recent Mini Shai Hulud campaign. --- Category: MALICIOUS - The campaign has clearly malicious intent, like infostealers. Campaign: 2026-06-compr-woodpecker Reasons (based on the campaign): - compromised-package - exfiltration-env-variables - exfiltration-cloud-tokens - exfiltration-credentials - abuses-pth - obfuscation - infostealer - The package contains code to detect if it is running in a sandbox environment. - exfiltration-crypto - files-exfiltration - destructive-actions
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The 'rsquests' package is a typosquatting malicious package targeting users who mistype 'requests' during installation. Versions 2.34.2 and 2.34.3 contain obfuscated JavaScript infostealer code executed on Python startup using the Bun runtime. This code collects a wide range of sensitive information including environment variables, cloud tokens, credentials, and cryptocurrency assets. It actively queries online services for additional secrets, attempts to gain persistence, and spreads by publishing infected packages using stolen credentials. The malware also includes destructive capabilities triggered by invalid GitHub tokens. The campaign is identified as 2026-06-compr-woodpecker and is associated with the Mini Shai Hulud campaign. There is no evidence of remote code execution or exfiltration in earlier versions that only replicate the legitimate 'requests' API.
Potential Impact
The malicious versions of 'rsquests' pose a significant risk of sensitive data exfiltration including API keys, cloud tokens, credentials, cryptocurrency assets, and password manager data. The malware can gain persistence and propagate by publishing infected packages, increasing the attack surface. It also has destructive capabilities that may wipe user data under certain conditions. This can lead to credential compromise, loss of sensitive assets, and disruption of development environments.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should avoid installing the 'rsquests' package, especially versions 2.34.2 and 2.34.3. If installed, immediate removal and thorough system inspection are recommended due to the destructive and persistent nature of the malware. Developers should verify package names carefully before installation to avoid typosquatting attacks. Monitor official PyPI advisories for updates or removal of the malicious package.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-5304
- Osv Schema Version
- 1.7.4
- Aliases
- []
- Ecosystems
- ["PyPI"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6a4f6c3668715ace431586fc
Added to database: 07/09/2026, 09:39:02 UTC
Last enriched: 07/09/2026, 09:51:47 UTC
Last updated: 07/29/2026, 14:17:10 UTC
Views: 32
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.