Project

One World
NFTDeFi
15,000 USDC
View results
Submission Details
Severity: medium
Invalid

In EIP712Domain_TYPE_HASH lack of chainId

Summary

The _setDomainSeperator()function in the EIP712Base.sol uses an incorrect type hash which does not match the format of data it is supposed to represent. In EIP-712, the domain separator should match the format: EIP712Domain(string name, string version, uint256 chainId, address verifyingContract).

Vulnerability Details

The EIP-712 standard specifies a domain separator format using the type hash for the following data structure:

EIP712 Domain (string name, string version, uint256 chainId, address verifyingContract)

However, in the current implementation:

struct EIP712Domain {
string name;
string version;
address verifyingContract;
bytes32 salt;
}

Impact

Signature verification failure: the type hash used in the domain separator does not match the required format, any off-chain signatures generated expecting the domain to be compliant with EIP712Domain will not match the calculated on-chain domain separator. As a result, all such signature verifications will fail.

Recommendations

use EIP712 Domain (string name, string version, uint256 chainId, address verifyingContract)

Updates

Lead Judging Commences

0xbrivan2 Lead Judge 9 months ago
Submission Judgement Published
Invalidated
Reason: Known issue

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.