Post
Topic
Board Development & Technical Discussion
Re: As a miner can i decide which block to mine?
by
bob123
on 23/12/2017, 15:03:24 UTC
Transactions can be up to 100kb in size (to be valid according to the network rules).
It's not. Transactions are valid as long as they can fit inside a single block.

No, thats not true.
Transactions are limited to a weight of 400.000. Look it up here:
Defined as constant here: https://github.com/bitcoin/bitcoin/blob/3c098a8aa0780009c11b66b1a5d488a928629ebf/src/policy/policy.h#L24.
And validty-check here: https://github.com/bitcoin/bitcoin/blob/3c098a8aa0780009c11b66b1a5d488a928629ebf/src/net_processing.cpp#L661-L665
Since the weight of a non-segwit transaction is 4 times its size, this leads to a maximum size of 100.000 byte (100kb) for valid transactions.

Note the comment:
Code:
// Ignore big transactions, to avoid a
// send-big-orphans memory exhaustion attack.
(to be found in 2nd link).