Skip to content

Commit

Permalink
Validate bytecode in EthContractService.get_function_sighashes
Browse files Browse the repository at this point in the history
  • Loading branch information
medvedev1088 committed Oct 5, 2023
1 parent 7cef054 commit 570f69d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cli/polygonetl/service/eth_contract_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@
class EthContractService:

def get_function_sighashes(self, bytecode):
if not bytecode:
return []

bytecode = clean_bytecode(bytecode)
if bytecode is not None:
evm_code = EvmCode(contract=Contract(bytecode=bytecode), static_analysis=False, dynamic_analysis=False)
Expand Down

0 comments on commit 570f69d

Please sign in to comment.