verichains / revela

Decompiler for Move smart contracts
https://revela.verichains.io
Other
42 stars 10 forks source link

Decompile script bytecode will panic. #3

Open kynehc opened 6 months ago

kynehc commented 6 months ago

./revela -s -b third_party/move/tools/revela/tests/bytecode/set_vals.mv

This cause the following results:

thread 'main' panicked at third_party/move/tools/revela/src/decompiler/bin_to_compiler_translator.rs:467:10:
invalid bounds in module: PartialVMError { major_status: INDEX_OUT_OF_BOUNDS, sub_status: None, message: Some("Index 2 out of bounds for 2 while indexing address identifier"), exec_state: None, indices: [(AddressIdentifier, 2)], offsets: [] }
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

I also tested other script bytecodes and also got panic.

aquynh commented 6 months ago

if you can fix this issue, please make pull req