19 lines
431 B
Python
19 lines
431 B
Python
import logging
|
|
|
|
FORMAT = "[%(levelname)s] %(name)s %(filename)s:%(lineno)d: %(message)s"
|
|
logging.basicConfig(format=FORMAT)
|
|
logging.getLogger().setLevel(logging.INFO)
|
|
|
|
import androscalpel as asc
|
|
import zipfile as z
|
|
from androscalpel import *
|
|
|
|
APK_NAME = "test.apk"
|
|
DEX_NAME = "classes.dex"
|
|
|
|
with z.ZipFile(APK_NAME) as zipf:
|
|
with zipf.open(DEX_NAME, "r") as dex:
|
|
dex = dex.read()
|
|
|
|
apk = asc.Apk()
|
|
apk.add_dex_file(dex)
|