Description:Description\
depositWithSignature is allowed to be called by the permit creator only. No other contracts will be able to execute this function on behalf of the signer.
All the contracts in the staking folder have the same implementation, so the same issue persists across all.
Attack Scenario\
Describe how the vulnerability can be exploited.
As we can see msg.sender is always passed as owner. As a result, when someone with a valid permit signature wants to deposit on behalf of the owner he won’t be able to do so.
This will allow everyone with a valid signature to deposit for the owner. This will be helpful when an owner has no gas to execute the transaction, which is the main idea of this EIP
Github username: -- Twitter username: -- Submission hash (on-chain): 0xf20d1e2e80b3c38ae27a81365a5880d7a19fa12d7ce1195ae792befaba7e411d Severity: medium
Description: Description\
depositWithSignature
is allowed to be called by the permit creator only. No other contracts will be able to execute this function on behalf of the signer.All the contracts in the
staking
folder have the same implementation, so the same issue persists across all.Attack Scenario\ Describe how the vulnerability can be exploited.
Attachments
As we can see
msg.sender
is always passed as owner. As a result, when someone with a valid permit signature wants to deposit on behalf of the owner he won’t be able to do so.Modify the code like this:
This will allow everyone with a valid signature to deposit for the owner. This will be helpful when an owner has no gas to execute the transaction, which is the main idea of this EIP