
안드로이드 앱 침투 테스트의 지루한 작업을 자동화하는 도구입니다. APKTool 및 Dex2Jar를 사용합니다.
v2.0.0
Android 앱 침투 테스트의 단순 작업을 자동화하는 도구입니다.
현재 이 도구는 다음 기능을 제공합니다:
/data/app//data/data작업 모드를 연결하여 자신만의 사용자 정의 워크플로를 자동화할 수 있습니다.
예시:
humoud@komputer:~/Documents/dev/apkSneeze# python3 apkSneeze.py -adb_over_wifi -device_ip 192.168.1.114 -apk_dl -pkg_name com.dev.test.example -apk
===========================================================
___ ______ _ __ _____ _ _ _____ _____ ______ _____
/ _ \ | ___ \ | / / / ___| \ | || ___| ___|___ /| ___|
/ /_\ \| |_/ / |/ / \ `--.| \| || |__ | |__ / / | |__
| _ || __/| \ `--. \ . ` || __|| __| / / | __|
| | | || | | |\ \ /\__/ / |\ || |___| |___./ /___| |___
\_| |_/\_| \_| \_/ \____/\_| \_/\____/\____/\_____/\____/
v2.0.0
============================================================
Using Settings:
+> Process apk file: True
> Target apk file name: sneezed.apk
+> Setup ADB over WiFi: True
+> Download apk file: True
+> Download app data directory: False
>> Settings shared for adb setup and apk\data download:
>> ADBKey file location: /home/humoud/.android/adbkey
>> Test device IP address: 192.168.1.114
>> Test device port: 5555
>> Target package name: com.dev.test.example
Confirm? [y/n] y
Killing adb server
Listing attached devices
* daemon not running; starting now at tcp:5037
* daemon started successfully
> List of devices attached
> xxxxx device
Setting the device to listen on port 5555
> restarting in TCP mode port: 5555
Connecting to the device...
> connected to 192.168.1.114:5555
You can test if everything is working by seeing if you can get a shell: adb -s 192.168.1.114:5555 shell
<*> Copying APK file to /data/local/tmp/apkSneeze/base.apk (mobile device)...
<*> Downloading APK file to sneezed.apk...
<*> Download done, check sneezed.apk
<*> Deleting APK file from /data/local/tmp/apkSneeze/base.apk (mobile device)...
[0] Processing apk file...
[1] Decompiling the APK file using APKTOOL...
> I: Using Apktool 2.4.0-dirty on sneezed.apk
> I: Loading resource table...
> I: Decoding AndroidManifest.xml with resources...
> I: Loading resource table from file: /home/humoud/.local/share/apktool/framework/1.apk
> I: Regular manifest package...
> I: Decoding file-resources...
> I: Decoding values */* XMLs...
> I: Baksmaling classes.dex...
> I: Baksmaling classes2.dex...
> I: Baksmaling classes3.dex...
> I: Copying assets and libs...
> I: Copying unknown files...
> I: Copying original files...
[2] Converting APK file to JAR file using dex2jar...
dex2jar sneezed.apk -> ./sneezed-dex2jar.jar
[3] Searching for interesting strings(outputing to file interesting_strings_sneezed.txt)...
[3] >> Going through RegEx list...
[3] >> Going through strings list...
Hits: 20853
Done!
요구 사항:
python3 -m pip install -r requirements.txt
참고: 이 도구는 Kali Linux에서 테스트 및 개발되었으며, apktool과 dex2jar가 설치되어 있습니다.
apk 파일을 처리하려면 (디컴파일, Jar 변환, 흥미로운 문자열 검색):
python3 apkSneeze.py -apk -apk_name test.apk
WiFi를 통해 ADB를 설정하려면 장치가 USB로 연결되어 있어야 합니다:
python3 apkSneeze.py -adb_over_wifi -device_ip 192.168.1.114
사용자 정의 포트 설정:
python3 apkSneeze.py -adb_over_wifi -device_ip 192.168.1.114 -device_port 10111
테스트 장치에서 apk 파일을 다운로드하려면 (루트 권한 필요):
python3 apkSneeze.py -apk_dl -pkg_name com.dev.test -device_ip 192.168.1.114
5555가 아닌 다른 포트를 사용하는 경우 (사용자 정의 포트):
python3 apkSneeze.py -apk_dl -pkg_name com.dev.test -device_ip 192.168.1.114 -device_port 10111
테스트 장치에서 앱 데이터 디렉토리(/data/data)를 다운로드하려면 (루트 권한 필요):
python3 apkSneeze.py -data_dir_dl -device_ip 192.168.1.114 -pkg_name com.test.target.app
작업 모드를 연결할 수 있습니다. 예: wifi를 통해 adb 설정, apk 파일 다운로드, 마지막으로 다운로드한 apk 파일 처리.
python3 apkSneeze.py -adb_over_wifi -device_ip 192.168.1.114 -apk_dl -pkg_name com.dev.test.example -apk
도구의 기본값은 다음과 같습니다:
적절한 매개변수를 지정하여 모두 변경할 수 있습니다.
usage: apkSneeze.py [-h] [-apk] [-apk_name APK_NAME] [-apk_dl] [-data_dir_dl]
[-pkg_name PKG_NAME] [-device_ip DEVICE_IP]
[-device_port DEVICE_PORT] [-adbkey_file ADBKEY_FILE]
[-adb_over_wifi]
optional arguments:
-h, --help show this help message and exit
-apk Process an apk file.
-apk_name APK_NAME Name of the apk file to process.
-apk_dl Download apk file from device. Requires params:
pkg_name, device_ip, device_port, adbkey_file.
-data_dir_dl Download app data directory from device. Requires
params: pkg_name, device_ip, device_port, adbkey_file.
-pkg_name PKG_NAME Application Package Name (ex: com.dev.app). This is
required if you wish to download the apk file.
-device_ip DEVICE_IP IP Address of the testing device.
-device_port DEVICE_PORT
Port number the testing device is listening on.
-adbkey_file ADBKEY_FILE
Location of the adbkey file (ex:
/home/user/.android/adbkey).
-adb_over_wifi Setup adb over wifi automatically. You must provide
the IP address of the device and have it connected via
USB. You can set a custom port using param
device_port.
APKSneeze를 사전 상호 동의 없이 대상을 공격하는 데 사용하는 것은 불법입니다. 모든 해당 지역, 주 및 연방 법률을 준수하는 것은 최종 사용자의 책임입니다. 개발자는 어떠한 책임도 지지 않으며, 이 프로그램으로 인한 오용이나 손해에 대해 책임을 지지 않습니다.