Title: Node add transactions to pool policy , basic transaction validation rules Post by: bitaps on September 17, 2015, 12:18:54 PM I am trying to collect all infromation about adding and verification transaction into Blockchain.
Could any experts in this question verify that collected information is actual and correct? Thank you Node add transaction to pool policy http://i.stack.imgur.com/a2lOY.png Blockchain transaction validation rules http://i.stack.imgur.com/QvgMr.png Fixed both schemas, thank to yakuza699 and amaclin for help and explanations! Title: Re: Add transactions to rawmempool, add transactions included in block Post by: amaclin on September 17, 2015, 12:38:16 PM Not correct.
For example, you (and anyone) have a right to accept 1-megabyte transactions into a mempool and in block For more information: https://en.bitcoin.it/wiki/Protocol_rules Title: Re: Add transactions to rawmempool, add transactions included in block Post by: bitaps on September 17, 2015, 12:45:54 PM source -> https://bitcoin.org/en/developer-guide#non-standard-transactions
So standard transactions have limit 100,000 bytes For transaction that we add inside blocks no check for isStandard so limit Size in bytes < MAX_BLOCK_SIZE ( 1 megabyte). 1 MB tx is not possible Maximum possible Nonstandart Transaction size is MAX_BLOCK_SIZE - block header info (80 bytes) and this transaction should be coinbase ! Not all information on bitkoin wiki is actual ! This is a reason why we try collect actual rules in one place and then post on bitcoin wiki Title: Re: Add transactions to rawmempool, add transactions included in block Post by: yakuza699 on September 17, 2015, 12:54:44 PM 1MB transaction is VALID but non-standard under 0.9.3 but no one in the world disallows you to change these rules and make your node relay 1MB transactions.For example this is my transaction https://live.blockcypher.com/btc/tx/657b57238c7e442227f30c40e6f7a621eaed66087cace0ff66394c28bcf4162c/ (https://live.blockcypher.com/btc/tx/657b57238c7e442227f30c40e6f7a621eaed66087cace0ff66394c28bcf4162c/) which size is 219KB.
Title: Re: Add transactions to rawmempool, add transactions included in block Post by: bitaps on September 17, 2015, 12:57:57 PM 1 MB tx is not possible!
Maximum possible Non-standart Transaction size is MAX_BLOCK_SIZE (1 MB) - block header info (80 bytes) and this transaction should be coinbase ! And this constraints is correctly described in attached pictures Title: Re: Add transactions to rawmempool, add transactions included in block Post by: yakuza699 on September 17, 2015, 01:01:13 PM 1 MB tx is not possible! You're right but 1MB tx will be possible in the next forks.Maximum possible Non-standart Transaction size is MAX_BLOCK_SIZE (1 MB) - block header info (80 bytes) and this transaction should be coinbase ! And this constraints is correctly described in attached pictures Title: Re: Add transactions to rawmempool, add transactions included in block Post by: bitaps on September 17, 2015, 01:05:00 PM Yes and we use variable MAX_BLOCK_SIZE, this variable at this moment = 1 MB
Title: Re: Add transactions to rawmempool, add transactions included in block Post by: amaclin on September 17, 2015, 01:24:04 PM 1 MB tx is not possible! OK, you are right.999000 bytes is quite good transaction and I will be happy to put it into mempool and confirm into a block (Oups! I am not a miner and even do not have node.) Quote So standard transactions have limit 100,000 bytes Have you said that you want a rules only for standard transactions and bitcoin core client without any patches?Title: Re: Add transactions to rawmempool, add transactions included in block Post by: bitaps on September 17, 2015, 04:30:00 PM We want rules for bitcoin protocol. Many documents that we can see on bitcoin wiki website, is not actual for recent protocol changes. Other source of information is Bitcoin core github repository, but same rules not described in separate documents like BIPs, and information only available inside C++ bitcoin core source files. So we collected all available information in this sources and want verify with community that our implementation of this part of bitcoin prorocol rules is correct.
Title: Re: Add transactions to rawmempool, add transactions included in block Post by: amaclin on September 17, 2015, 04:42:39 PM You should understand the difference between bitcoin protocol and node policy.
Transaction with the size 999000 bytes is valid transaction. But most of nodes do not relay/accept it. Nodes can implement their own policy. For example Eligius pool does not accept transactions to 1JwSSubhmg6iPtRjtyqhUYYH7bZg3Lfy1T My node can reject transactions with the size 18347-19456 bytes. Why not? Quote Many documents that we can see on bitcoin wiki website, is not actual for recent protocol changes No. There are only a couple of changes in consensus code from the very beginningTitle: Re: Add transactions to rawmempool, add transactions included in block Post by: bitaps on September 17, 2015, 07:37:03 PM Standard type of transactions is the Node policy or protocol rules?
Title: Re: Add transactions to rawmempool, add transactions included in block Post by: amaclin on September 17, 2015, 08:00:50 PM Standard type of transactions is the Node policy or protocol rules? node policy of courseTitle: Re: Add transactions to rawmempool, add transactions included in block Post by: yakuza699 on September 17, 2015, 08:05:26 PM Standard type of transactions is the Node policy or protocol rules? What do you mean by standard type?All standard and non-standard tx's as long as they are valid can be included in a block.Protocol rules state which kind of tx's can be included in a block node policy rules state which tx's will be relayed.Node policy rules can only be tighter and not looser.For example under current protocol rules(and tx rules) tx over 1MB is invalid thus block that included this transaction is also invalid.A transaction of over 100KB is not relayed under current node policy but it is perfectly valid and good under protocol rules and it can be included in block.Title: Re: Add transactions to rawmempool, add transactions included in block Post by: bitaps on September 17, 2015, 08:19:45 PM Mempool of unconfirmed transations is this relate to Node policy? Unconfirmed transactions is part of Bitcoin protocol?
Title: Re: Add transactions to rawmempool, add transactions included in block Post by: bitaps on September 18, 2015, 03:19:25 PM Fixed both schemas
Node add transaction to pool policy http://i.stack.imgur.com/ZIxL7.png Blockchain transaction validation rules http://i.stack.imgur.com/82cq7.png Title: Re: Add transactions to rawmempool, add transactions included in block Post by: amaclin on September 18, 2015, 03:57:51 PM Quote Output coins pubkey script must be one of next types: p2pkh, p2sh, pubkey (no more accepted), multisig, null-data What? ;DAre you kidding us? Title: Re: Node add transactions to pool policy , basic transaction validation rules Post by: bitaps on September 18, 2015, 04:28:53 PM Quote Pubkey outputs are a simplified form of the P2PKH pubkey script, but they aren’t as secure as P2PKH, so they generally aren’t used in new transactions anymore. source -> https://bitcoin.org/en/developer-guide#standard-transactions Whats wrong? Title: Re: Node add transactions to pool policy , basic transaction validation rules Post by: amaclin on September 18, 2015, 04:38:17 PM Quote Pubkey outputs are a simplified form of the P2PKH pubkey script, but they aren’t as secure as P2PKH, so they generally aren’t used in new transactions anymore. source -> https://bitcoin.org/en/developer-guide#standard-transactionsWhats wrong? 2) they are used. do not trust bitcoin.org. there are more than 40 mln such transactions proof: http://webbtc.com/scripts/pubkey and several thousands of them were sent last week :) Title: Re: Node add transactions to pool policy , basic transaction validation rules Post by: bitaps on September 18, 2015, 04:56:08 PM fixed Pubkey type -> http://i.stack.imgur.com/a2lOY.png
Added coinbase sig script length constraints -> http://i.stack.imgur.com/QvgMr.png |