Author

Topic: A different way to create coinbase transaction (Read 153 times)

legendary
Activity: 3472
Merit: 4801
February 15, 2018, 10:35:25 AM
#3
As ranochigo has pointed out, you cant change ANYTHING about a block once the proof-of-work is complete.  If you do, then the block becomes invalid.

More importantly, some of your understanding of the current process is not entirely correct.
AFAIK when a miner succeeds in creating a block, he puts a special transaction (coinbase) in it which spends no input and sends a fixed amount of BTC to an address he can arbitrarily specify.

No.

When a miner (or pool) BUILDS a block, he includes a special transaction (coinbase) which spends no value in the input (but stores arbitrary data in the input) and sends NO MORE THAN the SUM of the block subsidy (currently 21.5 BTC) PLUS all the transaction fees of all the transactions included in the block to one OR MORE outputs he can arbitrarily specify.

THEN the miner (or pool) starts the proof-of-work on that block.  IF they are first to complete the proof-of-work, THEN they get to broadcast their block (which already includes the coinbase transaction).  IF they are NOT first to complete the proof-of-work, THEN they update their blockchain, UTXO, and mempool with the information from the block that they receive, and start the whole proces all over again.

Instead of doing so, can we do the following: Miner simply puts an address in the block header.

There is currently nowhere in the header to store an address.  You'd have to change the format of the header and that would be a HARD FORK.  Getting anyone to agree to a HARD FORK is going to require a VERY GOOD REASON.  What problem are you trying to fix with this?

When he succeeds in creating the block, all nodes that receive this block create the coinbase transaction -which spends no input and sends the fixed amount to the address in header- in their UTXO pool.

All the nodes already add the outputs from the coinbase to their UTXO.
legendary
Activity: 3038
Merit: 4418
Crypto Swap Exchange
That's before the miner succeeds in mining the block. The coinbase and any other transactions are added before the miner hashes the block header and finds a hash matching the target. If you were to change anything within the block, the hash of the block changes completely.

What do you actually achieve by doing that?
newbie
Activity: 9
Merit: 6
AFAIK when a miner succeeds in creating a block, he puts a special transaction (coinbase) in it which spends no input and sends a fixed amount of BTC to an address he can arbitrarily specify.

Instead of doing so, can we do the following: Miner simply puts an address in the block header. When he succeeds in creating the block, all nodes that receive this block create the coinbase transaction -which spends no input and sends the fixed amount to the address in header- in their UTXO pool.

Would that work?
Jump to: