External risk intelligence

BitcoinJS Library Merkle Root Validation Vulnerability Allows Transaction Duplication.

CVE advisorySeverity: CRITICAL (CVSS 9.3)

CVE-2026-107846

The vulnerability exists in a JavaScript library (bitcoinjs-lib) used for building Bitcoin applications. While it affects tools like explorers or indexers, the library itself is a dependency included in codebases rather than a standalone network-facing service. Exposure depends on how a developer implements the library within their specific application, making direct public internet exposure uncommon and dependent on specific design choices.

Halo Surface Signal: 2 out of 5 — less likely to be public-facing.

External exposure likelihood

Horizon Alert

Summary of the vulnerability and why it matters

This advisory concerns a vulnerability in a JavaScript library used for Bitcoin-related applications. The flaw could allow malicious actors to manipulate transaction data, potentially leading to incorrect processing by services that rely on the library's validation functions, such as explorers or exchanges. The main concern is confirming if your applications utilize this specific library and are therefore exposed.

  • A library flaw could allow transaction data manipulation.
  • Confirms relevance for Bitcoin applications and services.
  • Understand exposure and validate library use.

Attack Path

How an attacker could exploit the issue

An attacker could manipulate transaction data within a Bitcoin block to create a situation where a block's Merkle root appears valid even with duplicate transactions. This could happen by a peer appending duplicate transactions, causing a different transaction list to retain the original Merkle root. Systems that rely on validating this root, such as explorers or SPV clients, might then process duplicated transactions, potentially leading to incorrect accounting or network instability.

  • Requires network access.
  • Achieved by sending specially crafted transactions.
  • Risk of incorrect transaction processing.

Live Threat

Current exploitation, exposure, and threat context

The bitcoinjs-lib library's block-root verification could be tricked into accepting a manipulated transaction list that retains a valid Merkle root. This could allow specially crafted transactions to be processed twice by consumer applications, or cause honest blocks to be rejected by SPV clients and other consumers.

  • Affected block-root validation logic.
  • Accepts recomputed root without checking mutation.
  • Duplicate transactions processed, blocks rejected.

Operational Fix

Recommended remediation, mitigation, and detection steps

Application owners and platform teams are likely responsible for addressing this vulnerability in the bitcoinjs-lib, as it impacts how block roots are validated in applications like explorers, exchange indexers, or SPV clients. The initial step is to identify all instances of the affected library, confirm their exposure and criticality, and then coordinate remediation efforts with accountable owners.

  • Ownership: Application and platform teams.
  • Verify first: Identify all library instances.
  • Action: Plan remediation based on risk.

Supplementary metadata

Validate whether this threat affects your internet-facing exposure.

Halo Threat Intelligence helps prioritize remediation with Halo Surface Signal and H/A/L/O context. Start exposure validation with a free external attack surface trial.

Frequently asked questions

What is bitcoinjs-lib used for?

bitcoinjs-lib is a foundational JavaScript library for Node.js and browser environments. It provides developers with the essential cryptographic and protocol primitives required to build Bitcoin-related software, such as transaction signing, address generation, and blockchain data parsing for services like explorers and wallet clients.

What is the vulnerability in CVE-2026-107846?

This vulnerability is classified as CWE-354 (Improper Validation of Integrity Check Value). The library fails to detect adjacent duplicate hashes when padding Merkle-tree levels. Consequently, the verification logic can be tricked into accepting a manipulated transaction list that preserves the original block header and Merkle root, essentially ignoring the modification.

How can an attacker trigger this issue?

An attacker triggers this by appending duplicate transactions to a block. Because the library's verification paths do not check for mutation, they accept the recomputed root as valid. This does not trigger if the application does not rely on the library to perform Merkle root validation for block headers, as the flaw is specific to the verification logic.

Is my software exposed to this vulnerability?

According to Halo Surface Signal, direct internet exposure is uncommon because this is a code dependency rather than a standalone service. Your exposure depends entirely on your application's design choices—specifically, if your software functions as a blockchain explorer, exchange indexer, or SPV client that uses affected versions to validate block-root data.

How do I fix this in my application?

The primary step is to identify all software components in your environment that include affected versions (2.3.0 through 5.2.1, 6.1.8, or 7.0.2). Once identified, you must update the library dependency to version 5.2.1, 6.1.8, or 7.0.2 to incorporate the corrected validation logic that properly handles mutation checks.

References