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

ST registers are incorrect #13118

Closed
bannsec opened this issue Feb 15, 2019 · 0 comments · Fixed by #15241
Closed

ST registers are incorrect #13118

bannsec opened this issue Feb 15, 2019 · 0 comments · Fixed by #15241
Labels
RDebug x86 Intel/AMD x86 architecture support issues

Comments

@bannsec
Copy link
Contributor

bannsec commented Feb 15, 2019

Work environment

Questions Answers
OS/arch/bits (mandatory) Ubuntu x86 64
File format of the file you reverse (mandatory) ELF
Architecture/bits of the file (mandatory) x86/64
r2 -v full output, not truncated (mandatory) radare2 3.3.0-git 81 @ linux-x86-64 git.3.3.0-git commit: 69ed848 build: 2019-02-13__23:04:54

Expected behavior

The dr st0 type commands and drf should show the correct values for the ST registers.

Actual behavior

They do not. It appears that radare is truncating reading the ST registers at 64bits, when in reality ST registers are 80 bits. This leads to wildly inaccurate responses about the values.

Steps to reproduce the behavior

  • Load test binary given below in both gdb and r2
  • Break at 0x004011fa
  • Compare what r2 believes the value is (st7) to gdb. Note it is truncated in r2.

Additional Logs, screenshots, source-code, configuration dump, ...

Adding the test binary.
known_values.zip

@XVilka XVilka added RDebug x86 Intel/AMD x86 architecture support issues labels Feb 21, 2019
radare pushed a commit that referenced this issue Oct 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
RDebug x86 Intel/AMD x86 architecture support issues
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants