Role providers can bypass intended restrictions and lower expiry set by other providers #57
Labels
2 (Med Risk)
Assets not at direct risk, but function/availability of the protocol could be impacted or leak value
bug
Something isn't working
M-05
primary issue
Highest quality submission among a set of duplicates
🤖_primary
AI based primary recommendation
🤖_18_group
AI based duplicate group recommendation
satisfactory
satisfies C4 submission criteria; eligible for awards
selected for report
This submission will be included/highlighted in the audit report
sponsor disputed
Sponsor cannot duplicate the issue, or otherwise disagrees this is an issue
sufficient quality report
This report is of sufficient quality
Lines of code
https://github.com/code-423n4/2024-08-wildcat/blob/main/src/access/FixedTermLoanHooks.sol#L413
Vulnerability details
Proof of Concept
If we look at the code comments, we'll see that role providers can update a user's credential only if at least one of the 3 is true:
This means that a role providers should not be able to reduce a credential set by another role provider.
However, this could easily be bypassed by simply splitting the call into 2 separate ones:
Recommended Mitigation Steps
Fix is non-trivial.
Assessed type
Context
The text was updated successfully, but these errors were encountered: