You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 7, 2024. It is now read-only.
sherlock-admin opened this issue
Jul 3, 2023
· 0 comments
Labels
DuplicateA valid issue that is a duplicate of an issue with `Has Duplicates` labelHighA valid High severity issueRewardA payout will be made for this issue
LiquidationFacet allows setPrice to be called with outdated prices
Summary
Vulnerability Detail
When prices are assigned to a symbol it only checks whether priceSig.timestamp <= maLayout.liquidationTimestamp[partyA] + maLayout.liquidationTimeout. It doesn't verify that the given price is recent, e.g. signed within the last 15 minutes.
Thus, the liquidator is able to assign any price in the past for a given symbol. The price determines the payout to the other party on liquidation. While liquidators are currently permissioned, the protocol team has communicated that it's supposed to be permissionless in the future.
Impact
Liquidator can use outdated prices when liquidating party A.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
DuplicateA valid issue that is a duplicate of an issue with `Has Duplicates` labelHighA valid High severity issueRewardA payout will be made for this issue
Ruhum
high
LiquidationFacet allows
setPrice
to be called with outdated pricesSummary
Vulnerability Detail
When prices are assigned to a symbol it only checks whether
priceSig.timestamp <= maLayout.liquidationTimestamp[partyA] + maLayout.liquidationTimeout
. It doesn't verify that the given price is recent, e.g. signed within the last 15 minutes.Neither does the Muon library check whether the price is valid:
Thus, the liquidator is able to assign any price in the past for a given symbol. The price determines the payout to the other party on liquidation. While liquidators are currently permissioned, the protocol team has communicated that it's supposed to be permissionless in the future.
Impact
Liquidator can use outdated prices when liquidating party A.
Code Snippet
https://github.com/sherlock-audit/2023-06-symmetrical/blob/main/symmio-core/contracts/facets/liquidation/LiquidationFacetImpl.sol#L38
https://github.com/sherlock-audit/2023-06-symmetrical/blob/main/symmio-core/contracts/libraries/LibMuon.sol#L50
Tool used
Manual Review
Recommendation
Check whether a price is recent:
priceSig.timestamp > block.timestamp - 30 minutes
Duplicate of #113
The text was updated successfully, but these errors were encountered: