Submitted by shw, also found by 0xRajeev, pauliax and cmichel
When a router adds liquidity to the TransactionManager, the manager does not correctly handle the received amount if the transferred token is a deflationary or fee-on-transfer token. The actual received amount is less than what is recorded in the routerBalances variable. See TransactionManager.sol #L97 and #L101.
Recommend getting the received token amount by calculating the difference of token balance before and after the transfer, for example:
- LayneHaber (Connext) confirmed
ghoul-sol (Judge) commented:
