Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Note that Coinbase maturity interval does not protect JoinSplits #1499

Merged
merged 2 commits into from Oct 14, 2016

Conversation

arcalinea
Copy link
Contributor

Changed wording of Block Chain Reorganization section in security-warnings.md to note that we did not change Coinbase maturity #1387, but that this also does not protect JoinSplits from becoming invalidated in the case of a block chain reorg #953

@ebfull
Copy link
Contributor

ebfull commented Oct 8, 2016

Double spends can also cause rolled back transactions to be invalidated during a reorg, but I think that's the only other exception that Bitcoin has.

@bitcartel bitcartel added this to the 1.0.0-rc1 milestone Oct 10, 2016
@bitcartel bitcartel added the A-documentation Area: Documentation label Oct 10, 2016
@bitcartel
Copy link
Contributor

@ebfull: For the pull request, should @arcalinea document this? Also found an interesting case here, where a transaction was roll-backed during a reorg, but now no longer exists because it would have double-spent on the winning fork. https://bitcointalk.org/index.php?topic=152348.0


Users should be aware of new behavior in Zcash that differs significantly from Bitcoin: in the case of a block chain reorganization, Bitcoin's coinbase maturity rule helps ensure that any reorg shorter than the maturity interval will not invalidate any of the rolled-back transactions. However for Zcash, all JoinSplits which were anchored within the reorg interval will become invalid, rolling back transactions and reverting funds to the original owner. The transaction rebroadcast mechanism inherited from Bitcoin will not successfully rebroadcast transactions containing JoinSplits if the anchor needs to change—the JoinSplit creator must do that.
Users should be aware of new behavior in Zcash that differs significantly from Bitcoin: in the case of a block chain reorganization, Bitcoin's coinbase maturity rule helps ensure that any reorg shorter than the maturity interval will not invalidate any of the rolled-back transactions. Zcash keeps Bitcoin's 100 block maturity lapse for generation transactions, but because JoinSplits must be anchored within a block, the protections this provides are much more limited in scope. In the case of a block chain reorg for Zcash, all JoinSplits which were anchored within the reorg interval and any transactions that depend on them will become invalid, rolling back transactions and reverting funds to the original owner. The transaction rebroadcast mechanism inherited from Bitcoin will not successfully rebroadcast transactions depending on invalidated JoinSplits if the anchor needs to change. The creator of an invalidated JoinSplit, as well as the creators of all transactions dependent on it, must rebroadcast the transactions themselves.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

s/helps ensure/helps to ensure/
s/100 block/100-block/
s/lapse/interval/
s/the protections this provides are much more limited in scope/this provides more limited protection against transactions being invalidated/
s/reorg/reorganization/g

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, incorporated.

@bitcartel
Copy link
Contributor

ACK
@zkbot r+

@zkbot
Copy link
Contributor

zkbot commented Oct 14, 2016

📌 Commit 4f61aa6 has been approved by bitcartel

@zkbot
Copy link
Contributor

zkbot commented Oct 14, 2016

⌛ Testing commit 4f61aa6 with merge 6432b8c...

zkbot pushed a commit that referenced this pull request Oct 14, 2016
…r=bitcartel

Note that Coinbase maturity interval does not protect JoinSplits

Changed wording of Block Chain Reorganization section in security-warnings.md to note that we did not change Coinbase maturity #1387, but that this also does not protect JoinSplits from becoming invalidated in the case of a block chain reorg #953
@zkbot
Copy link
Contributor

zkbot commented Oct 14, 2016

☀️ Test successful - zcash

@zkbot zkbot merged commit 4f61aa6 into zcash:master Oct 14, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-documentation Area: Documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants