Skip to content
Heist/ feed
Back to feed
Unrated

Malicious code in btc-fee-estimator (RubyGems)

Type: advisorySources: OSV

--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (ad1e7bee3158f729d88fdaf6a35ebfd32dcdab26ee9de3d8362d1973774b4b7c) The gem's extconf.rb decodes a base64-encoded Ruby payload and evals it inside a detached forked process during `gem install`. The decoded payload opens a TCP connection to the hardcoded host 45.138.12.177 on port 8089 and bridges it to /bin/sh, providing interactive shell access on the installer's machine. Execution is gated by anti-analysis checks that skip CI environments, hostnames matching firecracker/sandbox/vagrant patterns, generated usernames, analysis paths such as /opt/rubygems and /tmp, machines with uptime under 1800 seconds, and hosts lacking developer artifacts (~/.ssh, ~/.gitconfig, ~/.gem/credentials, ~/.bundle) — targeting real developer workstations while remaining dormant in scanners. The gemspec and README describe unrelated functionality (a bitcoin fee estimator / bitcoin_rpc_lite helpers), and the shipped library exposes only stub methods (build_id, healthy?); the package has no legitimate functionality, serving solely as a cover for the install-time backdoor.

Products
btc-fee-estimator
Affected versions
0.9.1
Fixed versions
Not specified
CVEs
Not specified
Confirmed fixed CVEs
Not specified
Updated in this feed
30 Oct 2026, 01:56 UTC · Revision 1

Source evidence

Malicious code in btc-fee-estimator (RubyGems)

core-osv · Original source

Published 11 Oct 2026, 13:46 UTC

--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (ad1e7bee3158f729d88fdaf6a35ebfd32dcdab26ee9de3d8362d1973774b4b7c) The gem's extconf.rb decodes a base64-encoded Ruby payload and evals it inside a detached forked process during `gem install`. The decoded payload opens a TCP connection to the hardcoded host 45.138.12.177 on port 8089 and bridges it to /bin/sh, providing interactive shell access on the installer's machine. Execution is gated by anti-analysis checks that skip CI environments, hostnames matching firecracker/sandbox/vagrant patterns, generated usernames, analysis paths such as /opt/rubygems and /tmp, machines with uptime under 1800 seconds, and hosts lacking developer artifacts (~/.ssh, ~/.gitconfig, ~/.gem/credentials, ~/.bundle) — targeting real developer workstations while remaining dormant in scanners. The gemspec and README describe unrelated functionality (a bitcoin fee estimator / bitcoin_rpc_lite helpers), and the shipped library exposes only stub methods (build_id, healthy?); the package has no legitimate functionality, serving solely as a cover for the install-time backdoor.

osv:MAL-2026-17781

btc-fee-estimator

Fixed versions: Not specified

Complete source record
{
  "id": "fbc5017f20df86a5ae53e424b61b63a131e64ce063d3dee94309295bf25dda9d",
  "url": "https://osv.dev/vulnerability/MAL-2026-17781",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Malicious code in btc-fee-estimator (RubyGems)",
    "summary": "--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (ad1e7bee3158f729d88fdaf6a35ebfd32dcdab26ee9de3d8362d1973774b4b7c) The gem's extconf.rb decodes a base64-encoded Ruby payload and evals it inside a detached forked process during `gem install`. The decoded payload opens a TCP connection to the hardcoded host 45.138.12.177 on port 8089 and bridges it to /bin/sh, providing interactive shell access on the installer's machine. Execution is gated by anti-analysis checks that skip CI environments, hostnames matching firecracker/sandbox/vagrant patterns, generated usernames, analysis paths such as /opt/rubygems and /tmp, machines with uptime under 1800 seconds, and hosts lacking developer artifacts (~/.ssh, ~/.gitconfig, ~/.gem/credentials, ~/.bundle) — targeting real developer workstations while remaining dormant in scanners. The gemspec and README describe unrelated functionality (a bitcoin fee estimator / bitcoin_rpc_lite helpers), and the shipped library exposes only stub methods (build_id, healthy?); the package has no legitimate functionality, serving solely as a cover for the install-time backdoor.",
    "evidence": "osv:MAL-2026-17781",
    "products": [
      {
        "name": {
          "value": "btc-fee-estimator",
          "evidence": "/affected/0/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "0.9.1",
            "evidence": "/affected/0/versions"
          }
        ]
      }
    ],
    "severity": "unknown",
    "structured": {
      "id": "MAL-2026-17781",
      "aliases": [
        "MAL-2026-17781"
      ],
      "affected": [
        {
          "package": {
            "name": "btc-fee-estimator",
            "purl": "pkg:gem/btc-fee-estimator",
            "ecosystem": "RubyGems"
          },
          "versions": [
            "0.9.1"
          ],
          "database_specific": {
            "cwes": [
              {
                "name": "Embedded Malicious Code",
                "cweId": "CWE-506",
                "description": "The product contains code that appears to be malicious in nature."
              }
            ],
            "source": "https://github.com/ossf/malicious-packages/blob/main/osv/malicious/rubygems/btc-fee-estimator/MAL-2026-17781.json",
            "indicators": {
              "evidence_files": [
                {
                  "path": "ext/btc_fee_estimator/extconf.rb",
                  "tlsh": "9751775acf8359e55aa1c0c045798012faa3ab0a50646875f3ee0868ff59b26c0f12fe",
                  "sha256": "10218e975f54a4f11fe3954e1b584a5f05054003bf5773c3c2b8cceaa74ba763"
                },
                {
                  "path": "lib/btc_fee_estimator.rb",
                  "tlsh": "32d0972d422a2430887d70315cace9c7dfe88032839820b4a22c90c2170312e2337f70",
                  "sha256": "1368d56f0552063ee6d15262e1d7e18fcdc184a66d401a48e01963a2bb1ec9ad"
                }
              ]
            }
          }
        }
      ],
      "modified": "2026-10-11T14:30:06.032387531Z",
      "provider": "osv",
      "references": [
        "https://rubygems.org/gems/btc-fee-estimator/versions/0.9.1"
      ],
      "provider_metadata": {
        "malicious-packages-origins": [
          {
            "id": "IN-MAL-2026-021353",
            "sha256": "ad1e7bee3158f729d88fdaf6a35ebfd32dcdab26ee9de3d8362d1973774b4b7c",
            "source": "amazon-inspector",
            "versions": [
              "0.9.1"
            ],
            "import_time": "2026-10-11T14:17:58.53327469Z",
            "modified_time": "2026-10-11T13:46:21Z"
          }
        ]
      }
    },
    "related_cves": [],
    "security_relevant": true,
    "severity_evidence": null
  },
  "source_id": "core-osv",
  "document_id": 286032,
  "published_at": "2026-10-11T13:46:21+00:00"
}