Skip to content

Latest commit

 

History

History
53 lines (30 loc) · 1.23 KB

File metadata and controls

53 lines (30 loc) · 1.23 KB

Proper Champagne Raven

Medium

Wrong pragma

Summary

The pragma used in HatsSignerGate.sol is:

pragma solidity >=0.8.13;

But the usage of transient keyword makes the pragma wrong.

Root Cause

In HatsSignerGate.sol:2, the pragma is false since the compiler will not understand the transient keyword for solidity versions <0.8.27

Internal pre-conditions

No response

External pre-conditions

No response

Attack Path

No response

Impact

The compiler will not be able to compile depending on the pragma version.

PoC

No response

Mitigation

Change pragma to:

pragma solidity >=0.8.27;

For judging:

Some people will invalidate because of this rule:

Using Solidity versions that support EVM opcodes that don't work on networks on which the protocol is deployed is not a valid issue because one can manage compilation flags to compile for past EVM versions on newer Solidity versions.

But note that here it is different: the compiler will not work for most of compiler versions. It is not due to opcodes that don't work on networks on which the protocol is deployed.