Inactive validators blocked from claiming commissions despite passed timelock
A validator's commission claim can be requested and a timelock started, but if the validator is deactivated after the timelock passes, finalisation is blocked. This leaves the validator permanently unable to claim commissions that were already earned and unlocked.
Plume Network
Originally disclosed on Immunefi
52719 sc medium inactive validators blocked from claiming commissions despite passed timelock
- Report ID: #52719
- Report Type: Smart Contract
- Report severity: Medium
- Target: https://github.com/immunefi-team/attackathon-plume-network/blob/main/plume/src/facets/ValidatorFacet.sol
- Impacts:
- Theft of unclaimed yield
Brief / Intro
When a commission claim for a validator and token is requested, a timelock is started, after which the request can be finalized. However, both requesting and finalizing are disallowed for inactive validators, even if the timelock had already passed before the validator became inactive. This restriction is stricter than for slashed validators, which is inconsistent and does not make sense.
Vulnerability Details
Validators can be either deactivated or slashed. Both events set the slashedAtTimestamp to the current block.timestamp. However, slashing a validator is far more severe: it means that all other validators voted to slash it due to malicious behavior. By contrast, deactivation simply means the validator is no longer active, without implying any wrongdoing.
Therefore, it is illogical to completely block commission claims for deactivated validators while still allowing certain commission claims for slashed validators.
Relevant code excerpts:
When a validator is slashed, the commission claim can still be finalized if the timelock had already passed before the validator was slashed:
if (validator.slashed && readyTimestamp >= validator.slashedAtTimestamp) {
revert ValidatorInactive(validatorId);
}
In contrast, deactivated validators cannot finalize their requests at all, regardless of whether the timelock had already passed:
// For a non-slashed validator, simply require it to be active to finalize a claim.
if (!validator.slashed && !validator.active) {
revert ValidatorInactive(validatorId);
}
This creates an inconsistent and stricter rule for deactivated (inactive) validators compared to slashed validators.
Impact Details
{% hint style="warning" %} Inactive validators are permanently unable to claim their commissions, even if the timelock had already passed while they were active. This restriction is stricter than the rules for slashed validators, which is inconsistent and unfair. This can lead to loss/theft of unclaimed yield. {% endhint %}
References
Code references are provided throughout the report (links retained as-is):
- ValidatorFacet.sol (target): https://github.com/immunefi-team/attackathon-plume-network/blob/main/plume/src/facets/ValidatorFacet.sol
- PlumeRewardLogic.sol lines referenced in PoC: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/lib/PlumeRewardLogic.sol#L189-L191
- Request commission claim: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L500-L539
- Request timestamp set: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L531
- Requesting blocked for slashed or inactive: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L513-L515
- setValidatorStatus (deactivation): https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L252-L308
- Deactivation sets slashedAtTimestamp: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L277
- finalizeCommissionClaim checks: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L566-L575
Proof of Concept
{% stepper %} {% step %}
Step
Validator A accrues commissions.
Reference: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/lib/PlumeRewardLogic.sol#L189-L191 {% endstep %}
{% step %}
Step
The admin of validator A requests a commission claim by calling ValidatorFacet::requestCommissionClaim().
This sets the requestTimestamp to the current block.timestamp: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L531
Note: Requesting a claim is not possible for slashed or inactive validators: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L513-L515 {% endstep %}
{% step %}
Step
After the timelock has passed, the validator is deactivated by calling ValidatorFacet::setValidatorStatus().
Deactivation sets the slashedAtTimestamp to the current block.timestamp: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L277
{% endstep %}
{% step %}
Step
When the validator admin tries to finalize the commission claim by calling ValidatorFacet::finalizeCommissionClaim(), the call reverts even though the timelock had already passed while the validator was still active.
Reference (finalize checks): https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L566-L575
If the validator had been slashed instead, the call would not revert: https://github.com/immunefi-team/attackathon-plume-network/blob/580cc6d61b08a728bd98f11b9a2140b84f41c802/plume/src/facets/ValidatorFacet.sol#L566-L570
This demonstrates the inconsistency: deactivated validators cannot finalize even if the timelock expired before deactivation, while slashed validators may finalize depending on timestamps. {% endstep %} {% endstepper %}
Context
The target is the ValidatorFacet.sol contract of Plume Network, a smart contract facet that handles validator lifecycle and commission claims. The feature at the centre of the report is the commission claim flow: a validator's admin requests a claim, a timelock starts, and once the timelock has passed the admin can finalise the claim and receive the accrued commissions.
Two events can change a validator's status: deactivation and slashing. Both set slashedAtTimestamp to the current block.timestamp. Slashing is the severe one: all other validators voted to slash the validator for malicious behaviour. Deactivation only means the validator is no longer active and carries no implication of wrongdoing.
The report argues that the claim rules treat these two cases inconsistently, and that the stricter rule lands on the less severe case.
Setup
The report does not describe any accounts, tools, versions or deployment preconditions. It is a code review finding supported by a step-by-step scenario, not a live exploitation against a running environment. The relevant roles are the validator admin, who calls requestCommissionClaim() and finalizeCommissionClaim(), and the actor who calls setValidatorStatus() to deactivate the validator.
Finding it
The researcher compared the checks applied to slashed validators with those applied to deactivated validators in the commission claim path.
When a validator is slashed, a claim can still be finalised if the timelock had already passed before the validator was slashed:
if (validator.slashed && readyTimestamp >= validator.slashedAtTimestamp) {
revert ValidatorInactive(validatorId);
}
For a deactivated validator, the check is unconditional:
// For a non-slashed validator, simply require it to be active to finalize a claim.
if (!validator.slashed && !validator.active) {
revert ValidatorInactive(validatorId);
}
So a deactivated validator cannot finalise a request at all, even when the timelock expired while the validator was still active. A slashed validator, whose offence is far more serious, keeps the ability to finalise in that same timing situation. The researcher found this both inconsistent and illogical: deactivation implies no wrongdoing, yet it produces the harsher outcome.
Exploitation
Step 1: Validator A accrues commissions
Validator A builds up commissions over time. The report references PlumeRewardLogic.sol lines 189 to 191 as the place where this accrual is handled.
Step 2: The admin requests a commission claim
The admin of validator A calls ValidatorFacet::requestCommissionClaim(). This sets requestTimestamp to the current block.timestamp.
Requesting a claim is not possible for slashed or inactive validators, so at this point validator A must still be active. The report references lines 513 to 515 for that restriction.
Step 3: The validator is deactivated after the timelock passes
Once the timelock has passed, the validator is deactivated by calling ValidatorFacet::setValidatorStatus(). Deactivation sets slashedAtTimestamp to the current block.timestamp.
Step 4: Finalisation reverts
The validator admin calls ValidatorFacet::finalizeCommissionClaim(). The call reverts, even though the timelock had already passed while the validator was still active.
Had the validator been slashed instead, the call would not revert, because the slashed branch compares readyTimestamp against slashedAtTimestamp and only reverts when the timelock had not passed before the slash.
The scenario shows the inconsistency directly: deactivated validators cannot finalise even when the timelock expired before deactivation, while slashed validators may finalise depending on the timestamps.
Root cause
The finalisation logic branches on validator.slashed. For slashed validators it performs a timestamp comparison, allowing finalisation when the timelock had already passed before the slash. For non-slashed validators it only checks validator.active, with no timestamp comparison at all.
Because deactivation also writes slashedAtTimestamp, the data needed to make the same timestamp comparison exists for deactivated validators, but the code never uses it on that branch. The active check therefore overrides a timelock that had already been satisfied, and the request becomes permanently unfinalisable.
Impact
Inactive validators are permanently unable to claim their commissions, even if the timelock had already passed while they were active. The report classifies this as theft of unclaimed yield: the commissions stay unclaimed and are lost to the validator. The condition is that the validator is deactivated after requesting a claim and after the timelock has passed, but before finalising.
Fix
The report does not state that a fix was applied, and it does not propose a specific patch. The direction it points to is to make the deactivated case consistent with the slashed case, that is, to allow finalisation when the timelock had already passed before deactivation, using the slashedAtTimestamp that deactivation already records.
Variants to test
- Look for other state transitions that write the same timestamp field used by a timelock comparison, and check whether every consumer of that field applies the comparison consistently. A positive result is a path where a status change after the timelock expires blocks an action that the timestamp would otherwise permit.
- Compare the checks on request and on finalise for each status. A positive result is an asymmetry where one status is handled with a timestamp comparison and another with a plain boolean.
- Check whether deactivation and slashing share a field but not a policy. A positive result is a branch that keys on the severity flag (
slashed) rather than on the timestamp, producing a stricter rule for the milder event. - Test the reverse ordering: request, deactivate before the timelock passes, then wait. A positive result is a revert that is correct by design, which helps confirm the bug is specifically about timelocks satisfied before deactivation.
Hunting notes
This kind of bug hides in claim and withdrawal flows that combine a timelock with a status flag. The signal during review is a finalisation function that branches on a severity or status boolean and applies a timestamp comparison on only one side of the branch. When two different events write the same timestamp field, check every reader of that field for consistent use. The report establishes impact through a concrete four-step scenario that ends in a revert, while a slashed validator in the same timing situation would not revert.
What happened, in plain words
Plume Network is a blockchain project. Part of its code is a smart contract called ValidatorFacet.sol. A smart contract is a program that lives on a blockchain: it runs automatically, anyone can read its code, and once it is deployed its rules apply to everyone in the same way. You can think of it as a vending machine that is bolted to the wall: the rules printed on it are the rules, and nobody can quietly change them at the counter.
This contract manages "validators". A validator is a participant in the network that does work on its behalf, and in return it earns a share of the fees, called commissions. The contract also runs a claim process for those commissions: the person in charge of a validator (its admin) asks for the money, then has to wait for a fixed period called a timelock, and only after that period can the admin collect. A timelock is a deliberate delay, like the cooling-off period some banks apply before a large withdrawal, so that everyone can see what is happening before it happens.
A validator can stop being active in two different ways:
- Deactivation: the validator simply stops taking part. Nothing bad is implied. It is like an employee handing in their notice.
- Slashing: the other validators vote to punish it because it behaved maliciously. This is the serious one. It is like being fired for misconduct after a disciplinary hearing.
Both events record the same piece of information in the contract: the moment they happened, stored in a field called slashedAtTimestamp.
The problem the researcher found is about what happens to a pending commission claim when the validator is deactivated. The claim rules are inconsistent. A validator that was slashed (the serious case) can still finish a claim if the timelock had already run out before the slashing. A validator that was merely deactivated (the mild case) cannot finish the claim at all, even if the timelock had already run out while it was still active. The milder event gets the harsher treatment, and the commissions are stuck forever.
The report classifies this as "theft of unclaimed yield". "Yield" here means the earnings the validator had built up, and "unclaimed" means the money was never collected. The label is the program's way of saying that value which should have reached its owner is lost instead.
Context
The target of the report is the ValidatorFacet.sol contract of Plume Network. The word "facet" comes from a pattern where one large contract is split into smaller pieces, each handling one area of behaviour. This facet handles the validator lifecycle (becoming active, being deactivated, being slashed) and the commission claims.
The feature at the centre of the report is the commission claim flow. It has three moments:
- The validator's admin requests a claim. The contract notes the current time.
- A timelock starts. The admin has to wait.
- Once the timelock has passed, the admin finalises the claim and receives the accrued commissions.
Two events can change a validator's status: deactivation and slashing. Both write the current block.timestamp into slashedAtTimestamp. block.timestamp is the time recorded by the blockchain for the block in which the transaction is included; it is the clock the contract uses, not the clock on your laptop.
The report argues that the claim rules treat these two cases inconsistently, and that the stricter rule lands on the less severe case.
Setup
The report does not describe any accounts, tools, versions or deployment preconditions. It is a code review finding supported by a step-by-step scenario, not a live attack against a running system. In other words, nobody had to break into anything: the researcher read the contract's rules and worked out, on paper, a sequence of ordinary actions that ends badly.
The relevant roles are:
- the validator admin, who calls
requestCommissionClaim()andfinalizeCommissionClaim(); - the actor who calls
setValidatorStatus()to deactivate the validator.
Finding it
The researcher compared the checks applied to slashed validators with those applied to deactivated validators in the commission claim path. A "check" here is an if statement: a rule the contract tests before it lets an action through. If the test fails, the contract refuses and undoes everything, which is called a revert.
When a validator is slashed, a claim can still be finalised if the timelock had already passed before the validator was slashed:
if (validator.slashed && readyTimestamp >= validator.slashedAtTimestamp) {
revert ValidatorInactive(validatorId);
}
Line by line:
if (validator.slashed && ...): only do the following when this validator has been slashed.&&means "and", so both conditions must hold.readyTimestamp >= validator.slashedAtTimestamp: compare the moment the claim became ready (the end of the timelock) with the moment the validator was slashed. If the ready moment is the same as or later than the slash moment, the timelock had not finished before the slash.revert ValidatorInactive(validatorId);: refuse the action and report that the validator is inactive.
Read as a sentence: "If the validator was slashed, and the claim only became ready at or after the slash, then refuse." The flip side is the important part: if the claim became ready before the slash, the contract does not refuse, and the claim can be finalised.
For a deactivated validator, the check is unconditional:
// For a non-slashed validator, simply require it to be active to finalize a claim.
if (!validator.slashed && !validator.active) {
revert ValidatorInactive(validatorId);
}
Line by line:
// For a non-slashed validator, simply require it to be active to finalize a claim.: a comment written by the contract's authors, explaining the intent of the next line.if (!validator.slashed && !validator.active):!means "not". So: if the validator has not been slashed and is not active, then...revert ValidatorInactive(validatorId);: ...refuse the action.
There is no timestamp comparison here at all. The only question asked is "is it active right now?". A deactivated validator answers no, so the claim is refused, no matter when the timelock ended.
So a deactivated validator cannot finalise a request at all, even when the timelock expired while the validator was still active. A slashed validator, whose offence is far more serious, keeps the ability to finalise in that same timing situation. The researcher found this both inconsistent and illogical: deactivation implies no wrongdoing, yet it produces the harsher outcome.
Exploitation
"Exploitation" here does not mean breaking in. It means walking through ordinary, permitted actions in a particular order to show that the rules produce a bad result. The report lays this out as four steps.
Step 1: Validator A accrues commissions
Validator A builds up commissions over time. The report references PlumeRewardLogic.sol lines 189 to 191 as the place where this accrual is handled. Accrual simply means the earnings add up as the validator does its work, the way interest adds up in a savings account.
Step 2: The admin requests a commission claim
The admin of validator A calls ValidatorFacet::requestCommissionClaim(). The :: notation is just a way of writing "this function, in this contract". This sets requestTimestamp to the current block.timestamp, so the contract now knows when the waiting period started.
Requesting a claim is not possible for slashed or inactive validators, so at this point validator A must still be active. The report references lines 513 to 515 for that restriction. This matters for the argument: the admin did everything correctly and at a time when the validator was in good standing.
Step 3: The validator is deactivated after the timelock passes
Once the timelock has passed, the validator is deactivated by calling ValidatorFacet::setValidatorStatus(). Deactivation sets slashedAtTimestamp to the current block.timestamp.
Why does this step matter? Because the timelock had already finished before the deactivation. At the moment the validator was deactivated, the admin was already entitled to collect. The deactivation happens afterwards and, in the researcher's view, should not take that entitlement away.
Step 4: Finalisation reverts
The validator admin calls ValidatorFacet::finalizeCommissionClaim(). The call reverts, even though the timelock had already passed while the validator was still active. A revert means the transaction is cancelled and its effects are undone, as if it never happened; the commissions stay where they are.
Had the validator been slashed instead, the call would not revert, because the slashed branch compares readyTimestamp against slashedAtTimestamp and only reverts when the timelock had not passed before the slash.
The scenario shows the inconsistency directly: deactivated validators cannot finalise even when the timelock expired before deactivation, while slashed validators may finalise depending on the timestamps.
Root cause
The finalisation logic branches on validator.slashed. "Branches" means it takes one path of code or another depending on a condition, like a fork in a road. For slashed validators it performs a timestamp comparison, allowing finalisation when the timelock had already passed before the slash. For non-slashed validators it only checks validator.active, with no timestamp comparison at all.
Because deactivation also writes slashedAtTimestamp, the data needed to make the same timestamp comparison exists for deactivated validators, but the code never uses it on that branch. The active check therefore overrides a timelock that had already been satisfied, and the request becomes permanently unfinalisable.
A useful comparison: imagine a building where the fire alarm unlocks the doors for anyone who was already inside when it rang, but a simple power cut locks everyone in regardless of when it happened. The information needed to treat the power cut fairly (who was inside before it happened) is recorded, but the rule never looks at it.
Impact
Inactive validators are permanently unable to claim their commissions, even if the timelock had already passed while they were active. The report classifies this as theft of unclaimed yield: the commissions stay unclaimed and are lost to the validator.
The condition is specific: the validator is deactivated after requesting a claim and after the timelock has passed, but before finalising. All three have to line up.
Fix
The report does not state that a fix was applied, and it does not propose a specific patch. The direction it points to is to make the deactivated case consistent with the slashed case, that is, to allow finalisation when the timelock had already passed before deactivation, using the slashedAtTimestamp that deactivation already records.
In plain terms: the contract already writes down the moment of deactivation, so the rule could simply ask "did the waiting period end before that moment?" and let the claim through if the answer is yes.
Variants to test
These are ideas for where else the same kind of mistake might hide. Each one describes what to look for and what a positive result would look like.
- Look for other state transitions that write the same timestamp field used by a timelock comparison, and check whether every consumer of that field applies the comparison consistently. A positive result is a path where a status change after the timelock expires blocks an action that the timestamp would otherwise permit.
- Compare the checks on request and on finalise for each status. A positive result is an asymmetry where one status is handled with a timestamp comparison and another with a plain boolean. A boolean is a value that is simply true or false, with no time information in it.
- Check whether deactivation and slashing share a field but not a policy. A positive result is a branch that keys on the severity flag (
slashed) rather than on the timestamp, producing a stricter rule for the milder event. - Test the reverse ordering: request, deactivate before the timelock passes, then wait. A positive result is a revert that is correct by design, which helps confirm the bug is specifically about timelocks satisfied before deactivation.
Hunting notes
This kind of bug hides in claim and withdrawal flows that combine a timelock with a status flag. The signal during review is a finalisation function that branches on a severity or status boolean and applies a timestamp comparison on only one side of the branch. When two different events write the same timestamp field, check every reader of that field for consistent use.
The report establishes impact through a concrete four-step scenario that ends in a revert, while a slashed validator in the same timing situation would not revert.
Glossary
- Smart contract: a program stored on a blockchain that runs automatically and follows the same rules for everyone.
- Blockchain: a shared record of transactions that many computers keep copies of, so entries are hard to change after the fact.
- Plume Network: the project whose contract is the target of this report.
- Validator: a network participant that does work on the network's behalf and earns commissions for it.
- Commission: the earnings a validator builds up for its work.
- Validator admin: the person in charge of a validator, who requests and finalises its commission claims.
- Facet: one piece of a larger contract that has been split into smaller parts, each handling one area of behaviour.
ValidatorFacet.sol: the contract file that handles validator status and commission claims in this report.PlumeRewardLogic.sol: a contract file referenced in the report as the place where commission accrual is handled.- Timelock: a deliberate waiting period that must pass before an action can be completed.
- Request a claim: the first step of collecting commissions, which records the current time and starts the timelock.
- Finalise a claim: the last step, which pays out the commissions once the timelock has passed.
- Deactivation: a validator stops being active, with no suggestion of wrongdoing.
- Slashing: a punishment voted for by the other validators because a validator behaved maliciously.
slashedAtTimestamp: the field in which the contract records the moment a validator was slashed or deactivated.requestTimestamp: the field recording when a commission claim was requested.readyTimestamp: the moment a claim becomes ready, that is, when its timelock ends.block.timestamp: the time the blockchain records for the block containing a transaction; the clock the contract uses.- Check: an
ifstatement that tests a condition before letting an action through. - Revert: the contract refusing an action and undoing the transaction, as if it never happened.
- Boolean: a value that is either true or false, carrying no time information.
- Branch: a fork in the code where one path or another is taken depending on a condition.
- Accrue: to build up over time, as earnings do.
- Yield: earnings produced by an asset or by work; here, the validator's commissions.
- Unclaimed yield: earnings that were never collected by their owner.
- Theft of unclaimed yield: the report's impact category for value that should reach its owner but is lost instead.
- Code review: reading a program's code to find problems, without attacking a running system.
- Proof of concept: a step-by-step demonstration showing that a problem is real.
- Bug bounty program: a scheme where projects reward researchers for reporting security problems.
- Severity: the rating a report gives to how serious a problem is; this one is Medium.