Editing Maemo PirateBox

Warning: You are not logged in. Your IP address will be recorded in this page's edit history.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 1: Line 1:
-
This manual explains how to turn your [[Nokia N810|N810]] or [[Nokia N900|N900]] Maemo device into a PirateBox.
+
This manual explains how to turn your N810 or N900 Maemo device into a PirateBox.
-
[[Image:Screenshot_lola_rennt.png|350px|thumb|right| n810 connected to n900 piratebox]]
+
-
In case you don't know what is piratebox go to [http://wiki.daviddarts.com/PirateBox David Darts page] or [http://www.thepiratebox.net/ here]. Also, there are script called [https://github.com/cr/mkPirateBox mkPirateBox] for hardware router devices.
+
-
I also found [http://talk.maemo.org/member.php?u=51085 Plissken]'s [http://forum.daviddarts.com/read.php?2,57 implementation] for n900, however it requires custom kernel. This solution is much simpler and works with maemo default kernels. It does not support file uploading, and thus is not a "canonical" piratebox. However, it allows to create your own web page with links, and distribute them everywhere you go.
+
 +
In case you don't know what is piratebox go to [http://wiki.daviddarts.com/PirateBox David Darts page] or [http://www.thepiratebox.net/ here]. Also, there are script called [https://github.com/cr/mkPirateBox mkPirateBox] for hardware router devices.
 +
I also found David's [http://forum.daviddarts.com/read.php?2,57 implementation] for n900, however it requires custom kernel. This solution is much simpler and works with maemo default kernels.
==Install web server==
==Install web server==
 +
Basicly what we need is a web server and wireless-tools.
-
Basically what we need is a web server and wireless-tools:
+
<pre>
 +
apt-get install wireless-tools
 +
</pre>
-
apt-get install lighttpd wireless-tools
+
<pre>
 +
apt-get install lighttpd
 +
</pre>
-
I also edited the server's config file:
+
I also edited the server's config file  
-
vi /etc/lighttpd.conf
+
<pre>
 +
vi /etc/lighttpd.conf
 +
</pre>
 +
and changed document root directory to /media/mmc1/www
 +
<pre>
 +
server.document-root = "/media/mmc1/www/"
 +
</pre>
-
and changed document root directory to <code>/media/mmc1/www</code>
+
put your website data there and start http server if it's not started.
-
server.document-root = "/media/mmc1/www/"
+
<pre>/etc/init.d/lighttpd restart</pre>
-
 
+
-
put your website data there and start http server if it's not started:
+
-
 
+
-
/etc/init.d/lighttpd restart
+
==Start access point==
==Start access point==
-
So, dnsmasq is available in Maemo out of the box. It is a DNs and DHCP server. [[root access|As root]], start the following script:
+
So, dnsmasq is available in maemo out of the box. It is a dns and dhcp server.
 +
As a root, start the following script:
-
<source lang="bash">
+
<pre>
#!/bin/bash
#!/bin/bash
set -x
set -x
Line 40: Line 47:
ifconfig $IFACE down
ifconfig $IFACE down
sleep $INT  
sleep $INT  
 +
iwconfig $IFACE mode ad-hoc
 +
sleep $INT
ifconfig $IFACE up  
ifconfig $IFACE up  
-
sleep $INT
 
-
iwconfig $IFACE mode ad-hoc
 
sleep $INT
sleep $INT
iwconfig $IFACE essid $ESSID
iwconfig $IFACE essid $ESSID
-
sleep $INT
 
ifconfig $IFACE $ADDR netmask $NETMASK up
ifconfig $IFACE $ADDR netmask $NETMASK up
-
sleep $INT
 
/usr/sbin/dnsmasq -i $IFACE -a $ADDR -I lo -z -d \
/usr/sbin/dnsmasq -i $IFACE -a $ADDR -I lo -z -d \
Line 54: Line 59:
  --address=/#/$ADDR \
  --address=/#/$ADDR \
  --no-resolv
  --no-resolv
-
</source>
+
</pre>
-
Here <pre>--address=/#/$ADDR</pre> option is used in order to forward all the requests (i. e. to google or facebook) to the local web server.
+
-
 
+
-
This is it, now anybody can connect to your access point, type any address in the browser's address bar, and see your personal PirateBox on your N900 or N810 running under maemo
+
-
 
+
-
''I have written some comments and additions here: http://wiki.maemo.org/User:Rolfok#PirateBox''
+
-
[[Category:Software]]
+
This is it, now anybody can connect to your access point and your personal PirateBox on your n900 or n810 running under maemo

Learn more about Contributing to the wiki.


Please note that all contributions to maemo.org wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see maemo.org wiki:Copyrights for details). Do not submit copyrighted work without permission!


Cancel | Editing help (opens in new window)