<p>As with many things in Bitcoin, it is likely simply because it worked well enough, and such an attack was not immediately obvious.</p>

<p>Several of the choices made in the early days of Bitcoin don't have a full justification behind them, and were simply made because it worked at the time without any major, obvious shortcomings. This is one such scenario, as far as I'm aware.</p>

CC BY-SA 4.0
2018-11-13T13:56:07.367Z
2018-11-13T13:56:07.367Z
Raghav Sood
<p>At risk of creating a "lets discuss politics" question, let me clarify that what I want to know is whether there is a known benefit to Satoshi's "duplicate the last hash" merkle tree implementation over the seemingly obvious "append zeros".</p>

<p>For those who don't know, the bitcoin merkle tree algorithm allows blocks to be mutated if a transaction can be duplicated which lead to <a href="https://en.bitcoin.it/wiki/Common_Vulnerabilities_and_Exposures#CVE-2012-2459" rel="nofollow noreferrer">CSV-2012-2459</a>.</p>

<security><protocol><merkle-tree>
Why was an insecure merkle tree implementation chosen?
Caleb James DeLisle
# Why was an insecure merkle tree implementation chosen?

(Asked by: username_0 on 2018-11-13)

At risk of creating a "lets discuss politics" question, let me clarify that what I want to know is whether there is a known benefit to Satoshi's "duplicate the last hash" merkle tree implementation over the seemingly obvious "append zeros".

For those who don't know, the bitcoin merkle tree algorithm allows blocks to be mutated if a transaction can be duplicated which lead to [CSV-2012-2459](https://en.bitcoin.it/wiki/Common_Vulnerabilities_and_Exposures#CVE-2012-2459).

**Tags:** security, protocol, merkle-tree


---

## 1 answers

### Answer by username_1 on 2018-11-13. Score: 9 | Accepted answer

As with many things in Bitcoin, it is likely simply because it worked well enough, and such an attack was not immediately obvious.

Several of the choices made in the early days of Bitcoin don't have a full justification behind them, and were simply made because it worked at the time without any major, obvious shortcomings. This is one such scenario, as far as I'm aware.


---

