sherlock-audit / 2023-02-kairos-judging

2 stars 0 forks source link

ADM - Signature malleability vulnerability in openZeppelin contracts library version < 4.7.3. #146

Closed sherlock-admin closed 1 year ago

sherlock-admin commented 1 year ago

ADM

medium

Signature malleability vulnerability in openZeppelin contracts library version < 4.7.3.

Summary

ECDSA.recover() is being used with an openZeppelin contracts version < 4.7.3 which contains a signature malleability vulnerability.

Vulnerability Detail

In the function checkOfferArg() in BorrowCheckers.sol ECDSA.recover() is called with a signature that is a single bytes argument. This can results in the function being vulnerable to signature reuse.

Impact

An offer may be accepted against more than once.

Code Snippet

package.json#L16 BorrowCheckers.sol#L29

Tool used

Manual Review

Recommendation

Update openZeppelin's contract library to at least version 4.7.3.

Duplicate of #151