Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x64 mode 066h & REX.W bug? #83

Open
DrGolova opened this issue Apr 8, 2014 · 0 comments
Open

x64 mode 066h & REX.W bug? #83

DrGolova opened this issue Apr 8, 2014 · 0 comments

Comments

@DrGolova
Copy link

DrGolova commented Apr 8, 2014

Hello,

UDIs86 v1.7.2 in 64-bit mode disassemble "66 48 68 01 23 45 67" sequence as 5-bytes long "push 2301h" instruction.
But it must be 7-bytes long "push 067452301h" (REX.W bit must supersede 066h data-size override prefix).

Actually UDis86 just lose REX.W in resolve_mode() due to invalid flags in u->itab_entry->prefix for 068h opcode and fall into invalid 16-bit mode disassembling.
Quick bruteforcing also shows such issue for 0E8h & 0E9h opcodes (I checked only 1-byte opcodes and only for 066h & REX.W mixing).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant