Skip to content

fix: Preventing attacker to suppress AMM trading fees indefinitely and extract value from liquidity providers - #7867

Open
Kassaking7 wants to merge 1 commit into
XRPLF:developfrom
Kassaking7:DEFI-716
Open

fix: Preventing attacker to suppress AMM trading fees indefinitely and extract value from liquidity providers#7867
Kassaking7 wants to merge 1 commit into
XRPLF:developfrom
Kassaking7:DEFI-716

Conversation

@Kassaking7

Copy link
Copy Markdown
Contributor

High Level Overview of Change

An attacker will suppress AMM trading fees indefinitely and extract value from liquidity providers: Failure to invalidate vote slots and recompute the trading fee after a full LP withdrawal will cause persistent fee manipulation losses for liquidity providers as an attacker will perform a flash deposit, vote for a reduced fee, withdraw all liquidity, and leave a stale vote that continues to control the pool fee.

Context of Change

API Impact

  • Public API: New feature (new methods and/or new fields)
  • Public API: Breaking change (in general, breaking changes should only impact the next api_version)
  • libxrpl change (any change that may affect libxrpl or dependents of libxrpl)
  • Peer protocol change (must be backward compatible or bump the peer protocol version)

@Kassaking7 Kassaking7 changed the title fix: preventing attacker to suppress AMM trading fees indefinitely and extract value from liquidity providers fix: Preventing attacker to suppress AMM trading fees indefinitely and extract value from liquidity providers Jul 24, 2026
@codecov

codecov Bot commented Jul 24, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 95.34884% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/libxrpl/ledger/helpers/AMMHelpers.cpp 95.1% 2 Missing ⚠️

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant