Documentation ¶
Overview ¶
Copyright (c) 2023-2024 Nibi, Inc.
Copyright (c) 2023-2024 Nibi, Inc.
Copyright (c) 2023-2024 Nibi, Inc.
Index ¶
- Constants
- Variables
- func AnteHandlerError(shortDesc string) error
- func MAX_COMMISSION() sdk.Dec
- func NewErrMaxValidatorCommission(gotCommission sdk.Dec) error
- func NewFixedGasMeter(fixedGas types.Gas) types.GasMeter
- type AnteDecoratorAuthzGuard
- type AnteDecoratorEnsureSinglePostPriceMessage
- type AnteDecoratorGasWanted
- type AnteDecoratorPreventEtheruemTxMsgs
- type AnteDecoratorStakingCommission
- type AnteHandlerOptions
- type TxFeeChecker
Constants ¶
const OracleMessageGas = 500
Variables ¶
var ( ErrOracleAnte = registerError("oracle ante error") ErrMaxValidatorCommission = registerError("validator commission rate is above max") )
app/ante "sentinel" errors
Functions ¶
func AnteHandlerError ¶
func MAX_COMMISSION ¶
Types ¶
type AnteDecoratorAuthzGuard ¶
type AnteDecoratorAuthzGuard struct{}
AnteDecoratorAuthzGuard filters autz messages
func (AnteDecoratorAuthzGuard) AnteHandle ¶
func (rmd AnteDecoratorAuthzGuard) AnteHandle( ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler, ) (newCtx sdk.Context, err error)
AnteHandle rejects "authz grant generic --msg-type '/eth.evm.v1.MsgEthereumTx'" Also rejects authz exec tx.json with any MsgEthereumTx inside
type AnteDecoratorEnsureSinglePostPriceMessage ¶
type AnteDecoratorEnsureSinglePostPriceMessage struct{}
AnteDecoratorEnsureSinglePostPriceMessage ensures that there is only one oracle vote message in the transaction and sets the gas meter to a fixed value.
func (AnteDecoratorEnsureSinglePostPriceMessage) AnteHandle ¶
type AnteDecoratorGasWanted ¶
type AnteDecoratorGasWanted struct{}
AnteDecoratorGasWanted keeps track of the gasWanted amount on the current block in transient store for BaseFee calculation.
func (AnteDecoratorGasWanted) AnteHandle ¶
type AnteDecoratorPreventEtheruemTxMsgs ¶
type AnteDecoratorPreventEtheruemTxMsgs struct{}
AnteDecoratorPreventEtheruemTxMsgs prevents invalid msg types from being executed
func (AnteDecoratorPreventEtheruemTxMsgs) AnteHandle ¶
func (rmd AnteDecoratorPreventEtheruemTxMsgs) AnteHandle( ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler, ) (newCtx sdk.Context, err error)
AnteHandle rejects messages that requires ethereum-specific authentication. For example `MsgEthereumTx` requires fee to be deducted in the antehandler in order to perform the refund.
type AnteDecoratorStakingCommission ¶
type AnteDecoratorStakingCommission struct{}
AnteDecoratorStakingCommission: Implements sdk.AnteDecorator, enforcing the maximum staking commission for validators on the network.
func (AnteDecoratorStakingCommission) AnteHandle ¶
type AnteHandlerOptions ¶
type AnteHandlerOptions struct { sdkante.HandlerOptions IBCKeeper *ibckeeper.Keeper DevGasKeeper *devgaskeeper.Keeper DevGasBankKeeper devgasante.BankKeeper EvmKeeper *evmkeeper.Keeper AccountKeeper authkeeper.AccountKeeper TxCounterStoreKey types.StoreKey WasmConfig *wasmtypes.WasmConfig MaxTxGasWanted uint64 }
func (*AnteHandlerOptions) ValidateAndClean ¶
func (opts *AnteHandlerOptions) ValidateAndClean() error