8cba70dc90
- Add 8 files present in docker/fifa17-python/tools but missing from the top-level tree: fut_accounts.py + 7 test_*.py contracts (all committed in the server's docker tree; byte-identical to the running image). - Preserve newer responder work already matching the running container: utas_server.py (offlineSeason), lsx_responder_v2.py (OPENFUT_BIND), blaze_responder_v3b.py, autopatch.py, pow_server.py, fut_store.py, test_fut_contract.py, fifa17-hook-m1.sh. - Add 30 newer ghidra_queries (draft purchase/state, SBC 9-26, runtime registries). Local tree is now a strict superset of B with all shared files byte-identical.
31 lines
988 B
Python
31 lines
988 B
Python
"""Find indirect calls to service-interface slot +0xe0 and compare contracts."""
|
|
|
|
PATTERNS = (
|
|
bytes.fromhex("ff 90 e0 00 00 00"),
|
|
bytes.fromhex("ff 91 e0 00 00 00"),
|
|
bytes.fromhex("ff 92 e0 00 00 00"),
|
|
bytes.fromhex("ff 93 e0 00 00 00"),
|
|
bytes.fromhex("ff 96 e0 00 00 00"),
|
|
bytes.fromhex("ff 97 e0 00 00 00"),
|
|
bytes.fromhex("41 ff 90 e0 00 00 00"),
|
|
bytes.fromhex("41 ff 91 e0 00 00 00"),
|
|
bytes.fromhex("41 ff 92 e0 00 00 00"),
|
|
bytes.fromhex("41 ff 93 e0 00 00 00"),
|
|
)
|
|
|
|
seen = set()
|
|
for pattern in PATTERNS:
|
|
for hit in find_all(pattern, blocks=(".text",)):
|
|
owner = func(hit)
|
|
if owner is None:
|
|
continue
|
|
entry = int(owner.getEntryPoint().getOffset())
|
|
if entry in seen:
|
|
continue
|
|
seen.add(entry)
|
|
print("\n===== call %#x function %#x %s =====" %
|
|
(hit, entry, owner.getName()))
|
|
print(dec(owner, 120)[:12000])
|
|
print("callees", callees(owner)[:80])
|
|
|