(self)
| 41 | del ql |
| 42 | |
| 43 | def test_elf_partial_linux_x8664(self): |
| 44 | snapshot_file = r'/tmp/snapshot.bin' |
| 45 | |
| 46 | def dump(ql: Qiling, *args, **kw): |
| 47 | ql.save(reg=False, cpu_context=True, snapshot=snapshot_file) |
| 48 | ql.emu_stop() |
| 49 | |
| 50 | ql = Qiling(["../examples/rootfs/x8664_linux/bin/sleep_hello"], "../examples/rootfs/x8664_linux", verbose=QL_VERBOSE.DEFAULT) |
| 51 | load_address = ql.profile.getint("OS64", "load_address") |
| 52 | ql.hook_address(dump, load_address + 0x1094) |
| 53 | ql.run() |
| 54 | |
| 55 | ql = Qiling(["../examples/rootfs/x8664_linux/bin/sleep_hello"], "../examples/rootfs/x8664_linux", verbose=QL_VERBOSE.DEBUG) |
| 56 | load_address = ql.profile.getint("OS64", "load_address") |
| 57 | ql.restore(snapshot=snapshot_file) |
| 58 | |
| 59 | begin_point = load_address + 0x109e |
| 60 | end_point = load_address + 0x10bc |
| 61 | |
| 62 | ql.run(begin_point, end_point) |
| 63 | |
| 64 | del ql |
| 65 | |
| 66 | def test_elf_x_only_segment(self): |
| 67 | def stop(ql: Qiling): |
nothing calls this directly
no test coverage detected