Skip to content
Request an audit

‹ All findings

setPools() could use more validation

Low/InfoNftperp Matching Engine·Three Sigma · NFT perpetuals · 29th January, 20243S-NFTPerp-N08

Description

AmmRouter:setPools() is an admin function but could still benefit from input validaiton to prevent mistakes. For example, specifying a pool id that already exists will overwrite the current amm, which could be dangerous.

Additionally, it should be checked that the bounds of the pools increase with the index, which is currently not enforced but the logic depends on it.

Status

Acknowledged