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

Enforce coinbase maturity in consensus rules #90

Open
alexdovzhanyn opened this issue Jan 31, 2019 · 0 comments
Open

Enforce coinbase maturity in consensus rules #90

alexdovzhanyn opened this issue Jan 31, 2019 · 0 comments
Labels
Difficulty: Intermediate This issue can be worked on by someone with a moderate amount of experience with the codebase Enhancement New feature or request Help Wanted Extra attention is needed

Comments

@alexdovzhanyn
Copy link
Owner

XEX is currently spendable as soon as it is mined. The issue with this instant allowance is that if a fork were to occur shortly after a block is generated, and the XEX generated in the coinbase of that block is spent, all transactions with that XEX would be invalidated (not delayed as what happens in a regular fork, as these transactions could never be valid because they are referencing a coinbase transaction that no longer exists). We need to define a coinbase maturation period which dictates how many blocks must be generated before a coinbase is deemed safe to spend. Bitcoin's coinbase maturation period is 101 blocks ~17 hours.

We should consider how many blocks a highly unlikely fork would constitute and base the maturation period from that. If we wanted to wait ~24 hours for coinbase transactions to be spendable we could set this threshold to 720 blocks.

@alexdovzhanyn alexdovzhanyn added Enhancement New feature or request Help Wanted Extra attention is needed labels Jan 31, 2019
@alexdovzhanyn alexdovzhanyn added the Difficulty: Intermediate This issue can be worked on by someone with a moderate amount of experience with the codebase label Aug 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Difficulty: Intermediate This issue can be worked on by someone with a moderate amount of experience with the codebase Enhancement New feature or request Help Wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant