Skip to content

Map-A-Droid/apkutils

 
 

Repository files navigation

apkutils PyPI version GitHub license

A library that gets infos from APK.

Install

$ pip install apkutils

命令行使用

$ python3 -m apkutils -h
usage: apkutils [-h] [-m] [-s] [-f] [-c] [-V] p

positional arguments:
  p              path

optional arguments:
  -h, --help     show this help message and exit
  -m             Show manifest
  -s             Show strings
  -f             Show files
  -c             Show certs
  -V, --version  show program's version number and exit

用法

import binascii

from apkutils import __VERSION__, APK
apk = APK('test.apk')

if apk.get_manifest():
    print(json.dumps(apk.get_manifest(), indent=1))
elif apk.get_org_manifest():
    print(apk.get_org_manifest())

for item in apk.get_strings():
    print(binascii.unhexlify(item).decode(errors='ignore'))

for item in apk.get_files():
    print(item)

for item in apk.get_certs():
    print(item)

Reference

Packages

No packages published

Languages

  • Python 100.0%