goldenStaking
Function Type: external
Function Signature: goldenStaking(bool,uint256,bytes)
Function Selector: 0x475c31ff
The goldenStaking
function provides administrative control over staking operations. It is exclusively accessible to the goldenFisher
address, allowing privileged execution of stake/unstake actions that bypass standard verification (signature and nonce) requirements. This function operates under strict security parameters, prohibiting priority fees and processing payments via synchronous EVVM nonces.
Parameters
Parameter | Type | Description |
---|---|---|
isStaking | bool | true = Stake, false = Unstake |
amountOfStaking | uint256 | Amount of staking tokens to stake/unstake |
signature_EVVM | bytes | EVVM authorization signature |
The EVVM payment signature (signature_EVVM
) follows the Single Payment Signature Structure.
Workflow
Staking Process
- Authorization Validation: Verifies caller is the designated
goldenFisher
address - Process Execution: Invokes internal
stakingUserProcess
to:- Adjust staking balances
- Update historical records
- Handle unstaking cooldowns
- Manage re-staking restrictions
- Process payment via EVVM
- Distribute applicable rewards
For detailed information about the stakingUserProcess
implementation, refer to the stakingUserProcess.
Unstaking Process
- Authorization Validation: Verifies caller is the designated
goldenFisher
address - Process Execution: Invokes internal
stakingUserProcess
to:- Adjust staking balances
- Update historical records
- Manage unstaking cooldowns
- Handle re-staking restrictions
- Distribute applicable rewards
For detailed information about the stakingUserProcess
implementation, refer to the stakingUserProcess