forked from dwisiswant0/apkleaks
-
Notifications
You must be signed in to change notification settings - Fork 1
/
apkleaks.py
executable file
·26 lines (23 loc) · 1.17 KB
/
apkleaks.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/usr/bin/env python3
from apkleaks.apkleaks import APKLeaks
from apkleaks.colors import clr
import argparse
import os
def header():
VERSION = open(os.path.dirname(os.path.realpath(__file__)) + "/VERSION", "r").read()
return (" _ ____ _ ___ _ \n / \\ | _ \\| |/ / | ___ __ _| | _____ \n / _ \\ | |_) | ' /| | / _ \\/ _` | |/ / __|\n / ___ \\| __/| . \\| |__| __/ (_| | <\\__ \\\n /_/ \\_\\_| |_|\\_\\_____\\___|\\__,_|_|\\_\\___/\n {}\n --\n Scanning APK file for URIs, endpoints & secrets\n (c) 2020-2021, dwisiswant0\n".format(VERSION))
def argument():
parser = argparse.ArgumentParser()
parser.add_argument("-f", "--file", help="APK file to scanning", type=str, required=True)
parser.add_argument("-o", "--output", help="Write to file results (NULL will be saved into random file)", type=str, required=False)
parser.add_argument("-p", "--pattern", help="Path to custom patterns JSON", type=str, required=False)
arg = parser.parse_args()
return arg
if __name__ == "__main__":
print(clr.HEADER)
print(clr.HEADER + header() + clr.ENDC)
args = argument()
init = APKLeaks(args)
apk = init.integrity()
init.decompile()
init.scanning()