mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-26 22:15:52 +00:00
Must check sequence before checking fee and signature. Otherwise lots of bad things happen:
1) We needlessly check signatures on applied. 2) We return the wrong error code if a transaction that was already applied has an insufficient fee.
This commit is contained in:
@@ -206,15 +206,15 @@ TER Transactor::apply()
|
||||
mHasAuthKey = mTxnAccount->isFieldPresent(sfRegularKey);
|
||||
}
|
||||
|
||||
terResult = checkSeq();
|
||||
if (terResult != tesSUCCESS) return(terResult);
|
||||
|
||||
terResult = payFee();
|
||||
if (terResult != tesSUCCESS) return(terResult);
|
||||
|
||||
terResult = checkSig();
|
||||
if (terResult != tesSUCCESS) return(terResult);
|
||||
|
||||
terResult = checkSeq();
|
||||
if (terResult != tesSUCCESS) return(terResult);
|
||||
|
||||
mEngine->entryModify(mTxnAccount);
|
||||
|
||||
return doApply();
|
||||
|
||||
Reference in New Issue
Block a user