parse the Apk file AndroidManifest.xml
Project description
APK parse
reference androguard.
Example:
apkf = APK("myfile.apk")
apkf = APK(read("myfile.apk"), raw=True)
package
Return the name of the package
>>> apkf.package
com.android.vending
>>> apkf.get_package()
com.android.vending
file_md5
Return the file md5 of the apk
>>> apkf.file_md5
40bdd920a3a3d2acf432e3c5b485eb11
cert_md5
Return the cert md5 of the apk
>>> apkf.cert_md5
cde9f6208d672b54b1dacc0b7029f5eb
file_size
Return the apk file size
>>> apkf.file_size
11194863
androidversion
Return the apk version
>>> apkf.androidversion
{'Code': u'80341200', 'Name': u'5.4.12'}
get_androidversion_code()
Return the android version code
>>> apkf.get_androidversion_code()
80341200
get_androidversion_name()
Return the android version name
>>> apkf.get_androidversion_name()
5.4.12
get_min_sdk_version()
Return the android:minSdkVersion attribute
>>> apkf.get_min_sdk_version()
9
get_target_sdk_version()
Return the android:targetSdkVersion attribute
>>> apkf.get_target_sdk_version()
21
get_libraries()
Return the android:name attributes for libraries
>>> apkf.get_libraries()
[]
get_files()
Return the files inside the APK
>>> apkf.get_files()
[u'AndroidManifest.xml', u'assets/keys/dcb-pin-encrypt-v1/1',...]
get_files_types()
Return the files inside the APK with their associated types (by using python-magic)
Please pip install python-magic
>>> apkf.get_files_types()
{u'res/layout/play_card_bundle_item_small.xml': "Android's binary XML",...}
get_main_activity()
Return the name of the main activity
>>> apkf.get_main_activity()
com.android.vending.AssetBrowserActivity
get_activities()
Return the android:name attribute of all activities
>>> apkf.get_activities()
['com.android.vending.AssetBrowserActivity', ...]
get_services()
Return the android:name attribute of all services
>>> apkf.get_services()
['com.android.vending.GCMIntentService', ...]
get_receivers()
Return the android:name attribute of all receivers
>>> apkf.get_receivers()
['com.google.android.gcm.GCMBroadcastReceiver', ...]
get_providers()
Return the android:name attribute of all providers
>>> apkf.get_providers()
['com.google.android.finsky.providers.RecentSuggestionsProvider', ...]
get_permissions()
Return permissions
>>> apkf.get_permissions()
['com.android.vending.permission.C2D_MESSAGE', ...]
show()
Return FILES, PERMISSIONS, MAIN ACTIVITY...
>>> apkf.show()
FILES: ...
parse_icon()
Parse ICON of the apk, storage on icon_path
>>> apkf.parse_icon(icon_path='/tmp')
...
cert_text
>>> apkf.cert_text
Certificate:
Data:Version: 3 (0x2)
...
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
File details
Details for the file apk_parse-1.0.0.tar.gz
.
File metadata
- Download URL: apk_parse-1.0.0.tar.gz
- Upload date:
- Size: 50.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
348be49a12c08a623ecee27a967ad24478b038f280898f4e3cc4f1e2a70432a5
|
|
MD5 |
4a8adf77c7ffb03df3323f7c6cddb96e
|
|
BLAKE2b-256 |
10a34de3596eef8d017850a6b984540ef004fc60d442eff4cc131e864d921506
|
File details
Details for the file apk_parse-1.0.0-py3.7.egg
.
File metadata
- Download URL: apk_parse-1.0.0-py3.7.egg
- Upload date:
- Size: 62.5 kB
- Tags: Egg
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
b03fdf14275a5e9ad26058827fcd02f11751dbe22fe1b4b01a4e2febf8b42b21
|
|
MD5 |
ad78b55a108257a67bab9f0a654e1e26
|
|
BLAKE2b-256 |
169ecaf084013aff123e845293917808417dd1a6102ad90e21585c086e7c544e
|
File details
Details for the file apk_parse-1.0.0-py3.6.egg
.
File metadata
- Download URL: apk_parse-1.0.0-py3.6.egg
- Upload date:
- Size: 62.5 kB
- Tags: Egg
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
0797e9ce5b3218484085dedd5f71e0aed0845952df93b7303a24f353ab00e6dd
|
|
MD5 |
f4aa791142882de6f32407db07b2132d
|
|
BLAKE2b-256 |
23a168cb7a5e3a73ac9736d48f61b911dd4cda09dc55d7a313992b235ae2bb7c
|
File details
Details for the file apk_parse-1.0.0-py3-none-any.whl
.
File metadata
- Download URL: apk_parse-1.0.0-py3-none-any.whl
- Upload date:
- Size: 50.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
0518c891d8bb903e952a5b70de0d9fe5f478594e37bdb0826561ecc4d86fccfa
|
|
MD5 |
3acbffba3f59b8d1a2cfe5d9033b55f7
|
|
BLAKE2b-256 |
1e6e23b4ed8ff4eb832e1db9a6dc85aaa3c7cd95eff390f8e325b9a0fc5c606d
|