2
1
What happens if I broadcast two nLockTime transactions with different nLockTime but same input?
Is the smallest nLockTime going to be accepted or is it the tx that reaches the network the fastest that will be accepted.
2
1
What happens if I broadcast two nLockTime transactions with different nLockTime but same input?
Is the smallest nLockTime going to be accepted or is it the tx that reaches the network the fastest that will be accepted.
4
Background info:
As Nick mentioned, transaction replacement using nLockTime and the sequence numbers isn't currently enabled by the network. In practice, this means that any transactions with an nLockTime in the future and at least one input with non-max sequence number won't be broadcasted because it is not a 'final' transaction.
So, if you:
Essentially, the network 'accepts' the first final (ready for inclusion in a block) transaction spending that input that it sees. There are some proposals to alter this method, such as relay-first-double-spend and replace-by-fee.
0
I don't think transaction replacement is enabled, so it would be the transaction that was accepted first.
Although this is what the standard bitcoin core does, it is not something you can rely on. You have no control over what other people do so you should assume worst case (which probably means there's no point in doing it at all). For example if the transaction contains a high fee it might be worth while for a miner to hold onto it until the (earliest) locktime expires and try to mine it asap. – Jannes – 2015-04-22T07:50:55.243