forked from georgiaw/Smartphone-Pentest-Framework
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbtinstall
executable file
·65 lines (41 loc) · 2.63 KB
/
btinstall
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#!/bin/sh
#
# This is an attempt to make an installer for Smartphone Pentest Framework
# This is ugly as shit but it works.. could be done in perl a lot better,
# will convert it one day. maybe. =)
# -loon aug 2012
#######################################################################
## Install needed packages
echo -e "$(tput setaf 1)\nInstalling mod_perl and expect for perl\n"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)#########################################\n"; echo "$(tput sgr0)"
apt-get -y install libapache2-mod-perl2 libexpect-perl;
mkdir code; cd code;
echo -e "$(tput setaf 1)\nNow cloning Smartphone Pentest Framework...\n "; echo "$(tput sgr0)"
sleep 5;
git clone https://github.com/georgiaw/Smartphone-Pentest-Framework.git;
echo -e "$(tput setaf 1)\nCloning has completed. Continuing Setup \n"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)Creating first time 'framework' database (empty)\n"; echo "$(tput sgr0)"
service mysql start;
mysqladmin -u root create framework -ptoor;
# add the following to /etc/apache2/sites-enabled/000-default
#
# Under main (<VirtualHost *:80>) add the handler for perl
# Under <Directory /var/www/> add ExecCGI to the Options list
echo -e "$(tput setaf 1)\nTweaking Apaches main config file to add perl Handler and ExecCGI .. \n"; echo "$(tput sgr0)"
sed -i "s/ServerAdmin .*/& \n AddHandler cgi-script .cgi .pl/" /etc/apache2/sites-enabled/000-default;
sed -i "s/Options Indexes FollowSymLinks.*/& ExecCGI/" /etc/apache2/sites-enabled/000-default;
echo -e "$(tput setaf 1)\nRestarting Apache... \n"; echo "$(tput sgr0)"
/etc/init.d/apache2 start
echo -e "$(tput setaf 1)\nApache has restarted...\n"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)\nCopying over the GUI framework to webroot...\n"; echo "$(tput sgr0)"
cp -r Smartphone-Pentest-Framework/frameworkgui /var/www/;
cd /var/www/frameworkgui;
chmod 777 * ;
echo -e "$(tput setaf 1)\n\nInstall of Smartphone Pentest Framework is complete!\n"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)You need to edit your config files to your liking in the following locations:\n"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)/var/www/frameworkgui/config and /root/code/Smartphone-Pentest-Framework/frameworkconsole/config\n"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)"
echo -e "$(tput setaf 1)Once config is setup you can either run ./framework.pl in the frameworkconsole directory,\n"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)Or you may open your browser to http://localhost/frameworkgui/menu.pl !\n"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)"; echo "$(tput sgr0)"
echo -e "$(tput setaf 1)This concludes the install.. enjoy!"; echo "$(tput sgr0)"