Please describe the feature you’d like to see added.
Execute testmempoolaccept
in a way that will ignore the time/block-height validations of the transactions’ nSequence
and nLocktime
.
Is your feature related to a problem, if so please describe it.
testmempoolaccept
is a very useful tool to verify transactions that aren’t supposed to be broadcasted immediately - for example, for emergency recovery in case the seed is lost.
nLocktime
is also useful in such case, to prevent the recovery transaction from being broadcasted too early. However, after signing a transaction with a future nLocktime
, I couldn’t be sure that it is indeed valid: testmempoolaccept
considers this transaction as non-final
because of its future nLocktime
, without explaining whether it has other problems (i.e. invalid signatures etc.).
Describe the solution you’d like
A third optional parameter to testmempoolaccept
(after rawtxs
and maxfeerate
) called ignoretimelocks
, that will be a boolean.
Describe any alternatives you’ve considered
I’ve tried writing code that would parse the transaction and, given the current mempool utxos, verify its scripts. This becomes complicated to implement in multisig and segwit transactions, and doesn’t give me the guarantees that I want for such long-term transaction.
Another suggestion is that testmempoolaccept
will accumulate all the reasons a transaction is unacceptable, and not exit after the first reason.
Please leave any additional context
nSequence
is a bitfield with multiple purposes, like RBF, and possibly other features in the future. My suggestion only regards BIP-68 validations of nSequence
and not other features.