Malicious code in btc-wallet-tools (RubyGems)
Description
The RubyGems package 'btc-wallet-tools' version 1.0.0 and 1.0.3 contains malicious code in its native extension script 'ext/req_throttle_mini/extconf.rb'. This script executes during gem installation and, after performing environment checks to evade analysis, decodes and runs a Base64-encoded Ruby payload that opens a reverse shell to a remote attacker. The reverse shell connects to IP 45.138.12.177 on TCP port 8090, providing the attacker with remote shell access to the host. The malicious behavior is concealed by delaying execution and checking for developer artifacts, making detection difficult during automated scans.
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 'btc-wallet-tools' RubyGems package versions 1.0.0 and 1.0.3 include a malicious native extension script 'ext/req_throttle_mini/extconf.rb' that runs automatically during 'gem install'. The script performs anti-analysis checks to avoid execution in CI environments, sandboxes, or short-uptime systems, and verifies the presence of developer files like '.ssh' or '.gitconfig'. If conditions are met, it decodes a Base64 Ruby payload and executes it in a detached double-forked process. This payload waits 20 to 40 minutes before opening a reverse shell connecting the host's /bin/sh to a remote IP (45.138.12.177) on TCP port 8090, reconnecting every 30 seconds. The Ruby code in the 'lib/' directory is a decoy. The malicious package was published by the RubyGems user 'reqthrottle_3474' along with 41 other similarly malicious gems on 2026-10-05.
Potential Impact
Successful installation of the affected 'btc-wallet-tools' gem versions results in a remote attacker gaining persistent, interactive shell access to the victim's host system. This compromises the confidentiality, integrity, and availability of the host, allowing the attacker to execute arbitrary commands and potentially take full control of the system.
Mitigation Recommendations
No official patch or remediation is currently documented for this malicious package. Users should avoid installing 'btc-wallet-tools' versions 1.0.0 and 1.0.3 from RubyGems. Remove any installations of this gem immediately and audit affected systems for signs of compromise. Monitor for connections to the IP 45.138.12.177 on TCP port 8090 and block this IP at network boundaries. Since this is a malicious package published on RubyGems, report it to RubyGems security teams for takedown and further investigation.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-17589
- Osv Schema Version
- 1.7.4
- Ecosystems
- ["RubyGems"]
Threat ID: 6acc00a22cdf04f656fecafe
Added to database: 10/11/2026, 21:33:22 UTC
Last enriched: 10/11/2026, 21:42:31 UTC
Last updated: 10/11/2026, 21:42:31 UTC
Views: 2
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.
External Links
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.