-
-
Notifications
You must be signed in to change notification settings - Fork 755
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
heap
commands do not currently work for stripped glibc versions >= 2.34
#927
Comments
I have managed to make something work for some of the specified glibc versions a few months ago when I encountered this issue, but have yet to extensively test it. Anyone looking into this might wanna check it out It takes a relative offset from the stdin file structure from within glibc --- _IO_2_1_stdin. I feel like this commit may work from versions 2.34 onwards, and possibly even before 2.34 (untested). Would be great if someone with more time can look into this. |
Thanks for your input. Even though we had this version of calculating the address of the I am looking into an option to bruteforce the address of the Bruteforcing seems feasible in this case as the search space is quite constrained (at least for dynamically linked executables):
These facts could be used to quickly retrieve a list of valid candidates, and if the length of this list is exactly one, then with a high probability the I still need to check how to make this work on all architectures supported by GEF, and moreover if and how this could work in statically linked executables. Unfortunately, it may take me some time to verify all this as I'm very busy at work with some big deadlines coming up. |
The issue is that
__malloc_hook
was removed from the API in glibc version 2.34, which is the symbol which GEF uses as a hack to find themain_arena
when the libc is stripped.While a
__malloc_hook
symbol is still included in the glibc versions in question, it is just for compatibility reasons and it is not close to themain_arena
anymore.(source: https://sourceware.org/pipermail/libc-alpha/2021-August/129718.html)
Executing any
heap
command does not currently work for the specified glibc versions as they all rely on the correct identification of themain_arena
The text was updated successfully, but these errors were encountered: