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

Nokia n900 and Install script updates #3

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,12 @@ if [ "$?" -ne 0 ]; then echo "[!] Failed :("; exit 1; fi
echo "[+] Installing required packages..."
sleep 3

apt-get install -y python-pip gcc libxml2-dev libxslt-dev python2.7-dev mysql-server squid3 openvpn bind9 tshark python-mysqldb apache2 python-beaker python-flask python-jinja2 python-mysqldb python-sqlalchemy python-werkzeug
apt-get install -y build-essential python-pip gcc libxml2-dev libxslt-dev python2.7-dev mysql-server squid3 openvpn bind9 tshark python-mysqldb apache2 python-beaker python-flask python-jinja2 python-mysqldb python-sqlalchemy python-werkzeug
if [ "$?" -ne 0 ]; then echo "[!] Failed :("; exit 1; fi
if [ "$xplico" == "yes" ]; then
apt-get install -y xplico
fi
pip install lxml beautifulsoup requests PIL mitmproxy ipaddr publicsuffix twisted cryptacular Flask_SQLAlchemy
pip install lxml beautifulsoup requests==0.14.2 httplib2 PIL mitmproxy ipaddr publicsuffix twisted cryptacular Flask_SQLAlchemy
if [ "$?" -ne 0 ]; then echo "[!] Failed :("; exit 1; fi

echo "[+] Done installing packages. Onward and upward!"
Expand Down Expand Up @@ -292,6 +292,7 @@ EOL
cgi_dir=$(head -1 /dev/urandom | tr -dc _A-Z-a-z-0-9 | head -c${1:-132}|md5sum | sed 's/ .*//')
mkdir -p /usr/lib/cgi-bin/$cgi_dir
ln -s $home_dir/snoopy/server/transforms/ /usr/lib/cgi-bin/$cgi_dir/
ln -s $home_dir/snoopy/server/bin/wigle_api_lite.py $home_dir/snoopy/server/transforms/wigle_api_lite.py

web_dir=$(head -1 /dev/urandom | tr -dc _A-Z-a-z-0-9 | head -c${1:-132}|md5sum | sed 's/ .*//')
echo "http://$server_ip/$web_dir/" > $home_dir/snoopy/server/setup/webroot_guid.txt
Expand Down
2 changes: 1 addition & 1 deletion snoopy/client/setup/snoopy.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Name=Snoopy
Comment=Snoopy
Terminal=true
Icon=snoopy
Exec=osso-xterm -e "sudo /root/snoopy/bin/snoopy.sh"
Exec=osso-xterm -e "sudo bash /root/snoopy/bin/snoopy.sh"
X-Window-Icon=snoopy
X-HildonDesk-ShowInToolbar=true
X-Osso-Type=application/x-executable
Expand Down
3 changes: 3 additions & 0 deletions snoopy/client/setup_n900.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ sed -i "s,^Exec=.*,Exec=osso-xterm -e \"sudo $sd/snoopy.sh\"," ./setup/snoopy.de
cp ./setup/snoopy.desktop /usr/share/applications/hildon/
cp ./setup/snoopy.png /opt/usr/share/pixmaps/

# Make all desktop icons executable - fix for snoopy.desktop
chmod -R 777 /usr/share/applications/hildon/

#NB Don't manually update /etc/sudoers on N900
echo "user ALL = NOPASSWD: $sd/snoopy.sh" > /etc/sudoers.d/snoopy.sudoers
update-sudoers
Expand Down