def find(arg, int_size): matches = [] addr = 0 for x in range(100): newAddr = FindText(addr, SEARCH_DOWN, 0, 0, arg) if newAddr != 0xffffffffffffffffL: if newAddr > addr: addr = newAddr matches.append(addr) else: addr += 0x4 else: break string = copy(style) string += "<p>" for addr in matches: regions = [] get_mem_recursive(addr, regions, int_size=int_size) string += parse_mem(regions) + "<br>" string += "</p>" form.textEdit.append(string) form.textEdit.verticalScrollBar().setValue( form.textEdit.verticalScrollBar().maximum())
def get(addr, int_size, n=20): string = copy(style) string += "<p>" for x in range(n): regions = [] get_mem_recursive(addr + x * 4, regions, int_size=int_size) string += parse_mem(regions) + "<br>" string += "</p>" form.textEdit.append(string) form.textEdit.verticalScrollBar().setValue(form.textEdit.verticalScrollBar().maximum())
def deref_mem(): results = [[], []] int_size = 4 if get_bits() else 8 for i, reg in [(i, getattr(cpu, i)) for i in registers]: regions = [] get_mem_recursive(reg, regions, int_size=int_size) results[0].append((i, regions)) for i in range(0, config["stack_display_length"]): regions = [] get_mem_recursive(cpu.rsp + (i*int_size), regions, int_size=int_size) results[1].append((i*int_size, regions)) return results
def deref_mem(): results = [[], []] int_size = 4 if get_bits() else 8 for i, reg in [(i, getattr(cpu, i.strip(" "))) for i in registers]: regions = [] get_mem_recursive(reg, regions, int_size=int_size) results[0].append((i, regions)) for i in range(0, 100, 4): regions = [] get_mem_recursive(cpu.rsp + i, regions, int_size=int_size) results[1].append((i, regions)) return results
def deref_mem(): results = [[], []] int_size = 4 if get_bits() else 8 for i, reg in [(i, get_rg(i)) for i in (x64_registers if int_size == 8 else x86_registers) ]: regions = [] get_mem_recursive(reg, regions, int_size=int_size) results[0].append((i, regions)) for i in range(0, config["stack_display_length"]): regions = [] get_mem_recursive(get_rg("RSP" if int_size == 8 else "ESP") + (i * int_size), regions, int_size=int_size) results[1].append((i * int_size, regions)) return results