QA Report #114
Labels
bug
Something isn't working
duplicate
This issue or pull request already exists
QA (Quality Assurance)
Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax
Lines of code
https://github.com/code-423n4/2022-02-hubble/blob/main/contracts/AMM.sol#L730
https://github.com/code-423n4/2022-02-hubble/blob/main/contracts/MarginAccount.sol#L599
Vulnerability details
the governance can set the registry, therefore setting also the clearingHouse.
the clearingHouse has permissions to liquidate any trader.
also, they can set the clearingHouse in marginAccount and mint for themselves arbitrary amount of vusd, therefore they can steal all the funds.
Recomendation
don't allow the governance to change the registry.
The text was updated successfully, but these errors were encountered: