Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

APIMonitor Not working for Android Play Store Apps #20

Open
prashantmaurya opened this issue Apr 11, 2018 · 0 comments
Open

APIMonitor Not working for Android Play Store Apps #20

prashantmaurya opened this issue Apr 11, 2018 · 0 comments

Comments

@prashantmaurya
Copy link

Tried apps like hike, byjus and khan academy from playstore. Repackaged apk is generated but this new apk gives error while running on emulator. Error: Unfortunately app stopped working.
I am running this script in APIMonitor to automate repackaging, installing and collecting logs.
PS: This works for toy apps.
#!/bin/bash
if [ -z "$1" ]
then
echo "./run.sh apk-path"
exit 1
fi
#getting package name from manifest file
pac_name=$(java -jar APKParser.jar $1|grep -o "package[[:space:]]"='[[:space:]][^ ]+'|cut -d "=" -f2|sed -e 's/[[:space:]]//'|sed 's/.///g'|sed 's/"/L/'|sed 's/"//')
#echo $1 $pac_name
./apimonitor.py $1 $pac_name
dir=$(dirname "$1")
f=$(basename "$1")
f_name="${f%.
}"
echo "directory"$dir
echo "file"$f
echo "f_name"$f_name
echo "Installing Modifying apk"
echo $dir"/"$f_name"_name.apk"
adb install -r $dir"/"$f_name"_new.apk"
echo "apk installed"
adb logcat -c
echo "collecting log >logs/"$f_name".log"
adb logcat -s DroidBox>"logs/"$f_name".log"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant