Open CouleeApps opened 4 years ago
And for reference, here is what the alternative lifting for ret produces:
It would be cool if this were fixed, I've asked about it a few times now. Current workaround is to lift it as
temp0 = pop
jump(temp0)
Branches have very similar behavior: https://github.com/Vector35/binaryninja-api/issues/1908
When binja is configured to lift return instructions as jump(pop), dataflow can resolve the address of the pop but does modify the stack. Lifting returns as
esp = esp + 4 ; jmp *(esp - 4)
resolves correctly.Current behavior:
Expected behavior:
After the first ret, the stack is popped and the second ret resolves to the next address pushed onto the stack, resolving an indirect jump, and continuing the chain.
Binary: asmtest.zip Arch hook for x86: