# -*- coding: utf-8 -*-
import re
import zipfile

APK = r"C:\Users\Administrator\Desktop\notiMessage\reverse\apks\seabank_ph_base.apk"
METHOD_HINTS = [
    b"isRoot", b"isRooted", b"jailbroken", b"checkRoot", b"detectRoot",
    b"detectXposed", b"checkXposed", b"isXposed", b"checkFrida", b"isEmulator",
    b"checkIntegrity", b"SafeMode", b"needSafeMode", b"enterSafeMode",
    b"showRoot", b"rooted", b"factory settings",
]

with zipfile.ZipFile(APK) as zf:
    for name in sorted(zf.namelist()):
        if not name.endswith(".dex"):
            continue
        data = zf.read(name)
        hits = [h.decode("ascii", "ignore") for h in METHOD_HINTS if h in data]
        if hits:
            print(name, ":", ", ".join(hits))
