Closed atcuno closed 1 month ago
Ok, so this is quite strange. The relevant lines are:
for ref in range(0, self.page_size, self.ptr_size):
ptr_data = page[ref : ref + self.ptr_size]
(ptr,) = struct.unpack(self.ptr_struct, ptr_data)
Which can basically only go wrong if page_size isn't a multiple of ptr_size and I don't knwo that we ever have a page_size that isn't 4096 (I guess for really large pages)? Do you have the image that caused this, and can you either share it or look for basic info about it (page size, intel layer type, 32, pae, 64, that kind of thing)?
(For what it's worth, ptr_size
is set in the __init__
as self.ptr_size = struct.calcsize(ptr_struct)
so a mismatch between those two would be nigh on impossible...
Either that or your image is truncated, and this was looking at the last page? Also seems a bit questionable, but possible?
If you're going to mark a ticket as completed, please provide a short description for the resolution, even if it's just "no longer relevant" or similar? Otherwise it leaves people who come across the ticket scratching their head as to what changed...
Weird, I thought I did. Basically this was a Linux sample in our pool of Windows samples that triggered weird code paths in the scanning. Fixing it will be addressed in another ticket soon related to bugs we are finding in mass testing.
I triggered this backtrace when mass running plugins across samples:
I can dig in if needed, but I haven't dealt with the automagic for Windows before, so thought someone else would be able to fix it properly quicker.