-
Notifications
You must be signed in to change notification settings - Fork 113
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
Crash when searching outside the library range with KittyScanner #28
Comments
My Code |
|
This is to make it clear that it is outside the range. |
there is no memory permissions checks inside scanner functions. you have to check and provide valid readable memory range by yourself. if you want to scan a full library then use the segments array instead of only the base segment, then check which segment is readable |
Is it possible to read the segment from 0x00 to 0xFFFFFFFF and check if it is readable? |
Why would you use hardcoded memory range? |
use termux and print process maps
it could be malloc memory or bss. |
Ah, um... it seems very difficult, but I'll try it. |
That's right, it was in the range of anon:libc_malloc |
You can get malloc memory path with this, but on older android versions it might be empty
You can scan like this after
|
Thanks!! |
Hey, An error occurs in it.perms.compare |
Hey |
offset == 0 is just a check to filter out unnecessary maps to speed up the scan but you don't really need it. |
OK, Thanks! I'll try later. maybe this issue will be over. |
It has been confirmed that it does not work on some devices. Android versions are 7 and 11. |
In the sample, the search range is specified using ELF.baseSegment().startAddress and ELF.baseSegment().endAddress. However, if I use an arbitrary search range, it crashes. It is most likely that the program is crashing because it is reading an unreadable range.
There are no errors when compiling. can get the error with Logcat
Error:
Fatal signal 11 (SIGSEGV), code 2, fault addr 0xf15b6000 in tid 3825 (android.support)
The text was updated successfully, but these errors were encountered: