diff --git a/.config/cspell.config.yaml b/.config/cspell.config.yaml index 969720a11d..bd0eee5f07 100644 --- a/.config/cspell.config.yaml +++ b/.config/cspell.config.yaml @@ -83,7 +83,6 @@ words: - doxyfile - dxrpl - endmacro - - endpointv - exceptioned - Falco - finalizers @@ -92,6 +91,7 @@ words: - funclets - gcov - gcovr + - ghead - Gnutella - gpgcheck - gpgkey @@ -221,6 +221,8 @@ words: - takergets - takerpays - ters + - TMEndpointv2 + - trixie - tx - txid - txids @@ -255,6 +257,7 @@ words: - venv - vfalco - vinnie + - wasmi - wextra - wptr - writeme diff --git a/.gitattributes b/.gitattributes index bdfc989327..7a066d0967 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,5 +1,6 @@ # Set default behaviour, in case users don't have core.autocrlf set. #* text=auto +# cspell: disable # Visual Studio *.sln text eol=crlf diff --git a/.github/scripts/levelization/README.md b/.github/scripts/levelization/README.md index c8954b900e..c3e6ffa4a8 100644 --- a/.github/scripts/levelization/README.md +++ b/.github/scripts/levelization/README.md @@ -84,7 +84,7 @@ It generates many files of [results](results): to the destination module, de-duped, and with frequency counts. - `includes/`: A directory where each file represents a module and contains a list of modules and counts that the module _includes_. -- `includedby/`: Similar to `includes/`, but the other way around. Each +- `included_by/`: Similar to `includes/`, but the other way around. Each file represents a module and contains a list of modules and counts that _include_ the module. - [`loops.txt`](results/loops.txt): A list of direct loops detected diff --git a/.github/scripts/levelization/generate.sh b/.github/scripts/levelization/generate.sh index 775ddf789f..d700c7a206 100755 --- a/.github/scripts/levelization/generate.sh +++ b/.github/scripts/levelization/generate.sh @@ -29,7 +29,7 @@ pushd results oldifs=${IFS} IFS=: mkdir includes -mkdir includedby +mkdir included_by echo Build levelization paths exec 3< ${includes} # open rawincludes.txt for input while read -r -u 3 file include @@ -59,7 +59,7 @@ do echo $level $includelevel | tee -a paths.txt fi done -echo Sort and dedup paths +echo Sort and deduplicate paths sort -ds paths.txt | uniq -c | tee sortedpaths.txt mv sortedpaths.txt paths.txt exec 3>&- #close fd 3 @@ -71,7 +71,7 @@ exec 4&- #close fd 4 diff --git a/.github/scripts/rename/README.md b/.github/scripts/rename/README.md index 8336f23bec..cc004a335f 100644 --- a/.github/scripts/rename/README.md +++ b/.github/scripts/rename/README.md @@ -19,7 +19,7 @@ run from the repository root. 1. `.github/scripts/rename/definitions.sh`: This script will rename all definitions, such as include guards, from `RIPPLE_XXX` and `RIPPLED_XXX` to `XRPL_XXX`. -2. `.github/scripts/rename/copyright.sh`: This script will remove superflous +2. `.github/scripts/rename/copyright.sh`: This script will remove superfluous copyright notices. 3. `.github/scripts/rename/cmake.sh`: This script will rename all CMake files from `RippleXXX.cmake` or `RippledXXX.cmake` to `XrplXXX.cmake`, and any diff --git a/.github/scripts/rename/config.sh b/.github/scripts/rename/config.sh index 7f36e8fd21..f6e914f502 100755 --- a/.github/scripts/rename/config.sh +++ b/.github/scripts/rename/config.sh @@ -56,7 +56,7 @@ for DIRECTORY in "${DIRECTORIES[@]}"; do done ${SED_COMMAND} -i 's/rippled/xrpld/g' cfg/xrpld-example.cfg ${SED_COMMAND} -i 's/rippled/xrpld/g' src/test/core/Config_test.cpp -${SED_COMMAND} -i 's/ripplevalidators/xrplvalidators/g' src/test/core/Config_test.cpp +${SED_COMMAND} -i 's/ripplevalidators/xrplvalidators/g' src/test/core/Config_test.cpp # cspell: disable-line ${SED_COMMAND} -i 's/rippleConfig/xrpldConfig/g' src/test/core/Config_test.cpp ${SED_COMMAND} -i 's@ripple/@xrpld/@g' src/test/core/Config_test.cpp ${SED_COMMAND} -i 's/Rippled/File/g' src/test/core/Config_test.cpp diff --git a/.github/scripts/rename/copyright.sh b/.github/scripts/rename/copyright.sh index 41dbdc1f94..c5a9fb2cd3 100755 --- a/.github/scripts/rename/copyright.sh +++ b/.github/scripts/rename/copyright.sh @@ -50,11 +50,11 @@ for DIRECTORY in "${DIRECTORIES[@]}"; do # Handle the cases where the copyright notice is enclosed in /* ... */ # and usually surrounded by //---- and //======. ${SED_COMMAND} -z -i -E 's@^//-------+\n+@@' "${FILE}" - ${SED_COMMAND} -z -i -E 's@^.*Copyright.+(Ripple|Bougalis|Falco|Hinnant|Null|Ritchford|XRPLF).+PERFORMANCE OF THIS SOFTWARE\.\n\*/\n+@@' "${FILE}" + ${SED_COMMAND} -z -i -E 's@^.*Copyright.+(Ripple|Bougalis|Falco|Hinnant|Null|Ritchford|XRPLF).+PERFORMANCE OF THIS SOFTWARE\.\n\*/\n+@@' "${FILE}" # cspell: ignore Bougalis Falco Hinnant Ritchford ${SED_COMMAND} -z -i -E 's@^//=======+\n+@@' "${FILE}" # Handle the cases where the copyright notice is commented out with //. - ${SED_COMMAND} -z -i -E 's@^//\n// Copyright.+Falco \(vinnie dot falco at gmail dot com\)\n//\n+@@' "${FILE}" + ${SED_COMMAND} -z -i -E 's@^//\n// Copyright.+Falco \(vinnie dot falco at gmail dot com\)\n//\n+@@' "${FILE}" # cspell: ignore Vinnie Falco done done @@ -83,16 +83,16 @@ if ! grep -q 'Dev Null' src/xrpld/rpc/handlers/ValidatorInfo.cpp; then echo -e "// Copyright (c) 2019 Dev Null Productions\n\n$(cat src/xrpld/rpc/handlers/ValidatorInfo.cpp)" > src/xrpld/rpc/handlers/ValidatorInfo.cpp fi if ! grep -q 'Bougalis' include/xrpl/basics/SlabAllocator.h; then - echo -e "// Copyright (c) 2022, Nikolaos D. Bougalis \n\n$(cat include/xrpl/basics/SlabAllocator.h)" > include/xrpl/basics/SlabAllocator.h + echo -e "// Copyright (c) 2022, Nikolaos D. Bougalis \n\n$(cat include/xrpl/basics/SlabAllocator.h)" > include/xrpl/basics/SlabAllocator.h # cspell: ignore Nikolaos Bougalis nikb fi if ! grep -q 'Bougalis' include/xrpl/basics/spinlock.h; then - echo -e "// Copyright (c) 2022, Nikolaos D. Bougalis \n\n$(cat include/xrpl/basics/spinlock.h)" > include/xrpl/basics/spinlock.h + echo -e "// Copyright (c) 2022, Nikolaos D. Bougalis \n\n$(cat include/xrpl/basics/spinlock.h)" > include/xrpl/basics/spinlock.h # cspell: ignore Nikolaos Bougalis nikb fi if ! grep -q 'Bougalis' include/xrpl/basics/tagged_integer.h; then - echo -e "// Copyright (c) 2014, Nikolaos D. Bougalis \n\n$(cat include/xrpl/basics/tagged_integer.h)" > include/xrpl/basics/tagged_integer.h + echo -e "// Copyright (c) 2014, Nikolaos D. Bougalis \n\n$(cat include/xrpl/basics/tagged_integer.h)" > include/xrpl/basics/tagged_integer.h # cspell: ignore Nikolaos Bougalis nikb fi if ! grep -q 'Ritchford' include/xrpl/beast/utility/Zero.h; then - echo -e "// Copyright (c) 2014, Tom Ritchford \n\n$(cat include/xrpl/beast/utility/Zero.h)" > include/xrpl/beast/utility/Zero.h + echo -e "// Copyright (c) 2014, Tom Ritchford \n\n$(cat include/xrpl/beast/utility/Zero.h)" > include/xrpl/beast/utility/Zero.h # cspell: ignore Ritchford fi # Restore newlines and tabs in string literals in the affected file. diff --git a/.gitignore b/.gitignore index c4e81408bb..b899cf8436 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ # .gitignore +# cspell: disable # Macintosh Desktop Services Store files. .DS_Store diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 4a1dc159dc..00bec32ed6 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -36,20 +36,20 @@ repos: hooks: - id: black - # - repo: https://github.com/streetsidesoftware/cspell-cli - # rev: v9.2.0 - # hooks: - # - id: cspell # Spell check changed files - # - id: cspell # Spell check the commit message - # name: check commit message spelling - # args: - # - --no-must-find-files - # - --no-progress - # - --no-summary - # - --files - # - .git/COMMIT_EDITMSG - # stages: [commit-msg] - # always_run: true # This might not be necessary. + - repo: https://github.com/streetsidesoftware/cspell-cli + rev: v9.2.0 + hooks: + - id: cspell # Spell check changed files + exclude: .config/cspell.config.yaml + - id: cspell # Spell check the commit message + name: check commit message spelling + args: + - --no-must-find-files + - --no-progress + - --no-summary + - --files + - .git/COMMIT_EDITMSG + stages: [commit-msg] exclude: | (?x)^( diff --git a/clang_format.sh b/clang_format.sh index f9aeb0af66..2d834b515d 100755 --- a/clang_format.sh +++ b/clang_format.sh @@ -1,4 +1,5 @@ #!/bin/bash +# cspell: ignore clangf modified=$1 dir=`pwd` clangf=clang-format-10 diff --git a/include/xrpl/proto/xrpl.proto b/include/xrpl/proto/xrpl.proto index f93ebbc72c..613ef70a1f 100644 --- a/include/xrpl/proto/xrpl.proto +++ b/include/xrpl/proto/xrpl.proto @@ -17,9 +17,9 @@ enum MessageType { mtHAVE_SET = 35; mtVALIDATION = 41; mtGET_OBJECTS = 42; - mtVALIDATORLIST = 54; + mtVALIDATOR_LIST = 54; mtSQUELCH = 55; - mtVALIDATORLISTCOLLECTION = 56; + mtVALIDATOR_LIST_COLLECTION = 56; mtPROOF_PATH_REQ = 57; mtPROOF_PATH_RESPONSE = 58; mtREPLAY_DELTA_REQ = 59; @@ -308,7 +308,7 @@ message TMSquelch { } enum TMLedgerMapType { - lmTRANASCTION = 1; // transaction map + lmTRANSACTION = 1; // transaction map lmACCOUNT_STATE = 2; // account state map } diff --git a/include/xrpl/protocol/HashPrefix.h b/include/xrpl/protocol/HashPrefix.h index 77529e9212..39e03bf94f 100644 --- a/include/xrpl/protocol/HashPrefix.h +++ b/include/xrpl/protocol/HashPrefix.h @@ -67,9 +67,6 @@ enum class HashPrefix : std::uint32_t { /** Payment Channel Claim */ paymentChannelClaim = detail::make_hash_prefix('C', 'L', 'M'), - /** Credentials signature */ - credential = detail::make_hash_prefix('C', 'R', 'D'), - /** Batch */ batch = detail::make_hash_prefix('B', 'C', 'H'), }; diff --git a/include/xrpl/protocol/Permissions.h b/include/xrpl/protocol/Permissions.h index 319aeb1c28..74f539a3bf 100644 --- a/include/xrpl/protocol/Permissions.h +++ b/include/xrpl/protocol/Permissions.h @@ -29,7 +29,7 @@ enum GranularPermissionType : std::uint32_t { #pragma pop_macro("PERMISSION") }; -enum Delegation { delegatable, notDelegatable }; +enum Delegation { delegable, notDelegable }; class Permission { diff --git a/include/xrpl/protocol/detail/transactions.macro b/include/xrpl/protocol/detail/transactions.macro index 6d2d833440..bc7eefedb5 100644 --- a/include/xrpl/protocol/detail/transactions.macro +++ b/include/xrpl/protocol/detail/transactions.macro @@ -3,7 +3,7 @@ #endif /** - * TRANSACTION(tag, value, name, delegatable, amendments, privileges, fields) + * TRANSACTION(tag, value, name, delegable, amendments, privileges, fields) * * To ease maintenance, you may replace any unneeded values with "..." * e.g. #define TRANSACTION(tag, value, name, ...) @@ -25,7 +25,7 @@ # include #endif TRANSACTION(ttPAYMENT, 0, Payment, - Delegation::delegatable, + Delegation::delegable, uint256{}, createAcct, ({ @@ -45,7 +45,7 @@ TRANSACTION(ttPAYMENT, 0, Payment, # include #endif TRANSACTION(ttESCROW_CREATE, 1, EscrowCreate, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -59,7 +59,7 @@ TRANSACTION(ttESCROW_CREATE, 1, EscrowCreate, /** This transaction type completes an existing escrow. */ TRANSACTION(ttESCROW_FINISH, 2, EscrowFinish, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -76,7 +76,7 @@ TRANSACTION(ttESCROW_FINISH, 2, EscrowFinish, # include #endif TRANSACTION(ttACCOUNT_SET, 3, AccountSet, - Delegation::notDelegatable, + Delegation::notDelegable, uint256{}, noPriv, ({ @@ -97,7 +97,7 @@ TRANSACTION(ttACCOUNT_SET, 3, AccountSet, # include #endif TRANSACTION(ttESCROW_CANCEL, 4, EscrowCancel, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -110,7 +110,7 @@ TRANSACTION(ttESCROW_CANCEL, 4, EscrowCancel, # include #endif TRANSACTION(ttREGULAR_KEY_SET, 5, SetRegularKey, - Delegation::notDelegatable, + Delegation::notDelegable, uint256{}, noPriv, ({ @@ -124,7 +124,7 @@ TRANSACTION(ttREGULAR_KEY_SET, 5, SetRegularKey, # include #endif TRANSACTION(ttOFFER_CREATE, 7, OfferCreate, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -140,7 +140,7 @@ TRANSACTION(ttOFFER_CREATE, 7, OfferCreate, # include #endif TRANSACTION(ttOFFER_CANCEL, 8, OfferCancel, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -154,7 +154,7 @@ TRANSACTION(ttOFFER_CANCEL, 8, OfferCancel, # include #endif TRANSACTION(ttTICKET_CREATE, 10, TicketCreate, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -170,7 +170,7 @@ TRANSACTION(ttTICKET_CREATE, 10, TicketCreate, # include #endif TRANSACTION(ttSIGNER_LIST_SET, 12, SignerListSet, - Delegation::notDelegatable, + Delegation::notDelegable, uint256{}, noPriv, ({ @@ -183,7 +183,7 @@ TRANSACTION(ttSIGNER_LIST_SET, 12, SignerListSet, # include #endif TRANSACTION(ttPAYCHAN_CREATE, 13, PaymentChannelCreate, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -197,7 +197,7 @@ TRANSACTION(ttPAYCHAN_CREATE, 13, PaymentChannelCreate, /** This transaction type funds an existing unidirectional XRP payment channel. */ TRANSACTION(ttPAYCHAN_FUND, 14, PaymentChannelFund, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -208,7 +208,7 @@ TRANSACTION(ttPAYCHAN_FUND, 14, PaymentChannelFund, /** This transaction type submits a claim against an existing unidirectional payment channel. */ TRANSACTION(ttPAYCHAN_CLAIM, 15, PaymentChannelClaim, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -225,7 +225,7 @@ TRANSACTION(ttPAYCHAN_CLAIM, 15, PaymentChannelClaim, # include #endif TRANSACTION(ttCHECK_CREATE, 16, CheckCreate, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -241,7 +241,7 @@ TRANSACTION(ttCHECK_CREATE, 16, CheckCreate, # include #endif TRANSACTION(ttCHECK_CASH, 17, CheckCash, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -255,7 +255,7 @@ TRANSACTION(ttCHECK_CASH, 17, CheckCash, # include #endif TRANSACTION(ttCHECK_CANCEL, 18, CheckCancel, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -267,7 +267,7 @@ TRANSACTION(ttCHECK_CANCEL, 18, CheckCancel, # include #endif TRANSACTION(ttDEPOSIT_PREAUTH, 19, DepositPreauth, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -282,7 +282,7 @@ TRANSACTION(ttDEPOSIT_PREAUTH, 19, DepositPreauth, # include #endif TRANSACTION(ttTRUST_SET, 20, TrustSet, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -296,7 +296,7 @@ TRANSACTION(ttTRUST_SET, 20, TrustSet, # include #endif TRANSACTION(ttACCOUNT_DELETE, 21, AccountDelete, - Delegation::notDelegatable, + Delegation::notDelegable, uint256{}, mustDeleteAcct, ({ @@ -312,7 +312,7 @@ TRANSACTION(ttACCOUNT_DELETE, 21, AccountDelete, # include #endif TRANSACTION(ttNFTOKEN_MINT, 25, NFTokenMint, - Delegation::delegatable, + Delegation::delegable, uint256{}, changeNFTCounts, ({ @@ -330,7 +330,7 @@ TRANSACTION(ttNFTOKEN_MINT, 25, NFTokenMint, # include #endif TRANSACTION(ttNFTOKEN_BURN, 26, NFTokenBurn, - Delegation::delegatable, + Delegation::delegable, uint256{}, changeNFTCounts, ({ @@ -343,7 +343,7 @@ TRANSACTION(ttNFTOKEN_BURN, 26, NFTokenBurn, # include #endif TRANSACTION(ttNFTOKEN_CREATE_OFFER, 27, NFTokenCreateOffer, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -359,7 +359,7 @@ TRANSACTION(ttNFTOKEN_CREATE_OFFER, 27, NFTokenCreateOffer, # include #endif TRANSACTION(ttNFTOKEN_CANCEL_OFFER, 28, NFTokenCancelOffer, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -371,7 +371,7 @@ TRANSACTION(ttNFTOKEN_CANCEL_OFFER, 28, NFTokenCancelOffer, # include #endif TRANSACTION(ttNFTOKEN_ACCEPT_OFFER, 29, NFTokenAcceptOffer, - Delegation::delegatable, + Delegation::delegable, uint256{}, noPriv, ({ @@ -385,7 +385,7 @@ TRANSACTION(ttNFTOKEN_ACCEPT_OFFER, 29, NFTokenAcceptOffer, # include #endif TRANSACTION(ttCLAWBACK, 30, Clawback, - Delegation::delegatable, + Delegation::delegable, featureClawback, noPriv, ({ @@ -398,7 +398,7 @@ TRANSACTION(ttCLAWBACK, 30, Clawback, # include #endif TRANSACTION(ttAMM_CLAWBACK, 31, AMMClawback, - Delegation::delegatable, + Delegation::delegable, featureAMMClawback, mayDeleteAcct | overrideFreeze, ({ @@ -413,7 +413,7 @@ TRANSACTION(ttAMM_CLAWBACK, 31, AMMClawback, # include #endif TRANSACTION(ttAMM_CREATE, 35, AMMCreate, - Delegation::delegatable, + Delegation::delegable, featureAMM, createPseudoAcct, ({ @@ -427,7 +427,7 @@ TRANSACTION(ttAMM_CREATE, 35, AMMCreate, # include #endif TRANSACTION(ttAMM_DEPOSIT, 36, AMMDeposit, - Delegation::delegatable, + Delegation::delegable, featureAMM, noPriv, ({ @@ -445,7 +445,7 @@ TRANSACTION(ttAMM_DEPOSIT, 36, AMMDeposit, # include #endif TRANSACTION(ttAMM_WITHDRAW, 37, AMMWithdraw, - Delegation::delegatable, + Delegation::delegable, featureAMM, mayDeleteAcct, ({ @@ -462,7 +462,7 @@ TRANSACTION(ttAMM_WITHDRAW, 37, AMMWithdraw, # include #endif TRANSACTION(ttAMM_VOTE, 38, AMMVote, - Delegation::delegatable, + Delegation::delegable, featureAMM, noPriv, ({ @@ -476,7 +476,7 @@ TRANSACTION(ttAMM_VOTE, 38, AMMVote, # include #endif TRANSACTION(ttAMM_BID, 39, AMMBid, - Delegation::delegatable, + Delegation::delegable, featureAMM, noPriv, ({ @@ -492,7 +492,7 @@ TRANSACTION(ttAMM_BID, 39, AMMBid, # include #endif TRANSACTION(ttAMM_DELETE, 40, AMMDelete, - Delegation::delegatable, + Delegation::delegable, featureAMM, mustDeleteAcct, ({ @@ -505,7 +505,7 @@ TRANSACTION(ttAMM_DELETE, 40, AMMDelete, # include #endif TRANSACTION(ttXCHAIN_CREATE_CLAIM_ID, 41, XChainCreateClaimID, - Delegation::delegatable, + Delegation::delegable, featureXChainBridge, noPriv, ({ @@ -516,7 +516,7 @@ TRANSACTION(ttXCHAIN_CREATE_CLAIM_ID, 41, XChainCreateClaimID, /** This transactions initiates a crosschain transaction */ TRANSACTION(ttXCHAIN_COMMIT, 42, XChainCommit, - Delegation::delegatable, + Delegation::delegable, featureXChainBridge, noPriv, ({ @@ -528,7 +528,7 @@ TRANSACTION(ttXCHAIN_COMMIT, 42, XChainCommit, /** This transaction completes a crosschain transaction */ TRANSACTION(ttXCHAIN_CLAIM, 43, XChainClaim, - Delegation::delegatable, + Delegation::delegable, featureXChainBridge, noPriv, ({ @@ -541,7 +541,7 @@ TRANSACTION(ttXCHAIN_CLAIM, 43, XChainClaim, /** This transaction initiates a crosschain account create transaction */ TRANSACTION(ttXCHAIN_ACCOUNT_CREATE_COMMIT, 44, XChainAccountCreateCommit, - Delegation::delegatable, + Delegation::delegable, featureXChainBridge, noPriv, ({ @@ -553,7 +553,7 @@ TRANSACTION(ttXCHAIN_ACCOUNT_CREATE_COMMIT, 44, XChainAccountCreateCommit, /** This transaction adds an attestation to a claim */ TRANSACTION(ttXCHAIN_ADD_CLAIM_ATTESTATION, 45, XChainAddClaimAttestation, - Delegation::delegatable, + Delegation::delegable, featureXChainBridge, createAcct, ({ @@ -574,7 +574,7 @@ TRANSACTION(ttXCHAIN_ADD_CLAIM_ATTESTATION, 45, XChainAddClaimAttestation, /** This transaction adds an attestation to an account */ TRANSACTION(ttXCHAIN_ADD_ACCOUNT_CREATE_ATTESTATION, 46, XChainAddAccountCreateAttestation, - Delegation::delegatable, + Delegation::delegable, featureXChainBridge, createAcct, ({ @@ -595,7 +595,7 @@ TRANSACTION(ttXCHAIN_ADD_ACCOUNT_CREATE_ATTESTATION, 46, /** This transaction modifies a sidechain */ TRANSACTION(ttXCHAIN_MODIFY_BRIDGE, 47, XChainModifyBridge, - Delegation::delegatable, + Delegation::delegable, featureXChainBridge, noPriv, ({ @@ -606,7 +606,7 @@ TRANSACTION(ttXCHAIN_MODIFY_BRIDGE, 47, XChainModifyBridge, /** This transactions creates a sidechain */ TRANSACTION(ttXCHAIN_CREATE_BRIDGE, 48, XChainCreateBridge, - Delegation::delegatable, + Delegation::delegable, featureXChainBridge, noPriv, ({ @@ -620,7 +620,7 @@ TRANSACTION(ttXCHAIN_CREATE_BRIDGE, 48, XChainCreateBridge, # include #endif TRANSACTION(ttDID_SET, 49, DIDSet, - Delegation::delegatable, + Delegation::delegable, featureDID, noPriv, ({ @@ -631,7 +631,7 @@ TRANSACTION(ttDID_SET, 49, DIDSet, /** This transaction type deletes a DID */ TRANSACTION(ttDID_DELETE, 50, DIDDelete, - Delegation::delegatable, + Delegation::delegable, featureDID, noPriv, ({})) @@ -641,7 +641,7 @@ TRANSACTION(ttDID_DELETE, 50, DIDDelete, # include #endif TRANSACTION(ttORACLE_SET, 51, OracleSet, - Delegation::delegatable, + Delegation::delegable, featurePriceOracle, noPriv, ({ @@ -658,7 +658,7 @@ TRANSACTION(ttORACLE_SET, 51, OracleSet, # include #endif TRANSACTION(ttORACLE_DELETE, 52, OracleDelete, - Delegation::delegatable, + Delegation::delegable, featurePriceOracle, noPriv, ({ @@ -670,7 +670,7 @@ TRANSACTION(ttORACLE_DELETE, 52, OracleDelete, # include #endif TRANSACTION(ttLEDGER_STATE_FIX, 53, LedgerStateFix, - Delegation::delegatable, + Delegation::delegable, fixNFTokenPageLinks, noPriv, ({ @@ -683,7 +683,7 @@ TRANSACTION(ttLEDGER_STATE_FIX, 53, LedgerStateFix, # include #endif TRANSACTION(ttMPTOKEN_ISSUANCE_CREATE, 54, MPTokenIssuanceCreate, - Delegation::delegatable, + Delegation::delegable, featureMPTokensV1, createMPTIssuance, ({ @@ -700,7 +700,7 @@ TRANSACTION(ttMPTOKEN_ISSUANCE_CREATE, 54, MPTokenIssuanceCreate, # include #endif TRANSACTION(ttMPTOKEN_ISSUANCE_DESTROY, 55, MPTokenIssuanceDestroy, - Delegation::delegatable, + Delegation::delegable, featureMPTokensV1, destroyMPTIssuance, ({ @@ -712,7 +712,7 @@ TRANSACTION(ttMPTOKEN_ISSUANCE_DESTROY, 55, MPTokenIssuanceDestroy, # include #endif TRANSACTION(ttMPTOKEN_ISSUANCE_SET, 56, MPTokenIssuanceSet, - Delegation::delegatable, + Delegation::delegable, featureMPTokensV1, noPriv, ({ @@ -729,7 +729,7 @@ TRANSACTION(ttMPTOKEN_ISSUANCE_SET, 56, MPTokenIssuanceSet, # include #endif TRANSACTION(ttMPTOKEN_AUTHORIZE, 57, MPTokenAuthorize, - Delegation::delegatable, + Delegation::delegable, featureMPTokensV1, mustAuthorizeMPT, ({ @@ -742,7 +742,7 @@ TRANSACTION(ttMPTOKEN_AUTHORIZE, 57, MPTokenAuthorize, # include #endif TRANSACTION(ttCREDENTIAL_CREATE, 58, CredentialCreate, - Delegation::delegatable, + Delegation::delegable, featureCredentials, noPriv, ({ @@ -754,7 +754,7 @@ TRANSACTION(ttCREDENTIAL_CREATE, 58, CredentialCreate, /** This transaction type accept an Credential object */ TRANSACTION(ttCREDENTIAL_ACCEPT, 59, CredentialAccept, - Delegation::delegatable, + Delegation::delegable, featureCredentials, noPriv, ({ @@ -764,7 +764,7 @@ TRANSACTION(ttCREDENTIAL_ACCEPT, 59, CredentialAccept, /** This transaction type delete an Credential object */ TRANSACTION(ttCREDENTIAL_DELETE, 60, CredentialDelete, - Delegation::delegatable, + Delegation::delegable, featureCredentials, noPriv, ({ @@ -778,7 +778,7 @@ TRANSACTION(ttCREDENTIAL_DELETE, 60, CredentialDelete, # include #endif TRANSACTION(ttNFTOKEN_MODIFY, 61, NFTokenModify, - Delegation::delegatable, + Delegation::delegable, featureDynamicNFT, noPriv, ({ @@ -792,7 +792,7 @@ TRANSACTION(ttNFTOKEN_MODIFY, 61, NFTokenModify, # include #endif TRANSACTION(ttPERMISSIONED_DOMAIN_SET, 62, PermissionedDomainSet, - Delegation::delegatable, + Delegation::delegable, featurePermissionedDomains, noPriv, ({ @@ -805,7 +805,7 @@ TRANSACTION(ttPERMISSIONED_DOMAIN_SET, 62, PermissionedDomainSet, # include #endif TRANSACTION(ttPERMISSIONED_DOMAIN_DELETE, 63, PermissionedDomainDelete, - Delegation::delegatable, + Delegation::delegable, featurePermissionedDomains, noPriv, ({ @@ -817,7 +817,7 @@ TRANSACTION(ttPERMISSIONED_DOMAIN_DELETE, 63, PermissionedDomainDelete, # include #endif TRANSACTION(ttDELEGATE_SET, 64, DelegateSet, - Delegation::notDelegatable, + Delegation::notDelegable, featurePermissionDelegationV1_1, noPriv, ({ @@ -830,7 +830,7 @@ TRANSACTION(ttDELEGATE_SET, 64, DelegateSet, # include #endif TRANSACTION(ttVAULT_CREATE, 65, VaultCreate, - Delegation::delegatable, + Delegation::delegable, featureSingleAssetVault, createPseudoAcct | createMPTIssuance | mustModifyVault, ({ @@ -848,7 +848,7 @@ TRANSACTION(ttVAULT_CREATE, 65, VaultCreate, # include #endif TRANSACTION(ttVAULT_SET, 66, VaultSet, - Delegation::delegatable, + Delegation::delegable, featureSingleAssetVault, mustModifyVault, ({ @@ -863,7 +863,7 @@ TRANSACTION(ttVAULT_SET, 66, VaultSet, # include #endif TRANSACTION(ttVAULT_DELETE, 67, VaultDelete, - Delegation::delegatable, + Delegation::delegable, featureSingleAssetVault, mustDeleteAcct | destroyMPTIssuance | mustModifyVault, ({ @@ -875,7 +875,7 @@ TRANSACTION(ttVAULT_DELETE, 67, VaultDelete, # include #endif TRANSACTION(ttVAULT_DEPOSIT, 68, VaultDeposit, - Delegation::delegatable, + Delegation::delegable, featureSingleAssetVault, mayAuthorizeMPT | mustModifyVault, ({ @@ -888,7 +888,7 @@ TRANSACTION(ttVAULT_DEPOSIT, 68, VaultDeposit, # include #endif TRANSACTION(ttVAULT_WITHDRAW, 69, VaultWithdraw, - Delegation::delegatable, + Delegation::delegable, featureSingleAssetVault, mayDeleteMPT | mayAuthorizeMPT | mustModifyVault, ({ @@ -903,7 +903,7 @@ TRANSACTION(ttVAULT_WITHDRAW, 69, VaultWithdraw, # include #endif TRANSACTION(ttVAULT_CLAWBACK, 70, VaultClawback, - Delegation::delegatable, + Delegation::delegable, featureSingleAssetVault, mayDeleteMPT | mustModifyVault, ({ @@ -917,7 +917,7 @@ TRANSACTION(ttVAULT_CLAWBACK, 70, VaultClawback, # include #endif TRANSACTION(ttBATCH, 71, Batch, - Delegation::notDelegatable, + Delegation::notDelegable, featureBatch, noPriv, ({ @@ -932,7 +932,7 @@ TRANSACTION(ttBATCH, 71, Batch, # include #endif TRANSACTION(ttLOAN_BROKER_SET, 74, LoanBrokerSet, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, createPseudoAcct | mayAuthorizeMPT, ({ {sfVaultID, soeREQUIRED}, @@ -949,7 +949,7 @@ TRANSACTION(ttLOAN_BROKER_SET, 74, LoanBrokerSet, # include #endif TRANSACTION(ttLOAN_BROKER_DELETE, 75, LoanBrokerDelete, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, mustDeleteAcct | mayAuthorizeMPT, ({ {sfLoanBrokerID, soeREQUIRED}, @@ -960,7 +960,7 @@ TRANSACTION(ttLOAN_BROKER_DELETE, 75, LoanBrokerDelete, # include #endif TRANSACTION(ttLOAN_BROKER_COVER_DEPOSIT, 76, LoanBrokerCoverDeposit, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, noPriv, ({ {sfLoanBrokerID, soeREQUIRED}, @@ -972,7 +972,7 @@ TRANSACTION(ttLOAN_BROKER_COVER_DEPOSIT, 76, LoanBrokerCoverDeposit, # include #endif TRANSACTION(ttLOAN_BROKER_COVER_WITHDRAW, 77, LoanBrokerCoverWithdraw, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, mayAuthorizeMPT, ({ {sfLoanBrokerID, soeREQUIRED}, @@ -987,7 +987,7 @@ TRANSACTION(ttLOAN_BROKER_COVER_WITHDRAW, 77, LoanBrokerCoverWithdraw, # include #endif TRANSACTION(ttLOAN_BROKER_COVER_CLAWBACK, 78, LoanBrokerCoverClawback, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, noPriv, ({ {sfLoanBrokerID, soeOPTIONAL}, @@ -999,7 +999,7 @@ TRANSACTION(ttLOAN_BROKER_COVER_CLAWBACK, 78, LoanBrokerCoverClawback, # include #endif TRANSACTION(ttLOAN_SET, 80, LoanSet, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, mayAuthorizeMPT | mustModifyVault, ({ {sfLoanBrokerID, soeREQUIRED}, @@ -1026,7 +1026,7 @@ TRANSACTION(ttLOAN_SET, 80, LoanSet, # include #endif TRANSACTION(ttLOAN_DELETE, 81, LoanDelete, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, noPriv, ({ {sfLoanID, soeREQUIRED}, @@ -1037,7 +1037,7 @@ TRANSACTION(ttLOAN_DELETE, 81, LoanDelete, # include #endif TRANSACTION(ttLOAN_MANAGE, 82, LoanManage, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, // All of the LoanManage options will modify the vault, but the // transaction can succeed without options, essentially making it @@ -1051,7 +1051,7 @@ TRANSACTION(ttLOAN_MANAGE, 82, LoanManage, # include #endif TRANSACTION(ttLOAN_PAY, 84, LoanPay, - Delegation::delegatable, + Delegation::delegable, featureLendingProtocol, mayAuthorizeMPT | mustModifyVault, ({ {sfLoanID, soeREQUIRED}, @@ -1066,7 +1066,7 @@ TRANSACTION(ttLOAN_PAY, 84, LoanPay, # include #endif TRANSACTION(ttAMENDMENT, 100, EnableAmendment, - Delegation::notDelegatable, + Delegation::notDelegable, uint256{}, noPriv, ({ @@ -1078,7 +1078,7 @@ TRANSACTION(ttAMENDMENT, 100, EnableAmendment, For details, see: https://xrpl.org/fee-voting.html */ TRANSACTION(ttFEE, 101, SetFee, - Delegation::notDelegatable, + Delegation::notDelegable, uint256{}, noPriv, ({ @@ -1099,7 +1099,7 @@ TRANSACTION(ttFEE, 101, SetFee, For details, see: https://xrpl.org/negative-unl.html */ TRANSACTION(ttUNL_MODIFY, 102, UNLModify, - Delegation::notDelegatable, + Delegation::notDelegable, uint256{}, noPriv, ({ diff --git a/src/libxrpl/protocol/Permissions.cpp b/src/libxrpl/protocol/Permissions.cpp index 55b273e246..082a1792a4 100644 --- a/src/libxrpl/protocol/Permissions.cpp +++ b/src/libxrpl/protocol/Permissions.cpp @@ -11,7 +11,7 @@ Permission::Permission() #pragma push_macro("TRANSACTION") #undef TRANSACTION -#define TRANSACTION(tag, value, name, delegatable, amendment, ...) \ +#define TRANSACTION(tag, value, name, delegable, amendment, ...) \ {value, amendment}, #include @@ -24,7 +24,7 @@ Permission::Permission() #pragma push_macro("TRANSACTION") #undef TRANSACTION -#define TRANSACTION(tag, value, name, delegatable, ...) {value, delegatable}, +#define TRANSACTION(tag, value, name, delegable, ...) {value, delegable}, #include @@ -170,7 +170,7 @@ Permission::isDelegable( !rules.enabled(txFeaturesIt->second)) return false; - if (it->second == Delegation::notDelegatable) + if (it->second == Delegation::notDelegable) return false; return true; diff --git a/src/test/app/Batch_test.cpp b/src/test/app/Batch_test.cpp index 06cf5dee0c..6fbec52a93 100644 --- a/src/test/app/Batch_test.cpp +++ b/src/test/app/Batch_test.cpp @@ -402,6 +402,38 @@ class Batch_test : public beast::unit_test::suite env.close(); } + // temBAD_FEE: Inner txn with negative fee + { + auto const seq = env.seq(alice); + auto const batchFee = batch::calcBatchFee(env, 0, 2); + auto tx1 = batch::inner(pay(alice, bob, XRP(1)), seq + 1); + tx1[jss::Fee] = "-1"; + env(batch::outer(alice, seq, batchFee, tfAllOrNothing), + tx1, + batch::inner(pay(alice, bob, XRP(2)), seq + 2), + ter(temBAD_FEE)); + env.close(); + } + + // temBAD_FEE: Inner txn with non-integer fee + { + auto const seq = env.seq(alice); + auto const batchFee = batch::calcBatchFee(env, 0, 2); + auto tx1 = batch::inner(pay(alice, bob, XRP(1)), seq + 1); + tx1[jss::Fee] = "1.5"; + try + { + env(batch::outer(alice, seq, batchFee, tfAllOrNothing), + tx1, + batch::inner(pay(alice, bob, XRP(2)), seq + 2)); + fail("Expected parse_error for fractional fee"); + } + catch (jtx::parse_error const&) + { + BEAST_EXPECT(true); + } + } + // temSEQ_AND_TICKET: Batch: inner txn cannot have both Sequence // and TicketSequence. { diff --git a/src/test/app/ValidatorList_test.cpp b/src/test/app/ValidatorList_test.cpp index 163e4f632c..fa3c836cca 100644 --- a/src/test/app/ValidatorList_test.cpp +++ b/src/test/app/ValidatorList_test.cpp @@ -2370,7 +2370,8 @@ private: &extractHeader](Message& message) { auto [header, buffers] = extractHeader(message); if (BEAST_EXPECT(header) && - BEAST_EXPECT(header->message_type == protocol::mtVALIDATORLIST)) + BEAST_EXPECT( + header->message_type == protocol::mtVALIDATOR_LIST)) { auto const msg = detail::parseMessageContent( @@ -2386,7 +2387,7 @@ private: if (BEAST_EXPECT(header) && BEAST_EXPECT( header->message_type == - protocol::mtVALIDATORLISTCOLLECTION)) + protocol::mtVALIDATOR_LIST_COLLECTION)) { auto const msg = detail::parseMessageContent< protocol::TMValidatorListCollection>( diff --git a/src/test/overlay/compression_test.cpp b/src/test/overlay/compression_test.cpp index 2be69a74c9..f2fe07cb33 100644 --- a/src/test/overlay/compression_test.cpp +++ b/src/test/overlay/compression_test.cpp @@ -436,12 +436,12 @@ public: // 895B doTest( buildValidatorList(), - protocol::mtVALIDATORLIST, + protocol::mtVALIDATOR_LIST, 4, "TMValidatorList"); doTest( buildValidatorListCollection(), - protocol::mtVALIDATORLISTCOLLECTION, + protocol::mtVALIDATOR_LIST_COLLECTION, 4, "TMValidatorListCollection"); } diff --git a/src/xrpld/app/ledger/detail/LedgerReplayMsgHandler.cpp b/src/xrpld/app/ledger/detail/LedgerReplayMsgHandler.cpp index e1eb51fda7..9356f17af0 100644 --- a/src/xrpld/app/ledger/detail/LedgerReplayMsgHandler.cpp +++ b/src/xrpld/app/ledger/detail/LedgerReplayMsgHandler.cpp @@ -53,7 +53,7 @@ LedgerReplayMsgHandler::processProofPathRequest( { case protocol::lmACCOUNT_STATE: return ledger->stateMap().getProofPath(key); - case protocol::lmTRANASCTION: + case protocol::lmTRANSACTION: return ledger->txMap().getProofPath(key); default: // should not be here diff --git a/src/xrpld/app/misc/detail/ValidatorList.cpp b/src/xrpld/app/misc/detail/ValidatorList.cpp index 12ba52fa36..5c1c5e80a1 100644 --- a/src/xrpld/app/misc/detail/ValidatorList.cpp +++ b/src/xrpld/app/misc/detail/ValidatorList.cpp @@ -528,7 +528,7 @@ splitMessageParts( "xrpl::splitMessageParts : maximum message size"); messages.emplace_back( - std::make_shared(smallMsg, protocol::mtVALIDATORLIST), + std::make_shared(smallMsg, protocol::mtVALIDATOR_LIST), sha512Half(smallMsg), 1); return messages.back().numVLs; @@ -555,7 +555,7 @@ splitMessageParts( { messages.emplace_back( std::make_shared( - *smallMsg, protocol::mtVALIDATORLISTCOLLECTION), + *smallMsg, protocol::mtVALIDATOR_LIST_COLLECTION), sha512Half(*smallMsg), smallMsg->blobs_size()); return messages.back().numVLs; @@ -592,7 +592,7 @@ buildValidatorListMessage( "xrpl::buildValidatorListMessage(ValidatorBlobInfo) : maximum " "message size"); messages.emplace_back( - std::make_shared(msg, protocol::mtVALIDATORLIST), + std::make_shared(msg, protocol::mtVALIDATOR_LIST), sha512Half(msg), 1); return 1; @@ -640,7 +640,8 @@ buildValidatorListMessage( else { messages.emplace_back( - std::make_shared(msg, protocol::mtVALIDATORLISTCOLLECTION), + std::make_shared( + msg, protocol::mtVALIDATOR_LIST_COLLECTION), sha512Half(msg), msg.blobs_size()); return messages.back().numVLs; diff --git a/src/xrpld/app/tx/detail/Batch.cpp b/src/xrpld/app/tx/detail/Batch.cpp index 277bd4e3b7..a26bc52880 100644 --- a/src/xrpld/app/tx/detail/Batch.cpp +++ b/src/xrpld/app/tx/detail/Batch.cpp @@ -305,6 +305,16 @@ Batch::preflight(PreflightContext const& ctx) } } + // Check that the Fee is native asset (XRP) and zero + if (auto const fee = stx.getFieldAmount(sfFee); + !fee.native() || fee.xrp() != beast::zero) + { + JLOG(ctx.j.debug()) << "BatchTrace[" << parentBatchId << "]: " + << "inner txn must have a fee of 0. " + << "txID: " << hash; + return temBAD_FEE; + } + auto const innerAccount = stx.getAccountID(sfAccount); if (auto const preflightResult = xrpl::preflight( ctx.app, ctx.rules, parentBatchId, stx, tapBATCH, ctx.j); @@ -317,16 +327,6 @@ Batch::preflight(PreflightContext const& ctx) return temINVALID_INNER_BATCH; } - // Check that the fee is zero - if (auto const fee = stx.getFieldAmount(sfFee); - !fee.native() || fee.xrp() != beast::zero) - { - JLOG(ctx.j.debug()) << "BatchTrace[" << parentBatchId << "]: " - << "inner txn must have a fee of 0. " - << "txID: " << hash; - return temBAD_FEE; - } - // Check that Sequence and TicketSequence are not both present if (stx.isFieldPresent(sfTicketSequence) && stx.getFieldU32(sfSequence) != 0) diff --git a/src/xrpld/app/tx/detail/InvariantCheck.cpp b/src/xrpld/app/tx/detail/InvariantCheck.cpp index eb751c817f..0b237905e8 100644 --- a/src/xrpld/app/tx/detail/InvariantCheck.cpp +++ b/src/xrpld/app/tx/detail/InvariantCheck.cpp @@ -84,9 +84,9 @@ operator|(Privilege lhs, Privilege rhs) #pragma push_macro("TRANSACTION") #undef TRANSACTION -#define TRANSACTION(tag, value, name, delegatable, amendment, privileges, ...) \ - case tag: { \ - return (privileges) & priv; \ +#define TRANSACTION(tag, value, name, delegable, amendment, privileges, ...) \ + case tag: { \ + return (privileges) & priv; \ } bool diff --git a/src/xrpld/overlay/detail/Message.cpp b/src/xrpld/overlay/detail/Message.cpp index eb7b88894a..d03cd5e0da 100644 --- a/src/xrpld/overlay/detail/Message.cpp +++ b/src/xrpld/overlay/detail/Message.cpp @@ -68,8 +68,8 @@ Message::compress() case protocol::mtGET_LEDGER: case protocol::mtLEDGER_DATA: case protocol::mtGET_OBJECTS: - case protocol::mtVALIDATORLIST: - case protocol::mtVALIDATORLISTCOLLECTION: + case protocol::mtVALIDATOR_LIST: + case protocol::mtVALIDATOR_LIST_COLLECTION: case protocol::mtREPLAY_DELTA_RESPONSE: case protocol::mtTRANSACTIONS: return true; diff --git a/src/xrpld/overlay/detail/ProtocolMessage.h b/src/xrpld/overlay/detail/ProtocolMessage.h index 51dfc1ac7c..77ad368ccd 100644 --- a/src/xrpld/overlay/detail/ProtocolMessage.h +++ b/src/xrpld/overlay/detail/ProtocolMessage.h @@ -63,9 +63,9 @@ protocolMessageName(int type) return "status"; case protocol::mtHAVE_SET: return "have_set"; - case protocol::mtVALIDATORLIST: + case protocol::mtVALIDATOR_LIST: return "validator_list"; - case protocol::mtVALIDATORLISTCOLLECTION: + case protocol::mtVALIDATOR_LIST_COLLECTION: return "validator_list_collection"; case protocol::mtVALIDATION: return "validation"; @@ -411,11 +411,11 @@ invokeProtocolMessage( success = detail::invoke( *header, buffers, handler); break; - case protocol::mtVALIDATORLIST: + case protocol::mtVALIDATOR_LIST: success = detail::invoke( *header, buffers, handler); break; - case protocol::mtVALIDATORLISTCOLLECTION: + case protocol::mtVALIDATOR_LIST_COLLECTION: success = detail::invoke( *header, buffers, handler); break; diff --git a/src/xrpld/overlay/detail/TrafficCount.cpp b/src/xrpld/overlay/detail/TrafficCount.cpp index 6fb397ea71..21b4ba78a4 100644 --- a/src/xrpld/overlay/detail/TrafficCount.cpp +++ b/src/xrpld/overlay/detail/TrafficCount.cpp @@ -9,8 +9,8 @@ std::unordered_map const {protocol::mtMANIFESTS, TrafficCount::category::manifests}, {protocol::mtENDPOINTS, TrafficCount::category::overlay}, {protocol::mtTRANSACTION, TrafficCount::category::transaction}, - {protocol::mtVALIDATORLIST, TrafficCount::category::validatorlist}, - {protocol::mtVALIDATORLISTCOLLECTION, + {protocol::mtVALIDATOR_LIST, TrafficCount::category::validatorlist}, + {protocol::mtVALIDATOR_LIST_COLLECTION, TrafficCount::category::validatorlist}, {protocol::mtVALIDATION, TrafficCount::category::validation}, {protocol::mtPROPOSE_LEDGER, TrafficCount::category::proposal},