0x73696d616f - Incorrect selector in `FlashRolloverLoan_G5::_acceptCommitment()` does not match `SmartCommitmentForwarder::acceptCommitmentWithRecipient()` #135
Incorrect selector in FlashRolloverLoan_G5::_acceptCommitment() does not match SmartCommitmentForwarder::acceptCommitmentWithRecipient()
Summary
FlashRolloverLoan_G5::_acceptCommitment() allows picking the SmartCommitmentForwarder, but the selector is incorrect, making it unusable for LenderCommitmentGroup_Smart.
Vulnerability Detail
FlashRolloverLoan_G5::_acceptCommitment() accepts the commitment to SmartCommitmentForwarder if _commitmentArgs.smartCommitmentAddress != address(0). However, the selector used is acceptSmartCommitmentWithRecipient(), which does not match SmartCommitmentForwarder::acceptCommitmentWithRecipient(), DoSing the ability to rollover loans for LenderCommitmentGroup_Smart.
Impact
FlashRolloverLoan_G5 will not work for LenderCommitmentGroup_Smart loans.
0x73696d616f
medium
Incorrect selector in
FlashRolloverLoan_G5::_acceptCommitment()
does not matchSmartCommitmentForwarder::acceptCommitmentWithRecipient()
Summary
FlashRolloverLoan_G5::_acceptCommitment()
allows picking theSmartCommitmentForwarder
, but the selector is incorrect, making it unusable forLenderCommitmentGroup_Smart
.Vulnerability Detail
FlashRolloverLoan_G5::_acceptCommitment()
accepts the commitment toSmartCommitmentForwarder
if_commitmentArgs.smartCommitmentAddress != address(0)
. However, the selector used isacceptSmartCommitmentWithRecipient()
, which does not matchSmartCommitmentForwarder::acceptCommitmentWithRecipient()
, DoSing the ability to rollover loans forLenderCommitmentGroup_Smart
.Impact
FlashRolloverLoan_G5
will not work forLenderCommitmentGroup_Smart
loans.Code Snippet
FlashRolloverLoan_G5::_acceptCommitment()
Tool used
Manual Review
Vscode
Recommendation
Insert the correct selector,
SmartCommitmentForwarder::acceptCommitmentWithRecipient()
.