oyente icon indicating copy to clipboard operation
oyente copied to clipboard

fix: set default crytic-compile version

Open yagol2020 opened this issue 3 years ago • 2 comments

new version of crytic-compile change something, resulting in errors in _extract_bin_obj of input_helper.py. Specified crytic-compile version in setup.py (0.1.8)

yagol2020 avatar Jan 21 '22 08:01 yagol2020

evm 1.10.15 use hex as the operand, like

00000: PUSH1 0x80 00002: PUSH1 0x40 00004: MSTORE 00005: PUSH1 0x04 00007: CALLDATASIZE 00008: LT 00009: PUSH1 0x3f 0000b: JUMPI 0000c: PUSH1 0x00 0000e: CALLDATALOAD

i adapted hex in symExec.py

yagol2020 avatar Jan 21 '22 23:01 yagol2020

I tried your branch and it fixed the mentioned error, but getting something else:

Traceback (most recent call last):
  File "oyente.py", line 232, in <module>
    main()
  File "oyente.py", line 227, in main
    exit_code = analyze_solidity()
  File "oyente.py", line 109, in analyze_solidity
    inputs = helper.get_inputs(global_params.TARGET_CONTRACTS)
  File "//oyente/oyente/input_helper.py", line 79, in get_inputs
    source_map = SourceMap(contract, self.source, 'solidity', self.root_path, self.remap,
  File "/oyente/oyente/source_map.py", line 51, in __init__
    self.positions = self._get_positions()
  File "/oyente/oyente/source_map.py", line 187, in _get_positions
    asm = SourceMap.position_groups[self.cname]['asm']['.data']['0']
KeyError: '/oyente/oyente/Reentrancy.sol:Reentrance'

Any idea? thanks

riordant avatar Mar 05 '22 12:03 riordant