From cb1cbae9c9a0f78fcd7b057633341661fa77f25e Mon Sep 17 00:00:00 2001 From: Horde Nicolas Date: Sun, 11 Jul 2021 18:51:41 +0200 Subject: [PATCH] =?UTF-8?q?Reactive=20la=20syntaxe=20Nasm=20en=20compilati?= =?UTF-8?q?on=20et=20ajoute=20le=20d=C3=A9tail=20en=20d=C3=A9sassemblage?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ia86.cpp | 2 ++ scenarios.json | 1 + 2 files changed, 3 insertions(+) diff --git a/ia86.cpp b/ia86.cpp index 9805948..a6259f7 100644 --- a/ia86.cpp +++ b/ia86.cpp @@ -336,6 +336,7 @@ void Desassembler::Desassemble(uint8_t *content, uint32_t address,uint32_t size, try { srcsize=cs_disasm(handle, content, size, address, 0, &insn); + cs_option(handle, CS_OPT_DETAIL, CS_OPT_ON); if (srcsize == 0) throw Error("Désassembleur - désassemblage.....................[ERREUR]"); else @@ -384,6 +385,7 @@ Assembler::Assembler(TextWindow *log) : log(log) { log->append(e.what()); } + ks_option(ks, KS_OPT_SYNTAX, KS_OPT_SYNTAX_NASM); } std::vector Assembler::MultiAssemble(std::string source,uint32_t address) diff --git a/scenarios.json b/scenarios.json index 19ff558..145f684 100644 --- a/scenarios.json +++ b/scenarios.json @@ -10,6 +10,7 @@ inc dx mov esi,0x44440234 hlt +jmp 0x14D .org 0x8D mov es,ax .org 0x14D