Skip to content
This repository has been archived by the owner on Jan 10, 2025. It is now read-only.

stake-pool: Add lamports check for transient stake account on decrease #3805

Merged
merged 1 commit into from
Nov 19, 2022

Conversation

joncinque
Copy link
Contributor

Problem

decrease_validator_stake does not check that transient account meets minimum delegation requirement

From a security POV this is irrelevant since the stake program will abort the transaction. But the program already checks for the minimum rent exempt amount, so it feels weird to check for that but not for the minimum delegation.

Solution

Increase the check to include the minimum delegation.

@joncinque joncinque merged commit 135cbdf into solana-labs:master Nov 19, 2022
@joncinque joncinque deleted the sp-deccheck branch November 19, 2022 00:43
HaoranYi pushed a commit to HaoranYi/solana-program-library that referenced this pull request Jul 19, 2023
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants