FuzzingLabs / thoth

Cairo/Starknet security toolkit (bytecode analyzer, disassembler, decompiler, symbolic execution, SBMC)
https://fuzzinglabs.com/
GNU Affero General Public License v3.0
242 stars 21 forks source link

How can I disassemble Sierra bytecode? #127

Open mstrong-tech opened 1 year ago

mstrong-tech commented 1 year ago

Hi, I'm trying to disassemble the Sierra bytecode for Cairo 1 class but can't find the relevant command. I can see the -d option but it's for decompiling Sierra files. What I want to try is to disassemble the Sierra bytecode with a local JSON file. example here: class: 0x4d7d2ddf396736d7cdba26e178e30e3388d488984a94e03bc4af4841e222920 json: https://external.integration.starknet.io/feeder_gateway/get_class_by_hash?classHash=0x4d7d2ddf396736d7cdba26e178e30e3388d488984a94e03bc4af4841e222920 or https://external.integration.starknet.io/feeder_gateway/get_compiled_class_by_class_hash?classHash=0x4d7d2ddf396736d7cdba26e178e30e3388d488984a94e03bc4af4841e222920

pventuzelo commented 1 year ago

Hey, for sierra you should use thoth-sierra take a look here and let me know if you still have the bug: https://github.com/FuzzingLabs/thoth/blob/master/sierra/README.md