Commit c86a9ae4 authored by Guillaume Bury's avatar Guillaume Bury

README and TODO update

parent 81f49fab
Note (for U): logs haven't changed. I just added some logs messages to notify
when a task has been finished
Vifibnet is a daemon setting up a resilient virtual private network over the
internet
......@@ -31,7 +35,7 @@ OPTIONS : REGISTRY.PY
MUST contain the VPN network prefix in its serial number. To
generate correct ca and key files for the 2001:db8:42:: prefix,
the following command can be used :
openssl req -nodes -new -x509 -key ca.key -set_serial
openssl req -nodes -new -x509 -key ca.key -set_serial \
0x120010db80042 -days 365 -out ca.crt
--key path
......@@ -87,12 +91,11 @@ OPTIONS : VIFIBNET.PY
Specify connection information to be advertised to other nodes.
address MUST be a ipv4 address since as of now openvpn does not
support ipv6 addresses.
proto should be either udp or tcp-client
Proto should be either udp or tcp-client
--internal-port port
Specify the port on which will be launched the openvpn server(s)
Can differ from port given in the --ip option.
Default : 1194
-i, --interface interface
Give one interface name for each use of the argument. The interface
will be used to detect other nodes on the local network.
--peers-db-refresh duration
Duration in seconds of the peers DB refresh interval.
......@@ -138,17 +141,20 @@ OPTIONS : VIFIBNET.PY
It takes between 3 times and 4 times the hello interval for babel
to re-establish connection with a node for which the direct
connection has been cut
Default : 30
Default : 15
-w, --wireless
Consider all interfaces as being wireless interfaces. Argument
directly passed down to the babeld daemon
--proto p [p']
Protocol used by the openvpn server(s). Start one openvpn server
for each protocl specified.
p (and p') should be either udp or tcp-server
Default : udp
--pp port proto
Port and protocol used by the openvpn server(s). Start one openvpn
server for each couple port/protocol specified.
Additionally, if no external configuration is given in the command
line, vifibnet will attempt to forward a port with upnp for each
couple port/proto given.
Protocols should be either udp or tcp-server.
Default : (1194, udp)
--tunnel-refresh duration
Interval in seconds between two tunnel refresh. Refreshing tunnels
......@@ -203,3 +209,5 @@ OPTIONS : VIFIBNET.PY
The file should contain one option per line, possibly ommitting
the '--'. Only long option are allowed (i.e "v 3" will not work
while "verbose 3" will)
You can give a file ( with the @ prefix ) as an argument within a
file
To be done :
The address of the client is declared while it should only be the address
of the server
Upgrade the logging function in order to be able to log message like
"Refreshing peers DB ... done", or add log messages to specify that an
action advertised by a previous log message has been completed
use the server as a bootstrap node -> switch peer discovery to be done
by vifibnet directly ?
......@@ -14,16 +7,18 @@ To be done :
|-> number of routes / tunnel
|-> favorise most used roads ?
Replace comments at the beginning of functions with docstrings & give all
fn docstrings
Write docstrings for all class/methods/functions
Use a timeout for the server peersDB so we can flag unreachable peers and
remove the peers whose certificate is no longer valid
To be discussed:
G : There is a blacklist system now ( blacklisted prefixes are deleted from
the peers database ). Since all nodes whose packets are routed through
the local network are blacklisted, I think we should reset the blacklist
from time to time....
Handle LAN internally in order not to have catastrophic results ....
( avahi could be used )
U : The address of the client is declared while it should only be the address
of the server
G : ??
To be discussed:
U : Babel seems to be very long to establish the routes : maybe we should
tell him thant we are not on a wired network but on a mobile network ?
G : babel establish routes quickly enough i'd say. There are two new
......@@ -51,3 +46,4 @@ To be discussed:
reestablish connection, if a direct link is cut
U : So we have to reduce the hello interval. 2min to detect a dead link is
far too much.
G : k
......@@ -35,8 +35,12 @@ class PeerManager:
self.next_refresh = time.time()
def reset_blacklist(self):
self._blacklist = [(self._prefix)]
def blacklist(self, prefix):
utils.log('Blacklisting %s' % (prefix,), 4)
self._db.execute("DELETE FROM peers WHERE prefix = ?", (prefix,))
self._blacklist = list(set(self._blacklist + [(prefix,)]))
def refresh(self):
......
......@@ -54,7 +54,7 @@ def getConfig():
help="VPN port of the discovery peer server")
# Routing algorithm options
_('--hello', type=int, default=30,
_('--hello', type=int, default=15,
help='Hello interval for babel, in seconds')
_('-w', '--wireless', action='store_true',
help='''Set all interfaces to be treated as wireless interfaces
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment