|
|
|
|
@ -61,39 +61,60 @@ def test_find_fake_fast_command(start_binary):
|
|
|
|
|
# setup_mem(0x20, 0x8)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_result(result, 0x20)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast --align &target_address", to_string=True)
|
|
|
|
|
check_result(result, 0x20)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x2F, 0x8)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_result(result, 0x2F)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast --align &target_address", to_string=True)
|
|
|
|
|
check_result(result, 0x2F)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x20, 0x9)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_result(result, 0x20)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast --align &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x20, 0x0)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast --align &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x20, 0x7)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast --align &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x1F, 0x8)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast --align &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x80, 0x78)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_result(result, 0x80)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast --align &target_address", to_string=True)
|
|
|
|
|
check_result(result, 0x80)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x80, 0x7F)
|
|
|
|
|
# # setup_mem(0x80, 0x7F)
|
|
|
|
|
# result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
# check_result(result, 0x80)
|
|
|
|
|
# gdb.execute("continue")
|
|
|
|
|
@ -101,17 +122,31 @@ def test_find_fake_fast_command(start_binary):
|
|
|
|
|
# setup_mem(0x80, 0x80)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast --align &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x100, 0x10)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address 0x100", to_string=True)
|
|
|
|
|
check_result(result, 0x100)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x100, 0x90)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address 0x100", to_string=True)
|
|
|
|
|
check_result(result, 0x100)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|
|
|
|
|
# setup_mem(0x100, 0x100)
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
|
|
|
|
|
result = gdb.execute("find_fake_fast &target_address 0x100", to_string=True)
|
|
|
|
|
check_no_results(result)
|
|
|
|
|
gdb.execute("continue")
|
|
|
|
|
|