Skip to content
Business logic Audit finding Intermediate

Missing Slippage Protection in Expired PT Redemption Causes User Fund Loss

The expired PT redemption function calls the SY contract's redeem with zero minimum output, so any external DEX swap it performs can return far fewer tokens than expected. An attacker could exploit this through MEV or unfavourable market conditions to cause users to lose funds.

0xPhantom2 Follow with Bluedragon, Schnilch and 8 others

Originally disclosed on Sherlock

Source: https://github.com/sherlock-audit/2025-06-notional-exponent-judging/issues/874

This issue has been acknowledged by the team but won't be fixed at this time.

Found by

0xPhantom2, Bluedragon, Schnilch, albahaca0000, boredpukar, jasonxiale, sergei2340, touristS, xiaoming90, yoooo, zhuying

Summary:

When PT tokens are expired, the _redeemPT function calls redeemExpiredPT which performs sy.redeem with minTokenOut: 0, allowing SY contracts that perform external DEX swaps to cause slippage losses without protection in both instant redemption and withdraw initiation flows.

Vulnerability Details:

The vulnerability occurs in the _redeemPT function which handles both expired and non-expired PT redemption. When PT.isExpired() returns true, it calls PendlePTLib.redeemExpiredPT.

The redeemExpiredPT function performs the redemption by calling sy.redeem with minTokenOut: 0. This means there's no slippage protection when the SY contract performs external DEX swaps or trades to convert the redeemed tokens to the target tokenOutSy.

Code Snippet:

Solidity
function redeemExpiredPT(
        IPPrincipalToken pt,
        IPYieldToken yt,
        IStandardizedYield sy,
        address tokenOutSy,
        uint256 netPtIn
    ) external returns (uint256 netTokenOut) {
        // PT Tokens are known to be ERC20 compliant
        pt.transfer(address(yt), netPtIn);
        uint256 netSyOut = yt.redeemPY(address(sy));
@->     netTokenOut = sy.redeem(address(this), netSyOut, tokenOutSy, 0, true); // AUDIT: no slippage protection
    }

This affects two critical flows:

  1. Instant Redemption: Called via _executeInstantRedemption.
  2. Withdraw Initiation: Called via _initiateWithdraw.

Impact

Users suffer direct fund loss when SY contracts perform unfavorable external DEX swaps during expired PT redemption, as the zero slippage protection allows maximum extractable value attacks and natural slippage losses.

The impact is amplified because users have no control over the redemption rate and cannot protect themselves against adverse market conditions or MEV attacks during the SY redemption process.

Proof of Concept (Scenario step by step):

  1. PT tokens expire and user initiates exit position
  2. _redeemPT is called and detects PT.isExpired() == true
  3. PendlePTLib.redeemExpiredPT is called with the expired PT amount
  4. PT tokens are transferred to YT contract and yt.redeemPY is called
  5. sy.redeem is called with minTokenOut: 0
  6. SY contract performs external DEX swap with unfavorable rates due to market conditions or MEV attacks
  7. User receives significantly fewer sUSDe tokens than expected with no recourse
  8. Loss propagates through either instant redemption or withdraw request flows

Recommended Mitigation:

Modify the redeemExpiredPT function to accept a minTokenOut parameter and pass it through to sy.redeem. Update both calling functions to calculate and provide appropriate slippage protection based on expected redemption rates.

Solidity
function redeemExpiredPT(
    IPPrincipalToken pt,
    IPYieldToken yt,
    IStandardizedYield sy,
    address tokenOutSy,
    uint256 netPtIn,
    uint256 minTokenOut  // Add slippage protection parameter
) external returns (uint256 netTokenOut) {
    pt.transfer(address(yt), netPtIn);
    uint256 netSyOut = yt.redeemPY(address(sy));
    netTokenOut = sy.redeem(address(this), netSyOut, tokenOutSy, minTokenOut, true);
}

Discussion

T-Woodward

This is an issue that will be managed through proper parameter choices, not code.

All SY tokens give you the option to redeem to a matching token (i.e. rsETH SY -> rsETH). If redeeming to the matching token, there will not be a fee or a trade and setting minTokenOut to 0 is fine.

So we'll just make sure to always redeem to the matching token and double check the SY's redemption function.

The original report as published on Sherlock, by 0xPhantom2. Images and videos are our own copies; raw HTML is shown as text. View it on Sherlock.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

The redeemExpiredPT function hardcodes minTokenOut to 0, removing any slippage protection for the subsequent SY redemption.

Impact

Users could suffer direct fund loss when SY contracts perform unfavourable external DEX swaps during expired PT redemption, as the zero slippage protection allows maximum extractable value attacks and natural slippage losses.

What the attacker needed

PT tokens have expired; SY contract performs external DEX swap; User initiates redemption or withdrawal

The fix

The team acknowledged the issue but stated it will be managed through proper parameter choices (always redeeming to the matching token) rather than a code fix.

How it was found

  1. PT tokens expire and user initiates exit position
  2. _redeemPT is called and detects PT.isExpired() == true
  3. PendlePTLib.redeemExpiredPT is called with the expired PT amount
  4. PT tokens are transferred to YT contract and yt.redeemPY is called
  5. sy.redeem is called with minTokenOut: 0
  6. SY contract performs external DEX swap with unfavorable rates due to market conditions or MEV attacks

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

When a user redeems an expired token, the code asks another contract to convert it into the desired token but sets the minimum acceptable amount to zero. This means the conversion can happen at any price, even a very bad one. An attacker who sees this transaction can manipulate the market to make the user receive much less than they should.

What is Business logic?

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.

More from Notional Exponent

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Business logic flaws

The lesson behind this report.

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.