Updating mesh documentation
This commit is contained in:
parent
9b6721261d
commit
879148c8e6
|
@ -7,7 +7,7 @@
|
|||
#+BEGIN_CENTER
|
||||
[[./images/logo.png]]
|
||||
#+END_CENTER
|
||||
| [[file:index.html][Home]] | [[Preparation for the Beaglebone Black]] | [[Checklist]] | [[Interactive Setup]] | [[Non-Interactive Setup]] | [[Post-Setup]] | [[Keydrives]] | [[On Client Machines]] |
|
||||
| [[file:index.html][Home]] | [[Preparation for the Beaglebone Black]] | [[Checklist]] | [[./mesh.html][Mesh network]] | [[Interactive Setup]] | [[Non-Interactive Setup]] | [[Post-Setup]] | [[Keydrives]] | [[On Client Machines]] |
|
||||
|
||||
|
||||
* Preparation for the Beaglebone Black
|
||||
|
@ -56,7 +56,8 @@ Before running the freedombone command you will need a few things.
|
|||
* It is possible to forward ports from the internet router to the system
|
||||
* If you want to set up a social network or microblog then you will need SSL certificates corresponding to those domains
|
||||
* Have ssh access to the system
|
||||
|
||||
* Mesh network
|
||||
If you are installing one of the mesh network variants then see [[./mesh.html][these instructions]] for details.
|
||||
* Interactive Setup
|
||||
The interactive server configuration setup is recommended for most users. On the system where freedombone is to be installed create a configuration file.
|
||||
|
||||
|
|
132
doc/EN/mesh.org
132
doc/EN/mesh.org
|
@ -8,7 +8,7 @@
|
|||
[[./images/logo.png]]
|
||||
#+END_CENTER
|
||||
|
||||
| [[What is a mesh network?]] | [[The Freedombone Mesh]] | [[Installation]] |
|
||||
| [[What is a mesh network?]] | [[The Freedombone Mesh]] | [[Installation]] | [[Wifi adaptors]] | [[Using the mesh]] |
|
||||
|
||||
* What is a mesh network?
|
||||
The internet as it currently exists is mostly organised according to a client/server model. Servers run the web services and store the data and clients are the laptops, desktops and other devices accessing the servers. In a mesh network there isn't any clear division between clients and servers. The computers on a mesh network are known as "peers" and they can perform the functions of both clients and servers. Commonly this is also known as a "peer to peer" network.
|
||||
|
@ -25,17 +25,135 @@ Example use cases would be:
|
|||
* Camp sites
|
||||
* War zones
|
||||
* Scientific expeditions to remote areas
|
||||
* Onboard ships
|
||||
* Underground (mines/caves)
|
||||
* Protests
|
||||
* Onboard smaller ships without satellite internet, captain/crew communications
|
||||
* Underground (mines or caves)
|
||||
* Protests / Occupations of buildings
|
||||
* Eventually in space for manned missions to other planets, moons or asteroids
|
||||
|
||||
* The Freedombone Mesh
|
||||
The Freedombone mesh is offline - in the sense of not being part of the larger internet - and consists of a set of computers with the system installed communicating wirelessly using ordinary wifi. Peers can enter or leave the network and it will adjust automatically. All communications between peers is end-to-end encrypted, so although it's easy to join the network it's not easy to passively evesdrop.
|
||||
The Freedombone mesh is offline - in the sense of not being part of the larger internet - and consists of a set of computers with the software installed communicating wirelessly using ordinary wifi. Peers can enter or leave the network and it will adjust automatically. All communications between peers is end-to-end encrypted, so although it's easy to join the network it's not easy to passively evesdrop.
|
||||
* Installation
|
||||
** Two types of system
|
||||
Installation is split into two categories, /routers/ and /user devices/.
|
||||
|
||||
A router is a computer which is dedicated to moving network traffic and building out the mesh infrastructure. It's not primarily intended to have a user interface. Hardware such as the Beaglebone Black is ideal for this, because it's small, inexpensive and doesn't consume much electrical power and so can be fitted in any location where an electricity supply is available. Small computers can also be battery operated or solar powered so that the mesh need not be statically sited. They could be included in a backpack for camping, fitted within moving vehicles, or on protest placards to help provide a local and transient communications system.
|
||||
A router is a computer which is dedicated to moving network traffic and building out the mesh infrastructure. It's not primarily intended to have a user interface. Hardware such as the Beaglebone Black is ideal for this, because it's small, inexpensive and doesn't consume much electrical power and so can be fitted in any location where an electricity supply is available.
|
||||
|
||||
User devices are the computers with which you would typically access the internet - laptops, desktop machines, netbooks or any other device which can run a Debian-based distro with a working wifi connection.
|
||||
Small computers acting as mesh routers can also be battery operated or solar powered so that the network need not be statically sited. They could be included in a backpack for camping, fitted within moving vehicles, strapped to protest placards or attached to large tethered helium balloons (like weather balloons) to help provide a local and transient communications system.
|
||||
|
||||
/User devices/ are the computers with which you would typically access the internet - laptops, desktop machines, netbooks or any other device which can run a Debian-based distro (eg. Ubuntu) with a working wifi connection.
|
||||
** Installing on routers
|
||||
Whatever system you're going to use as a mesh router should have a new Debian Jessie install on it. It's advisable that this be a new install so that there is no existing software on the system which could confuse the mesh install process. Connect your system to your internet router with an ethernet cable, then ssh into it and type:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
su
|
||||
apt-get update
|
||||
apt-get install git build-essential dialog
|
||||
git clone https://github.com/bashrc/freedombone
|
||||
cd freedombone
|
||||
make install
|
||||
#+END_SRC
|
||||
|
||||
At this point if you are using a system or dongle with an Atheros AR9271 wifi chipset then you may want to install some pre-compiled firmware (you can compile it from source, but it takes a long time - especially on the Beaglebone Black). If you need to do that then see the wifi adaptor notes below.
|
||||
|
||||
Then to begin the install:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
freedombone menuconfig
|
||||
#+END_SRC
|
||||
|
||||
Select the "/mesh (router)/" install variant, give an ESSID or just hit enter for the default. If discression is important then use an ESSID similar to those already in the area. The ESSID must be the same on every mesh peer. Assign this mesh peer a name. In order to avoid confusions it's important that the name should be unique on the network and contain no spaces. So maybe a word followed by some numbers, or the name of the place where the router will be installed.
|
||||
|
||||
If you're installing on a Beaglebone Black then after a while the system will reboot and you will need to ssh in again and run:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
cd freedombone
|
||||
freedombone -c freedombone.cfg
|
||||
#+END_SRC
|
||||
|
||||
The reboot is needed in order to enable zram and the hardware random number generator.
|
||||
** Installing on user devices
|
||||
Typically on a laptop with a Debian-based distro installed, open a terminal and type:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
sudo apt-get update
|
||||
sudo apt-get install git build-essential dialog
|
||||
git clone https://github.com/bashrc/freedombone
|
||||
cd freedombone
|
||||
sudo make install
|
||||
freedombone menuconfig
|
||||
#+END_SRC
|
||||
|
||||
Select the "/mesh (user device)/" variant and set the same ESSID as you did for the routers, or just hit enter for the default.
|
||||
|
||||
An important point is that on older Debian-based systems, such as Ubuntu 14.04 or Trisquel 7, you may need to install a more recent version of /batctl/. An example is as follows.
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
sudo apt-get remove --purge batctl
|
||||
wget http://mirrors.kernel.org/ubuntu/pool/universe/b/batctl/batctl_2014.1.0-2_amd64.deb
|
||||
sudo dpkg -i batctl_2014.1.0-2_amd64.deb
|
||||
#+END_SRC
|
||||
* Wifi adaptors
|
||||
There are a small number of wifi adaptors which are compatible with a fully free software stack.
|
||||
** Atheros AR9271
|
||||
To install the firmware for this:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
cd freedombone/drivers
|
||||
sha256sum ath9k_htc_driver_bbb.tar.gz
|
||||
7eb9324681f03c7630ed01e490ea447dfbd96c9b5389e45b64e4646d1be16ff1
|
||||
tar -xvzf ath9k_htc_driver_bbb.tar.gz
|
||||
mv *.fw /lib/firmware
|
||||
cd ..
|
||||
#+END_SRC
|
||||
* Using the mesh
|
||||
** Switching from internet to mesh mode
|
||||
To join the mesh network open a terminal and type:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
meshweb
|
||||
#+END_SRC
|
||||
|
||||
If you want to have your system as a permanent mesh peer then you could add that command to your startup applications so that it activates whenever the computer starts up.
|
||||
|
||||
A web page should appear in your browser, which then allows you to access communication services on the mesh. These pages should update automatically, so that if peers enter or leave the network the lists will change accordingly.
|
||||
** Chat
|
||||
If you have a Tox client installed on your system then you can use that to communicate with other mesh peers. A limitation is that if peers change you may need to quit the application and restart it in order to receive the updated list of DHTnodes. The [[https://github.com/Tox/toxic][Toxic]] client is installed by default, but you may also want to install [[https://github.com/tux3/qTox][qTox]] or [[http://utox.org][uTox]] for a more conventional-looking user experience.
|
||||
|
||||
You can obtain Tox IDs for users on the network via the initial web page.
|
||||
|
||||
To launch the [[https://github.com/Tox/toxic][Toxic client]] in a terminal type:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
toxic
|
||||
#+END_SRC
|
||||
|
||||
The first time you will be asked whether you wish to encrypt the data file used for your settings. Select "no" for this, otherwise the system will not be able to obtain your public key and broadcast it to other peers in the network. Even if you select "yes" the system will still be usable, but it will not be so easy for other peers on the network to find you unless you have previously exchanged your Tox ID via some out-of-band method.
|
||||
|
||||
Then to add a new friend:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
/nick mynickname
|
||||
/add <friend Tox ID>
|
||||
#+END_SRC
|
||||
|
||||
Your friend will need to approve the request, and then you can chat via text or voice using /CTRL-o/ and /CTRL-p/ to switch between screens and cursor keys plus Enter to select users.
|
||||
|
||||
A note for the security-conscious is that broadcasting Tox IDs via the network (using Avahi) is convenient but not highly secure. An adversary could maybe join the network and create decoy peers to try to disrupt the communications and have messages going to the wrong places. For the best security exchange Tox IDs in advance by some method other than looking them up from the initial mesh web page.
|
||||
** Blogging
|
||||
The Freedombone mesh uses a fully decentralized blogging system called [[https://github.com/HelloZeroNet/ZeroBlog][ZeroBlog]]. It behaves rather like other peer-to-peer file sharing systems in that if you are reading the blog of another user you are also simultaneously seeding it to other peers (acting as both a client and a server). This allows the system to scale well, while also being robust to any peer failing or leaving the network.
|
||||
|
||||
All blogs on the mesh are public, so any user joining the mesh can read any other blog. Network traffic is encrypted between peers, so passive snooping will be hard, and also the integrity of data is checked via certificates so that you can be reasonably confident that nefarious content has not been added or removed from the data stream while in transit through the network.
|
||||
|
||||
This type of content creation and delivery provides a good template for what the conventional internet should ultimately be like if it is to be robust, trustworthy and resistant to censorship or damage.
|
||||
|
||||
To add a new blog entry click the /new post/ button, edit the title and content (clicking /save/ at the bottom of the screen after each). Then when you are done click on the /publish/ button at the bottom of the screen. And that's all there is to it.
|
||||
** Other services
|
||||
It is hoped that a decentralized forum will be added, but this is not yet complete. In the mean time a substitute is to use the Tox group chat feature.
|
||||
** Turing off the mesh
|
||||
If you wish to return to the internet then open a terminal and type:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
sudo batman stop
|
||||
#+END_SRC
|
||||
|
||||
After a few seconds your usual internet wifi connection should be re-established.
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<title></title>
|
||||
<!-- 2015-07-11 Sat 12:37 -->
|
||||
<!-- 2015-09-05 Sat 14:16 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="generator" content="Org-mode" />
|
||||
<meta name="author" content="Bob Mottram" />
|
||||
|
@ -179,6 +179,8 @@ for the JavaScript code in this tag.
|
|||
|
||||
<col class="org-left" />
|
||||
|
||||
<col class="org-left" />
|
||||
|
||||
<col class="org-left" />
|
||||
</colgroup>
|
||||
<tbody>
|
||||
|
@ -186,6 +188,7 @@ for the JavaScript code in this tag.
|
|||
<td class="org-left"><a href="index.html">Home</a></td>
|
||||
<td class="org-left"><a href="#orgheadline1">Preparation for the Beaglebone Black</a></td>
|
||||
<td class="org-left"><a href="#orgheadline2">Checklist</a></td>
|
||||
<td class="org-left"><a href="./mesh.html">Mesh network</a></td>
|
||||
<td class="org-left"><a href="#orgheadline3">Interactive Setup</a></td>
|
||||
<td class="org-left"><a href="#orgheadline4">Non-Interactive Setup</a></td>
|
||||
<td class="org-left"><a href="#orgheadline5">Post-Setup</a></td>
|
||||
|
@ -274,7 +277,14 @@ Before running the freedombone command you will need a few things.
|
|||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgheadline8" class="outline-2">
|
||||
<h2 id="orgheadline8">Mesh network</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline8">
|
||||
<p>
|
||||
If you are installing one of the mesh network variants then see <a href="./mesh.html">these instructions</a> for details.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline3" class="outline-2">
|
||||
<h2 id="orgheadline3">Interactive Setup</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline3">
|
||||
|
@ -395,33 +405,33 @@ Also see the manpage for additional options which can be used instead of a confi
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgheadline8" class="outline-2">
|
||||
<h2 id="orgheadline8">Social Key Management</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline8">
|
||||
<div id="outline-container-orgheadline9" class="outline-2">
|
||||
<h2 id="orgheadline9">Social Key Management</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline9">
|
||||
<p>
|
||||
If you are using the interactive installer then you will be aked if you wish to import GPG keys. If you don't already possess GPG keys then just select "Ok" and they will be generated during the install. If you do already have GPG keys then there are a few possibilities
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgheadline9" class="outline-3">
|
||||
<h3 id="orgheadline9">You have the gnupg keyring on an encrypted USB drive</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline9">
|
||||
<div id="outline-container-orgheadline10" class="outline-3">
|
||||
<h3 id="orgheadline10">You have the gnupg keyring on an encrypted USB drive</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline10">
|
||||
<p>
|
||||
If you previously made a master keydrive containing the full keyring (the .gnupg directory). This is the most straightforward case, but not as secure as splitting the key into fragments.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline10" class="outline-3">
|
||||
<h3 id="orgheadline10">You have a number of key fragments on USB drives retrieved from friends</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline10">
|
||||
<div id="outline-container-orgheadline11" class="outline-3">
|
||||
<h3 id="orgheadline11">You have a number of key fragments on USB drives retrieved from friends</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline11">
|
||||
<p>
|
||||
If you previously made some USB drives containing key fragments then retrieve them from your friends and plug them in one after the other. After the last drive has been read then remove it and just select "Ok". The system will then try to reconstruct the key. For this to work you will need to have previously made three or more <a href="#orgheadline6">Keydrives</a>.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline11" class="outline-3">
|
||||
<h3 id="orgheadline11">You can specify some ssh login details for friends servers containing key fragments</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline11">
|
||||
<div id="outline-container-orgheadline12" class="outline-3">
|
||||
<h3 id="orgheadline12">You can specify some ssh login details for friends servers containing key fragments</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline12">
|
||||
<p>
|
||||
Enter three or more sets of login details and the installer will try to retrieve key fragments and then assemble them into the full key. This only works if you previously were using remote backups and had social key management enabled.
|
||||
</p>
|
||||
|
@ -564,9 +574,9 @@ On your internet router, typically under firewall settings, open the following p
|
|||
After installing for the first time it's a good idea to create some keydrives. These will store your gpg key so that if all else fails you will still be able to restore from backup. There are two ways to do this:
|
||||
</p>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline12" class="outline-3">
|
||||
<h3 id="orgheadline12">Master Keydrive</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline12">
|
||||
<div id="outline-container-orgheadline13" class="outline-3">
|
||||
<h3 id="orgheadline13">Master Keydrive</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline13">
|
||||
<p>
|
||||
This is the traditional security model in which you carry your full keyring on an encrypted USB drive. To make a master keydrive first format a USB drive as a LUKS encrypted drive. In Ubuntu this can be <a href="https://help.ubuntu.com/community/EncryptedFilesystemsOnRemovableStorage">done from the <i>Disk Utility</i> application</a>. Then plug it into the Freedombone system, then from your local machine run:
|
||||
</p>
|
||||
|
@ -586,9 +596,9 @@ If you are on a Beaglebone Black then use <i>sda</i> rather than <i>sdb</i> for
|
|||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline13" class="outline-3">
|
||||
<h3 id="orgheadline13">Fragment keydrives</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline13">
|
||||
<div id="outline-container-orgheadline14" class="outline-3">
|
||||
<h3 id="orgheadline14">Fragment keydrives</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline14">
|
||||
<p>
|
||||
This breaks your GPG key into a number of fragments and randomly selects one to add to the USB drive. First format a USB drive as a LUKS encrypted drive. In Ubuntu this <a href="https://help.ubuntu.com/community/EncryptedFilesystemsOnRemovableStorage">can be done from the <i>Disk Utility</i> application</a>. Plug it into the Freedombone system then from your local machine run the following commands:
|
||||
</p>
|
||||
|
|
|
@ -0,0 +1,525 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<title></title>
|
||||
<!-- 2015-09-05 Sat 14:12 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="generator" content="Org-mode" />
|
||||
<meta name="author" content="Bob Mottram" />
|
||||
<meta name="description" content="Turn the Beaglebone Black into a personal communications server"
|
||||
/>
|
||||
<meta name="keywords" content="freedombox, debian, beaglebone, red matrix, email, web server, home server, internet, censorship, surveillance, social network, irc, jabber" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<style type="text/css">
|
||||
<!--/*--><![CDATA[/*><!--*/
|
||||
.title { text-align: center;
|
||||
margin-bottom: .2em; }
|
||||
.subtitle { text-align: center;
|
||||
font-size: medium;
|
||||
font-weight: bold;
|
||||
margin-top:0; }
|
||||
.todo { font-family: monospace; color: red; }
|
||||
.done { font-family: monospace; color: green; }
|
||||
.priority { font-family: monospace; color: orange; }
|
||||
.tag { background-color: #eee; font-family: monospace;
|
||||
padding: 2px; font-size: 80%; font-weight: normal; }
|
||||
.timestamp { color: #bebebe; }
|
||||
.timestamp-kwd { color: #5f9ea0; }
|
||||
.org-right { margin-left: auto; margin-right: 0px; text-align: right; }
|
||||
.org-left { margin-left: 0px; margin-right: auto; text-align: left; }
|
||||
.org-center { margin-left: auto; margin-right: auto; text-align: center; }
|
||||
.underline { text-decoration: underline; }
|
||||
#postamble p, #preamble p { font-size: 90%; margin: .2em; }
|
||||
p.verse { margin-left: 3%; }
|
||||
pre {
|
||||
border: 1px solid #ccc;
|
||||
box-shadow: 3px 3px 3px #eee;
|
||||
padding: 8pt;
|
||||
font-family: monospace;
|
||||
overflow: auto;
|
||||
margin: 1.2em;
|
||||
}
|
||||
pre.src {
|
||||
position: relative;
|
||||
overflow: visible;
|
||||
padding-top: 1.2em;
|
||||
}
|
||||
pre.src:before {
|
||||
display: none;
|
||||
position: absolute;
|
||||
background-color: white;
|
||||
top: -10px;
|
||||
right: 10px;
|
||||
padding: 3px;
|
||||
border: 1px solid black;
|
||||
}
|
||||
pre.src:hover:before { display: inline;}
|
||||
pre.src-sh:before { content: 'sh'; }
|
||||
pre.src-bash:before { content: 'sh'; }
|
||||
pre.src-emacs-lisp:before { content: 'Emacs Lisp'; }
|
||||
pre.src-R:before { content: 'R'; }
|
||||
pre.src-perl:before { content: 'Perl'; }
|
||||
pre.src-java:before { content: 'Java'; }
|
||||
pre.src-sql:before { content: 'SQL'; }
|
||||
|
||||
table { border-collapse:collapse; }
|
||||
caption.t-above { caption-side: top; }
|
||||
caption.t-bottom { caption-side: bottom; }
|
||||
td, th { vertical-align:top; }
|
||||
th.org-right { text-align: center; }
|
||||
th.org-left { text-align: center; }
|
||||
th.org-center { text-align: center; }
|
||||
td.org-right { text-align: right; }
|
||||
td.org-left { text-align: left; }
|
||||
td.org-center { text-align: center; }
|
||||
dt { font-weight: bold; }
|
||||
.footpara:nth-child(2) { display: inline; }
|
||||
.footpara { display: block; }
|
||||
.footdef { margin-bottom: 1em; }
|
||||
.figure { padding: 1em; }
|
||||
.figure p { text-align: center; }
|
||||
.inlinetask {
|
||||
padding: 10px;
|
||||
border: 2px solid gray;
|
||||
margin: 10px;
|
||||
background: #ffffcc;
|
||||
}
|
||||
#org-div-home-and-up
|
||||
{ text-align: right; font-size: 70%; white-space: nowrap; }
|
||||
textarea { overflow-x: auto; }
|
||||
.linenr { font-size: smaller }
|
||||
.code-highlighted { background-color: #ffff00; }
|
||||
.org-info-js_info-navigation { border-style: none; }
|
||||
#org-info-js_console-label
|
||||
{ font-size: 10px; font-weight: bold; white-space: nowrap; }
|
||||
.org-info-js_search-highlight
|
||||
{ background-color: #ffff00; color: #000000; font-weight: bold; }
|
||||
/*]]>*/-->
|
||||
</style>
|
||||
<link rel="stylesheet" type="text/css"
|
||||
href="http://sachachua.com/blog/wp-content/themes/sacha-v3/foundation/css/foundation.min.css"></link>
|
||||
<link rel="stylesheet" type="text/css" href="http://sachachua.com/org-export.css"></link>
|
||||
<link rel="stylesheet" type="text/css" href="http://sachachua.com/blog/wp-content/themes/sacha-v3/style.css"></link>
|
||||
<script type="text/javascript">
|
||||
/*
|
||||
@licstart The following is the entire license notice for the
|
||||
JavaScript code in this tag.
|
||||
|
||||
Copyright (C) 2012-2013 Free Software Foundation, Inc.
|
||||
|
||||
The JavaScript code in this tag is free software: you can
|
||||
redistribute it and/or modify it under the terms of the GNU
|
||||
General Public License (GNU GPL) as published by the Free Software
|
||||
Foundation, either version 3 of the License, or (at your option)
|
||||
any later version. The code is distributed WITHOUT ANY WARRANTY;
|
||||
without even the implied warranty of MERCHANTABILITY or FITNESS
|
||||
FOR A PARTICULAR PURPOSE. See the GNU GPL for more details.
|
||||
|
||||
As additional permission under GNU GPL version 3 section 7, you
|
||||
may distribute non-source (e.g., minimized or compacted) forms of
|
||||
that code without the copy of the GNU GPL normally required by
|
||||
section 4, provided you include this license notice and a URL
|
||||
through which recipients can access the Corresponding Source.
|
||||
|
||||
|
||||
@licend The above is the entire license notice
|
||||
for the JavaScript code in this tag.
|
||||
*/
|
||||
<!--/*--><![CDATA[/*><!--*/
|
||||
function CodeHighlightOn(elem, id)
|
||||
{
|
||||
var target = document.getElementById(id);
|
||||
if(null != target) {
|
||||
elem.cacheClassElem = elem.className;
|
||||
elem.cacheClassTarget = target.className;
|
||||
target.className = "code-highlighted";
|
||||
elem.className = "code-highlighted";
|
||||
}
|
||||
}
|
||||
function CodeHighlightOff(elem, id)
|
||||
{
|
||||
var target = document.getElementById(id);
|
||||
if(elem.cacheClassElem)
|
||||
elem.className = elem.cacheClassElem;
|
||||
if(elem.cacheClassTarget)
|
||||
target.className = elem.cacheClassTarget;
|
||||
}
|
||||
/*]]>*///-->
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="preamble" class="status">
|
||||
<a name="top" id="top"></a>
|
||||
</div>
|
||||
<div id="content">
|
||||
<div class="center">
|
||||
|
||||
<div class="figure">
|
||||
<p><img src="./images/logo.png" alt="logo.png" />
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<table border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
<col class="org-left" />
|
||||
|
||||
<col class="org-left" />
|
||||
|
||||
<col class="org-left" />
|
||||
|
||||
<col class="org-left" />
|
||||
|
||||
<col class="org-left" />
|
||||
</colgroup>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="org-left"><a href="#orgheadline1">What is a mesh network?</a></td>
|
||||
<td class="org-left"><a href="#orgheadline2">The Freedombone Mesh</a></td>
|
||||
<td class="org-left"><a href="#orgheadline3">Installation</a></td>
|
||||
<td class="org-left"><a href="#orgheadline4">Wifi adaptors</a></td>
|
||||
<td class="org-left"><a href="#orgheadline5">Using the mesh</a></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<div id="outline-container-orgheadline1" class="outline-2">
|
||||
<h2 id="orgheadline1">What is a mesh network?</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline1">
|
||||
<p>
|
||||
The internet as it currently exists is mostly organised according to a client/server model. Servers run the web services and store the data and clients are the laptops, desktops and other devices accessing the servers. In a mesh network there isn't any clear division between clients and servers. The computers on a mesh network are known as "peers" and they can perform the functions of both clients and servers. Commonly this is also known as a "peer to peer" network.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
The client/server and mesh network models have advantages and disadvantages. If the server in a client/server system fails then you can have catastrophic service outages which affect many users. If a peer in a mesh network fails then the other peers may be mostly unaffected and communications can continue. The disadvantage of mesh networks is that each peer relays data for other peers and so the bandwidth usage by each peer may be higher than for a client in a client/server system. However, with modern hardware that's not much of an issue.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Mesh networks are useful for building local and highly resillient communications infrastructure which can be put together rapidly, in situations where the ordinary internet is either unavailable or untrustworthy.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Example use cases would be:
|
||||
</p>
|
||||
|
||||
<ul class="org-ul">
|
||||
<li>Conferences / Exhibitions</li>
|
||||
<li>Local community networks, not run by telcos or ISPs</li>
|
||||
<li>Emergency services / Disaster relief</li>
|
||||
<li>Camp sites</li>
|
||||
<li>War zones</li>
|
||||
<li>Scientific expeditions to remote areas</li>
|
||||
<li>Onboard smaller ships without satellite internet, captain/crew communications</li>
|
||||
<li>Underground (mines or caves)</li>
|
||||
<li>Protests / Occupations of buildings</li>
|
||||
<li>Eventually in space for manned missions to other planets, moons or asteroids</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgheadline2" class="outline-2">
|
||||
<h2 id="orgheadline2">The Freedombone Mesh</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline2">
|
||||
<p>
|
||||
The Freedombone mesh is offline - in the sense of not being part of the larger internet - and consists of a set of computers with the software installed communicating wirelessly using ordinary wifi. Peers can enter or leave the network and it will adjust automatically. All communications between peers is end-to-end encrypted, so although it's easy to join the network it's not easy to passively evesdrop.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline3" class="outline-2">
|
||||
<h2 id="orgheadline3">Installation</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline3">
|
||||
</div><div id="outline-container-orgheadline6" class="outline-3">
|
||||
<h3 id="orgheadline6">Two types of system</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline6">
|
||||
<p>
|
||||
Installation is split into two categories, <i>routers</i> and <i>user devices</i>.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
A router is a computer which is dedicated to moving network traffic and building out the mesh infrastructure. It's not primarily intended to have a user interface. Hardware such as the Beaglebone Black is ideal for this, because it's small, inexpensive and doesn't consume much electrical power and so can be fitted in any location where an electricity supply is available.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Small computers acting as mesh routers can also be battery operated or solar powered so that the network need not be statically sited. They could be included in a backpack for camping, fitted within moving vehicles, strapped to protest placards or attached to large tethered helium balloons (like weather balloons) to help provide a local and transient communications system.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<i>User devices</i> are the computers with which you would typically access the internet - laptops, desktop machines, netbooks or any other device which can run a Debian-based distro (eg. Ubuntu) with a working wifi connection.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline7" class="outline-3">
|
||||
<h3 id="orgheadline7">Installing on routers</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline7">
|
||||
<p>
|
||||
Whatever system you're going to use as a mesh router should have a new Debian Jessie install on it. It's advisable that this be a new install so that there is no existing software on the system which could confuse the mesh install process. Connect your system to your internet router with an ethernet cable, then ssh into it and type:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash">su
|
||||
apt-get update
|
||||
apt-get install git build-essential dialog
|
||||
git clone https://github.com/bashrc/freedombone
|
||||
<span class="org-builtin">cd</span> freedombone
|
||||
make install
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
At this point if you are using a system or dongle with an Atheros AR9271 wifi chipset then you may want to install some pre-compiled firmware (you can compile it from source, but it takes a long time - especially on the Beaglebone Black). If you need to do that then see the wifi adaptor notes below.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Then to begin the install:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash">freedombone menuconfig
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
Select the "<i>mesh (router)</i>" install variant, give an ESSID or just hit enter for the default. If discression is important then use an ESSID similar to those already in the area. The ESSID must be the same on every mesh peer. Assign this mesh peer a name. In order to avoid confusions it's important that the name should be unique on the network and contain no spaces. So maybe a word followed by some numbers, or the name of the place where the router will be installed.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
If you're installing on a Beaglebone Black then after a while the system will reboot and you will need to ssh in again and run:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash"><span class="org-builtin">cd</span> freedombone
|
||||
freedombone -c freedombone.cfg
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
The reboot is needed in order to enable zram and the hardware random number generator.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline8" class="outline-3">
|
||||
<h3 id="orgheadline8">Installing on user devices</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline8">
|
||||
<p>
|
||||
Typically on a laptop with a Debian-based distro installed, open a terminal and type:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash">sudo apt-get update
|
||||
sudo apt-get install git build-essential dialog
|
||||
git clone https://github.com/bashrc/freedombone
|
||||
<span class="org-builtin">cd</span> freedombone
|
||||
sudo make install
|
||||
freedombone menuconfig
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
Select the "<i>mesh (user device)</i>" variant and set the same ESSID as you did for the routers, or just hit enter for the default.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
An important point is that on older Debian-based systems, such as Ubuntu 14.04 or Trisquel 7, you may need to install a more recent version of <i>batctl</i>. An example is as follows.
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash">sudo apt-get remove --purge batctl
|
||||
wget http://mirrors.kernel.org/ubuntu/pool/universe/b/batctl/batctl_2014.1.0-2_amd64.deb
|
||||
sudo dpkg -i batctl_2014.1.0-2_amd64.deb
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline4" class="outline-2">
|
||||
<h2 id="orgheadline4">Wifi adaptors</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline4">
|
||||
<p>
|
||||
There are a small number of wifi adaptors which are compatible with a fully free software stack.
|
||||
</p>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline9" class="outline-3">
|
||||
<h3 id="orgheadline9">Atheros AR9271</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline9">
|
||||
<p>
|
||||
To install the firmware for this:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash"><span class="org-builtin">cd</span> freedombone/drivers
|
||||
sha256sum ath9k_htc_driver_bbb.tar.gz
|
||||
7eb9324681f03c7630ed01e490ea447dfbd96c9b5389e45b64e4646d1be16ff1
|
||||
tar -xvzf ath9k_htc_driver_bbb.tar.gz
|
||||
mv *.fw /lib/firmware
|
||||
<span class="org-builtin">cd</span> ..
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline5" class="outline-2">
|
||||
<h2 id="orgheadline5">Using the mesh</h2>
|
||||
<div class="outline-text-2" id="text-orgheadline5">
|
||||
</div><div id="outline-container-orgheadline10" class="outline-3">
|
||||
<h3 id="orgheadline10">Switching from internet to mesh mode</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline10">
|
||||
<p>
|
||||
To join the mesh network open a terminal and type:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash">meshweb
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
If you want to have your system as a permanent mesh peer then you could add that command to your startup applications so that it activates whenever the computer starts up.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
A web page should appear in your browser, which then allows you to access communication services on the mesh. These pages should update automatically, so that if peers enter or leave the network the lists will change accordingly.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline11" class="outline-3">
|
||||
<h3 id="orgheadline11">Chat</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline11">
|
||||
<p>
|
||||
If you have a Tox client installed on your system then you can use that to communicate with other mesh peers. A limitation is that if peers change you may need to quit the application and restart it in order to receive the updated list of DHTnodes. The <a href="https://github.com/Tox/toxic">Toxic</a> client is installed by default, but you may also want to install <a href="https://github.com/tux3/qTox">qTox</a> or <a href="http://utox.org/">uTox</a> for a more conventional-looking user experience.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
You can obtain Tox IDs for users on the network via the initial web page.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
To launch the <a href="https://github.com/Tox/toxic">Toxic client</a> in a terminal type:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash">toxic
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
The first time you will be asked whether you wish to encrypt the data file used for your settings. Select "no" for this, otherwise the system will not be able to obtain your public key and broadcast it to other peers in the network. Even if you select "yes" the system will still be usable, but it will not be so easy for other peers on the network to find you unless you have previously exchanged your Tox ID via some out-of-band method.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Then to add a new friend:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash">/nick mynickname
|
||||
/add <friend Tox ID>
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
Your friend will need to approve the request, and then you can chat via text or voice using <i>CTRL-o</i> and <i>CTRL-p</i> to switch between screens and cursor keys plus Enter to select users.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
A note for the security-conscious is that broadcasting Tox IDs via the network (using Avahi) is convenient but not highly secure. An adversary could maybe join the network and create decoy peers to try to disrupt the communications and have messages going to the wrong places. For the best security exchange Tox IDs in advance by some method other than looking them up from the initial mesh web page.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline12" class="outline-3">
|
||||
<h3 id="orgheadline12">Blogging</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline12">
|
||||
<p>
|
||||
The Freedombone mesh uses a fully decentralized blogging system called <a href="https://github.com/HelloZeroNet/ZeroBlog">ZeroBlog</a>. It behaves rather like other peer-to-peer file sharing systems in that if you are reading the blog of another user you are also simultaneously seeding it to other peers (acting as both a client and a server). This allows the system to scale well, while also being robust to any peer failing or leaving the network.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
All blogs on the mesh are public, so any user joining the mesh can read any other blog. Network traffic is encrypted between peers, so passive snooping will be hard, and also the integrity of data is checked via certificates so that you can be reasonably confident that nefarious content has not been added or removed from the data stream while in transit through the network.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
This type of content creation and delivery provides a good template for what the conventional internet should ultimately be like if it is to be robust, trustworthy and resistant to censorship or damage.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
To add a new blog entry click the <i>new post</i> button, edit the title and content (clicking <i>save</i> at the bottom of the screen after each). Then when you are done click on the <i>publish</i> button at the bottom of the screen. And that's all there is to it.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline13" class="outline-3">
|
||||
<h3 id="orgheadline13">Other services</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline13">
|
||||
<p>
|
||||
It is hoped that a decentralized forum will be added, but this is not yet complete. In the mean time a substitute is to use the Tox group chat feature.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgheadline14" class="outline-3">
|
||||
<h3 id="orgheadline14">Turing off the mesh</h3>
|
||||
<div class="outline-text-3" id="text-orgheadline14">
|
||||
<p>
|
||||
If you wish to return to the internet then open a terminal and type:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
|
||||
<pre class="src src-bash">sudo batman stop
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
After a few seconds your usual internet wifi connection should be re-established.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
|
||||
<style type="text/css">
|
||||
.back-to-top {
|
||||
position: fixed;
|
||||
bottom: 2em;
|
||||
right: 0px;
|
||||
text-decoration: none;
|
||||
color: #000000;
|
||||
background-color: rgba(235, 235, 235, 0.80);
|
||||
font-size: 12px;
|
||||
padding: 1em;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.back-to-top:hover {
|
||||
background-color: rgba(135, 135, 135, 0.50);
|
||||
}
|
||||
</style>
|
||||
|
||||
<div class="back-to-top">
|
||||
<a href="#top">Back to top</a> | <a href="mailto:bob@robotics.uk.to">E-mail me</a>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
var offset = 220;
|
||||
var duration = 500;
|
||||
jQuery(window).scroll(function() {
|
||||
if (jQuery(this).scrollTop() > offset) {
|
||||
jQuery('.back-to-top').fadeIn(duration);
|
||||
} else {
|
||||
jQuery('.back-to-top').fadeOut(duration);
|
||||
}
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -4,7 +4,7 @@
|
|||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<title></title>
|
||||
<!-- 2015-07-19 Sun 18:49 -->
|
||||
<!-- 2015-09-04 Fri 22:29 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="generator" content="Org-mode" />
|
||||
<meta name="author" content="Bob Mottram" />
|
||||
|
@ -225,12 +225,7 @@ Freedombone may be installed either in its entirety or as different variants wit
|
|||
|
||||
<tr>
|
||||
<td class="org-left"><b>Mesh</b></td>
|
||||
<td class="org-left">Mesh network bridge to the internet</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="org-left"><b>Nonmailbox</b></td>
|
||||
<td class="org-left">Installs eveything except for the email server</td>
|
||||
<td class="org-left">A wireless mesh network which is like the internet, but not the internet</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
Loading…
Reference in New Issue