-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun_with_antmonitor.sh
More file actions
executable file
·27 lines (23 loc) · 1.11 KB
/
run_with_antmonitor.sh
File metadata and controls
executable file
·27 lines (23 loc) · 1.11 KB
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
27
#!/bin/bash
if [ "$#" -ne 3 ]; then
echo "Usage: $0 <device_name> <package_name> <ssl_offset>"
exit 1
fi
DEVICE_NAME=$1
PACKAGE_NAME=$2
SSL_OFFSET=$3
# Make autovr
make clean
make node_modules
(cd ./ts && make index.out.js)
adb -s $DEVICE_NAME shell am start -n \"edu.uci.calit2.anteatermo.dev/edu.uci.calit2.anteater.client.android.activity.AntMonitorLauncherActivity\" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER
sleep 2
adb -s "$DEVICE_NAME" shell am start-activity -n edu.uci.calit2.anteatermo.dev/edu.uci.calit2.anteater.client.android.activity.VpnStarterActivity --ez edu.uci.calit2.anteater.EXTRA_DISCONNECT false
sleep 2
python3 autovr.py --device $DEVICE_NAME --package $PACKAGE_NAME --delay_scenes 5000 --ssl-offset $SSL_OFFSET --rooted
sleep 2
adb -s "$DEVICE_NAME" shell am start-activity -n edu.uci.calit2.anteatermo.dev/edu.uci.calit2.anteater.client.android.activity.VpnStarterActivity --ez edu.uci.calit2.anteater.EXTRA_DISCONNECT true
sleep 2
./get_pcaps.sh -s $DEVICE_NAME -d ./results/$PACKAGE_NAME
adb -s "$DEVICE_NAME" shell rm -rf /sdcard/antmonitor/*
echo "FINISHED $PACKAGE_NAME"