Advertisement
Guest User

Untitled

a guest
Apr 29th, 2016
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. # Start custom variables - Change this variables as you need
  2. ANDROID_VERSION=21.1.2
  3. SSH_SIGN="SHA1: A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1:A1"
  4. # End custom variables
  5.  
  6. # Start color variables -
  7. GREEN='\033[0;32m'
  8. RED='\033[0;31m'
  9. NC='\033[0m'
  10. # End color variables
  11.  
  12. printf "${GREEN}*****************\n"
  13. printf "Starting tests\n"
  14. printf "*****************${NC}\n"
  15.  
  16. DEBUG=`$ANDROID_HOME/build-tools/$ANDROID_VERSION/aapt dump badging $1 | grep "application-debuggable"`
  17.  
  18. if [ -z $DEBUG ]; then
  19. printf "${GREEN}** NO DEBUG **${NC}\n"
  20. else
  21. printf "${RED}** DEBUG **${NC}\n"
  22. echo $DEBUG
  23. fi
  24.  
  25. unzip -q $1 -d ./delete
  26. SIGNED=`keytool -printcert -file ./delete/META-INF/HEALTHKE.RSA | grep "$SSH_SIGN"`
  27. if [ $? -eq 0 ]; then
  28. if [ -n '$SIGNED' ]; then
  29. printf "${GREEN}** SIGNED!! **${NC}\n"
  30. echo $SIGNED
  31. fi
  32. else
  33. printf "${RED}** NO SIGNED **${NC}\n"
  34. echo $SIGNED
  35. fi
  36.  
  37. rm -rf ./delete
  38.  
  39. printf "${GREEN}*****************\n"
  40. printf "end tests \n"
  41. printf "*****************${NC}\n"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement