xrpld
Loading...
Searching...
No Matches
xrpl::proposal Namespace Reference

Functions

std::uint32_t proposalOwnerCount (STObject const &proposedTx)
 Owner-reserve increments held by a proposal of the given transaction.
bool isProposalTx (STObject const &proposedTx)
 Whether the proposed transaction is itself a proposal transaction, which would nest one proposal inside another.
bool isValidProposal (STObject const &proposedTx)
 Whether the proposed transaction is independently submittable through the ordinary multi-sign path: not a nested proposal, not a pseudo-transaction, not itself flagged as someone else's inner batch transaction, and — if it is a Batch — none of its own inner transactions is a nested proposal or a pseudo-transaction either.
bool hasSignatureField (STObject const &proposedTx)
 Whether the proposed transaction carries any signature field.
bool hasEmptySigningPubKey (STObject const &proposedTx)
 Whether the proposed transaction's SigningPubKey is present and empty, as unsigned canonical form requires.

Variables

constexpr std::uint32_t kProposalOwnerCount = 5
 Owner-reserve increments held by a proposal of an ordinary transaction.
constexpr std::uint32_t kBatchProposalOwnerCount = 10
 Owner-reserve increments held by a proposal of a Batch transaction.

Function Documentation

◆ proposalOwnerCount()

std::uint32_t xrpl::proposal::proposalOwnerCount ( STObject const & proposedTx)

Owner-reserve increments held by a proposal of the given transaction.

Definition at line 27 of file ProposalHelpers.h.

◆ isProposalTx()

bool xrpl::proposal::isProposalTx ( STObject const & proposedTx)

Whether the proposed transaction is itself a proposal transaction, which would nest one proposal inside another.

TODO: cover ttTRANSACTION_PROPOSAL_SIGN and ttTRANSACTION_PROPOSAL_CANCEL once those transactions exist.

Definition at line 41 of file ProposalHelpers.h.

◆ isValidProposal()

bool xrpl::proposal::isValidProposal ( STObject const & proposedTx)

Whether the proposed transaction is independently submittable through the ordinary multi-sign path: not a nested proposal, not a pseudo-transaction, not itself flagged as someone else's inner batch transaction, and — if it is a Batch — none of its own inner transactions is a nested proposal or a pseudo-transaction either.

A Batch inner transaction cannot itself be pseudo (preflight0 rejects the pseudo/tfInnerBatchTxn combination generically), but that guard lives outside this feature, so it is checked again here rather than relied upon.

Definition at line 13 of file libxrpl/ledger/helpers/ProposalHelpers.cpp.

◆ hasSignatureField()

bool xrpl::proposal::hasSignatureField ( STObject const & proposedTx)

Whether the proposed transaction carries any signature field.

A proposal is stored in unsigned canonical form; signatures may only ever arrive through TransactionProposalSign. Shared by the create-time check and the invariant that guards the stored entry, so the two cannot drift apart.

Definition at line 67 of file ProposalHelpers.h.

◆ hasEmptySigningPubKey()

bool xrpl::proposal::hasEmptySigningPubKey ( STObject const & proposedTx)

Whether the proposed transaction's SigningPubKey is present and empty, as unsigned canonical form requires.

An absent field is not the same as an empty one, and a populated one means the payload was already signed.

Definition at line 81 of file ProposalHelpers.h.

Variable Documentation

◆ kProposalOwnerCount

std::uint32_t xrpl::proposal::kProposalOwnerCount = 5
constexpr

Owner-reserve increments held by a proposal of an ordinary transaction.

Definition at line 14 of file ProposalHelpers.h.

◆ kBatchProposalOwnerCount

std::uint32_t xrpl::proposal::kBatchProposalOwnerCount = 10
constexpr

Owner-reserve increments held by a proposal of a Batch transaction.

A proposed Batch stores up to eight inner transactions plus multi-account signatures, so it reserves more than an ordinary proposed transaction.

Definition at line 21 of file ProposalHelpers.h.