Darinrikusham - Signature entered in createAttestation function in EthosAttestation contract could lead to anyone using signature for malicious purpose for other profileId #298
Labels
Sponsor Confirmed
The sponsor acknowledged this issue is valid
Won't Fix
The sponsor confirmed this issue will not be fixed
Darinrikusham
High
Signature entered in createAttestation function in EthosAttestation contract could lead to anyone using signature for malicious purpose for other profileId
Summary
Due to abi.encodePacked() method used for hashing and validating signature with Input params which has profileId and randValue of type uint256 as adjacent params in createAttestation function could lead to anyone using signature for other profileId then for which Ethos signer has signed for it.
Root Cause
Due to use of abi.encodePacked() in the underlying function to validate and check input with signature in which profileId and randValue are two adjacent inputs of type uint256 which could be used in different format of input to use the same signature and exploit it.
Internal pre-conditions
No response
External pre-conditions
No response
Attack Path
223
requested to createAttestation and Ethos generate randValue for example356
and user passed in the other params and retrieved the signature from Ethos.22
observed this transaction and used combination of profileId value22
and randValue3356
with other inputs remaining same can use the same signature before the above transaction gets signed from mempoolImpact
PoC
No response
Mitigation
This issue can be mitigated by using of abi.encode() instead of abi.encodePacked() or can change input param combination such that profileId and randValue are not adjacent.
The text was updated successfully, but these errors were encountered: