Compare commits

..

No commits in common. "hh_master" and "master" have entirely different histories.

51 changed files with 147 additions and 502 deletions

View file

@ -1,10 +0,0 @@
language: python
python: "3.4"
before_install:
- sudo apt-get install iputils-ping checkinstall
- wget https://www.linuxlounge.net/~martin/icvpn/nmap_6.47-1_amd64.deb
- sudo dpkg -i nmap_6.47-1_amd64.deb
install:
- pip install -r .travis_requirements.txt
script:
- sudo bash -c "source ~/virtualenv/python3.4/bin/activate && scripts/check -s ./hosts/"

View file

@ -1 +0,0 @@
python-nmap

View file

@ -1,75 +1,4 @@
[![Build Status](https://travis-ci.org/freifunk/icvpn.svg?branch=master)](https://travis-ci.org/freifunk/icvpn) This repository holds IC-VPN keys and configuration.
This repository contains the tinc hosts for ICVPN-Peers and several helper scripts.
## Setup
This network requires the use of the Tinc VPN Daemon. You should use at least version 1.0.24 or higher, also the
current pre-release version 1.1pre11 seems to work just fine.
### Clone the repository
# cd /etc/tinc/
# git clone https://github.com/freifunk/icvpn.git
# cd icvpn
# cp scripts/post-merge .git/hooks/
### Create your tinc configuration
Open your favorite editor and create the /etc/tinc/icvpn/tinc.conf.
Name=entenhausen1
Mode=switch
More options can be found through
# man tinc.conf
Afterwards create a keypair with tincd.
# tincd -n icvpn -K
Hint: In version 1.1 this option was moved to the tinc binary and is called <code>generate-rsa-keys</code>.
### Execute post-merge hook
This step is necessary to populate your new configuration with infos about the metanodes.
# ./git/hooks/post-merge
### Set up a cronjob to update the repository in regular intervals.
# crontab -e
and insert for example
@daily cd /etc/tinc/icvpn/; git pull > /dev/null
## What are meta nodes?
Tinc has a ConnectTo configuration option that describes which peers on startup to connect *and* sync metadata to.
Until now (2015/4) we had roughly 74 nodes, and every node connected to each other (full mesh). Tinc however
does not scale this way, because on each connect and disconnect all ConnectTo-lines are being notified of this
and then notify their neighbours again. Many smaller nodes seemingly could not handle the amount of metadata generated
by this which resulted in TCP Zero Windows. They then disconnected, and reconnected, producing more metadata in
the process, which was followed by even larger nodes queueing up metadata, which resulted in all nodes taking
a massive cpu and memory hit. Memory usage of up to 1.5GB was spotted, accumulated in less than 12 hours.
However for tinc to build its network graph it is sufficient, if all nodes only exchange metadata at a few nodes,
which results in much less strain on the whole network. This is why we now use meta nodes, which are defined in
the `./metanodes` file.
Criteria for the selection of meta nodes are:
1. autonomous system diversity
2. community diversity
3. ample resources (cpu, memory, traffic)
When data needs to be transferd between two nodes, this will happen indepently of those meta nodes. Through the shared
network graph a direct transfer is possible and will be tried: at first via UDP, then via TCP, then indirectly. While
indirect routing is possible the meta nodes are not required to provide forwarding for those packets.
## Contact
The maintainers can be reached at
- [icvpn@lists.funkfeuer.at](mailto:icvpn@lists.funkfeuer.at)
- [irc.hackint.org #icvpn](irc://irc.hackint.org/icvpn)
We have set up IRC notifications for all repositories concerning the icvpn network.
For more Info see http://wiki.freifunk.net/IC-VPN

6
hosts/Treuenbrietzen Normal file
View file

@ -0,0 +1,6 @@
#Address = shonyt.mine.nu
-----BEGIN RSA PUBLIC KEY-----
MIGJAoGBANbR3LhhWFNt9ak//ZTReEuNQHjibgTAM+cNTDwLevudrP3y9htxTzgF
UZDHnkbDqwrYNjnuaMLIik7ljj5aKQd+fXmv3S+sFvvaPnm+e7Fpt+r/ReTnS6su
iOdmQ7XgC/b6r5ISjGhSheHcVSNMmbDWwYISSpDTu9S5qcUAkp1jAgMBAAE=
-----END RSA PUBLIC KEY-----

View file

@ -1,9 +0,0 @@
address = 195.169.146.33
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAuksyHS3OGQUUS7hVItJZGHK/RDeOzuSyqmi7jbVv+0/IfRLU/mt+
kz/wMz2O/UDxyR84wmrLTVdt8TYnOaFBrlNdMGz3k2HjbZc0UxZpKxHMYR4US6Ab
vLApHSxXK44c16wcWDhQB9yHqM3GdMTdbxuKV60qclulHuI9wHkxDtn1qb1dEkbv
2rF2ldfZnNCZ7ktQ1Pnnkv9lOhT1WK8Ye2Sbl+V7klK7leRfE/eTM5e1KP4Zlf62
iecoBCzFKCAk3Zw88Sv9IlkVG1ZgO8rdZPH7Bb461XH4W0gO9BANg2/SnW0Hlnyp
Ye2Bh+oGwQTlxjxN44nKOcornozC8kZUuwIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,4 +1,5 @@
Address = augsburg1.icvpn.augsburg.freifunk.net Address = augsburg1.icvpn.augsburg.freifunk.net
Address = 109.163.229.249
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIGJAoGBALVQaY0axASCewZdfMPbxUBwphhoDHKzm0SvpietNy0gy+43Jb+N/Cs+ MIGJAoGBALVQaY0axASCewZdfMPbxUBwphhoDHKzm0SvpietNy0gy+43Jb+N/Cs+
d9l9HlAS2ngrCAahVm/GRA3iYHH2i5JdZnzxPFKdkefcZFz7x0ZDaqeqpb2YLWFs d9l9HlAS2ngrCAahVm/GRA3iYHH2i5JdZnzxPFKdkefcZFz7x0ZDaqeqpb2YLWFs

View file

@ -1,4 +1,4 @@
# Address = augsburg2.icvpn.augsburg.freifunk.net Address = augsburg2.icvpn.augsburg.freifunk.net
Address = augsburg2.icvpn.freifunk-augsburg.de Address = augsburg2.icvpn.freifunk-augsburg.de
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----

7
hosts/badzwischenhahn1 Normal file
View file

@ -0,0 +1,7 @@
#Address = ffbz.ath.cx
#Port = 655
-----BEGIN RSA PUBLIC KEY-----
MIGJAoGBAMlCF8Yj3adfH6Mssc7J59CMIzO4ZTa4meHXDaGWHXzGIMnUWRUlLIfp
7sa/uJ4U9iQU3ZEwv1cPWweDvWrG1HNL+oJEVv7xQWcBXaYnm0le305qom0E0U5U
cMt+yNZWTh2KfgJjGB78FuOas1yiGpVPnV2wAGgzREKgmiXTOzZnAgMBAAE=
-----END RSA PUBLIC KEY-----

View file

@ -1,4 +1,4 @@
# Address = freifunk-bt.criede.de Address = freifunk-bt.criede.de
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAppgeP431r3K4cgy9s1XUB/+SEb9F64Y9q34jxjwRssIaFx+mtukr MIIBCgKCAQEAppgeP431r3K4cgy9s1XUB/+SEb9F64Y9q34jxjwRssIaFx+mtukr
JDLFtRNNTi7ao+kL3s1OBhavCeKwYSFAlaQnIm7fLwKwhJiIZwnKVM26SJPUwPfP JDLFtRNNTi7ao+kL3s1OBhavCeKwYSFAlaQnIm7fLwKwhJiIZwnKVM26SJPUwPfP

10
hosts/bielefeld2 Normal file
View file

@ -0,0 +1,10 @@
Address = vpn2.freifunk-bielefeld.de
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAuNUlmNeftDUvk7FAJFvX7XwI9CYnEpdU7TD3waeE6ZbU1mSW0d+n
9MUArA1iprh9UlPchGrkluIV6lX1XaVYzeXy4HVtf5nLUBssCnbBN8T1PE2qD0rS
pYKQEc/C1fuGLx07uzKHpz9PufOZQrmiRzoAciZBRZ0y16wtkO5aKV+cHawnnaP2
rzKeNIKq+XvusalDf0gftr0znivFeHZk7C2XzZ27HjJGcZM8k/xtMiCfMVo6NpZX
s9hkCrbT6vKtTVWCdAMcZAk0taF8eTPxkRoMMADExeXcoQXIxazvfdV0z+ou/2it
5X3PohGtF70ZoT98OT2s3xETCea1JyOyDQIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,12 +0,0 @@
Address = vpn4.freifunk-bielefeld.de
Port = 655
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAvOJHnI0VCn4ZOVitzitHPHpxHesW4TYf7QafYU6ClQy/Sy9WN5Eg
lrfszpwZmzABnJZ7T7BQN8j91neKwzj10qr6ppLCDavP0nqQ0CJ+Bg7SCc6HJbsQ
aDTU1lvNcGKKPD+KchSNxUkOBZjZavVw01taztEnYy6hUy/ml8vdLTUjBBPMUQ0+
rTe5m/rjPim5J4Eo56kRoJ2TQ3bRNZwTAgV07NAosO5V1qUncPoYsMmS6RrbBVxj
q7UOEyegBrsFF0F5tdK/itvZIWD2T/0DlDUqoPmfh2j+urbzYwAw9VBc1+4DByfS
Unn0cQ8AccXTDtMWQVOrLxIhm0JCmiDi6wIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,11 +1,12 @@
Address = vpn01.bremen.freifunk.net Address = vpn01.bremen.freifunk.net
Port = 656 Port = 656
-----BEGIN RSA PUBLIC KEY----- -----BEGIN PUBLIC KEY-----
MIIBCgKCAQEAr7aAgyRdDjTjJyUhHaPd8aZIybNvi+paDKwkRJFUEHybsSsZs8pl MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAy2FfayKB0nuggl/B9Lff
mJl+wFFn3sW3y6R7th1iVSqHDU85KYpy7CemKcHRo0VVl0OayToKQGUc9wuUkjM2 lLAWf92KPDtmJt6un1nRylX99n1yTatnnzW9r4dv7oDKJVEGxOe9d17CIg0l/lQQ
XIpZ6WxJ2+B918780dFA5esdeigSTXnKABt80wllLmBumiumj6fGQnzXOFMfyWSI UDC0sBJmB+JLQE8INHASQPcRbQVvlRrq+jVSUbpezA8H4W/FDc0kyERJG4zHAW4b
TlpW77EQqZY3uXGlZjbzmCbzmspbldHZKwUBr1f8GW6pdeMzEeptg/5nVLLu0rG+ Om0c8ndFZBU2eMXTyaeFZ5gi6AETZ+GAOt3BGP3lhzVMIotnSf5Mm1q5EOejjlND
o+rXQuU2GxJXd6OwrIWEzLCpxbRNqZ6Xo2o1U4Mc3vrKv7yQ61xY/hYB7BLU89Dz dsz3Fsn3ScWgVeUCjwWK1xs/jg5+pa90he/eqO+DmihxDA0006YBnQcA0kiprjK2
tTNXWxy4cm/xYdxmCBStzWGwNRndqNY7fwIDAQAB k6Jo8J1KWD8G3m0XvWOu9z15WAKvkNSw96h28eGefsgQP+XEpEE9aWGcbuj88ycK
-----END RSA PUBLIC KEY----- dwIDAQAB
-----END PUBLIC KEY-----

View file

@ -1,11 +0,0 @@
Address = vpn03.bremen.freifunk.net
Port = 656
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAxWLy8tG8W3nV3o7fsm/oD+XwFW2qgGNRDRDiTPGmBNrHVGVCH8cI
s2Gpeu226x803dukxmrKXZskLBf5oCWxtI5wrxhkiIrb21RkODrMzQcKvOJ3pOGk
7GekS8WvhxuMAJEKnWiJIS9T3kcGUTMIETSvlWeG/SWkpVr2oFjD87LX+WDCOW/d
arHyu8xH4XpVaDeKwUHlDz3/QQjI4bOa2UvqmebkdkhX/uWd/hNTdpzUYwghPtPx
VNlKqeh+NSibYuep/VSoxFx8UHFu083nB2gNTF+b4apjB/4d2iFUMM/Mpgi+lYQ1
8ksoTu8C3e8KFhp4oP3GLlRuQ2QY+o4RpQIDAQAB
-----END RSA PUBLIC KEY-----

10
hosts/castrop1 Normal file
View file

@ -0,0 +1,10 @@
#Address = ffcas.no-ip.info
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAr1d6XRKMLgt853J8qxguOb017hjVSB4LNWKiLEXk1K5B4sPBP3Sj
6/3PjI38dbZsmWqOV6azMmqTeBjBKt1Ii02sfrIB0hc3JuwcCeLLrPtmxUWCIXon
pA0gv1mstM5BY4HLgfH9h9iwtTQ80k3BaTz5/Wcn3i3tRm/MLeXKNIRbIYLGxmyQ
aSE4QJCnWPXxW+FoKRY6u4jAmYeVi+OyF3Hg9HnVvsBV3AeQ4Ptb90Pkr76udN4D
W5rEIJelvAT2bMGlCZgowtCEgEAVqI2YHujndHemsUv/ApYR1xwKWRB/df9O8Fpr
HqdYAjpMtYoGfBj0UhulKZtHpM06LGDZNQIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,4 +1,4 @@
Address = ip4.gw03.darmstadt.freifunk.net Address = gw01.icvpn.darmstadt.freifunk.net
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIICCgKCAgEAsFBR3wzdRoFXDy38HQtlYDKHvsbY99fUkPZXxg5v3dBGIfWDWMBR MIICCgKCAgEAsFBR3wzdRoFXDy38HQtlYDKHvsbY99fUkPZXxg5v3dBGIfWDWMBR

View file

@ -1,4 +1,4 @@
Address = gw04.darmstadt.freifunk.net Address = gw02.icvpn.darmstadt.freifunk.net
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAuohUruR8enzVN1IswdzMuf8f3rY2HOK/yByItBcMHM9b4HMe6Jt6 MIIBCgKCAQEAuohUruR8enzVN1IswdzMuf8f3rY2HOK/yByItBcMHM9b4HMe6Jt6

View file

@ -1,10 +0,0 @@
Address = gw1.freifunk-dh.de
Port = 655
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEA3SOeCXMYhCyoBXd4LhJDEdq8afDcdT2+kX+8Cnv5HHMWfKv0PodZ
1zwPl04D3e7MJ+F73YXOIV6zAdEpwXMW6h15qg3r5vL+ZPKY/ywYnb3c1CIOe2C8
2rJoo9ynjJJt3rbrSc2qOkKFcEfSZWPn2cs9IiaX/tgZaPwpc/KDjPQ5kQ9AwVJk
2jMhuBHQClPUw/szHwkultrkRehQ7+H/lq7VMXdxfBHBh6Vtk6KX6N8S7NXYcKbG
Gk52yzLnlmGLxqJbPBBg68o54EEPsS9HUe4oKRkhYoHduQu3OTL4oFZTTXqVmaxB
JSXyXDFbJPMPNoSsC2F2D9bfPswIfH/efQIDAQAB
-----END RSA PUBLIC KEY-----

11
hosts/ehingen1 Normal file
View file

@ -0,0 +1,11 @@
Address = gw01.freifunk-ehingen.de
Port = 656
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAz1zcs2ZgiZRLVXQyqYXKD3+dx7imqN/cmJ6CYoSfxjesslWaS+qG
29YH+U7qXSDgRyjVtdXdVHIa9dYSKff292H7yzX3LbHPsUEeq5kAAqqieTIsRYoI
6QeUTYkfSuvkqmAe1zUmC5fcf8BRSu2YUHSWhM5Lu9ulWzXuKYoipnXgqQzVz67w
3DnYEx/DEAxn4LKagOpUq+l9OzChOtMWeW1/MSCaEhm7VLYaY9YITdhb5U61PB7F
fdv/77AhRBjL6zfNX6M9ZookKukAz3KHme5EzDYXVA4CiyBN+HMzgCYHbqopOiVZ
BGjNAeO8FjAkBwn5Os608LOSocOEVz9KDwIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,11 +0,0 @@
Address = ffef.securegate.eu
Port = 656
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEA0R+JEwwaxHJZsTlxTjpwDIjrSvbG6yCkeGO/zablrIdnoctZHgNQ
vcDvuSWeTThBvk7FVuOkgVbpcqTnDNzBNetV1SzpnQTG3yWJcADZtkt7oyEhkvV0
+fJN4eALaOJT1d1PVROcLyCVjBIP5m+d9rImLRQK0tzQnLWofuqDLxzYm8UjK2Df
hZ4cHQNi0r8EPzQPzLjcz3YmYO6iJ1s27F6iXd16uBCoAX2y4QdSauHQiijah5bf
laM3ZD8ry9Sgrxngz169ybp3yB7l37IPWhVRHy+OISY4z2G5IMEnwkeS+P8eM36X
ZG//Jc/joqqHszKLUAL1zpfNVqygHs06fwIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,5 +1,5 @@
Address = vpn1.freifunk-halle.de Address = vpn1.freifunk-halle.de
# Address = 88.198.51.136 Address = 88.198.51.136
Port = 655 Port = 655
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIGJAoGBALF/Wu4pe+f3dHeLYApHxUnOGUBzpNREUet6nDp80uWT/dph7h6Yqtz2 MIGJAoGBALF/Wu4pe+f3dHeLYApHxUnOGUBzpNREUet6nDp80uWT/dph7h6Yqtz2

10
hosts/flensburg1 Normal file
View file

@ -0,0 +1,10 @@
Address = fl1.icvpn.freifunk-flensburg.de
Port = 656
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAv9Ow8Vkxo03MaYxxpdjQ1/tce2BgyON3+HkHd7/s90wovB6kkFpY
jL+c6nqN8kIBPhAw4Ibz6HmwUm6GIgappkwI2B81TTfrF2k4LR0NX+Nbyw2UqpnF
mt4O4ZRDBoRPRJxyXHgxLox0/VqEH+F044nO5DVaCJihlDDVnmjqvdvazBLjsTrX
d08gPKkyD/VdUMaX6d5eZOfxzRiPYMpZE0rWMzQc+n1kvw1DXfk/jhawqf4ZpaH3
TD/DGzeuXnDjL2IxMYXHABdfZUug2r7eoP38UM7jVop32SVXQO95gBDs5hTzp9Wh
JdSYnxO3HgIRb+0g3a7Aq9KBBlQ6xCfZjwIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,5 +1,5 @@
# Address = gw2.fffranken.de Address = gw2.fffranken.de
# Port = 656 Port = 656
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIGJAoGBAOvt5phPFC+/KUvmGWJdNfIoPWuHfJb0na25VteGQDUMn0krudoIJQFb MIGJAoGBAOvt5phPFC+/KUvmGWJdNfIoPWuHfJb0na25VteGQDUMn0krudoIJQFb
snELlAl5emnNbH7W5NWGKfjl7fMRC8RJ7r9eb1/jjsRlDK6aRnN8hHzcCa45PCeI snELlAl5emnNbH7W5NWGKfjl7fMRC8RJ7r9eb1/jjsRlDK6aRnN8hHzcCa45PCeI

View file

@ -1,5 +1,5 @@
# Address = vpn3.fffranken.de Address = vpn3.fffranken.de
# Port = 657 Port = 657
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIGJAoGBAPIkkqmdnJi3Y+cGKslf0t+swE+7rtfRQTStW29MP62L6Sn0lxb5MufU MIGJAoGBAPIkkqmdnJi3Y+cGKslf0t+swE+7rtfRQTStW29MP62L6Sn0lxb5MufU
LRtR0UW31SWQ03HGuUe51e16ppxZ3V1AFQvoLAwxwDD6VvBk4n+XEiupWPt+0XSd LRtR0UW31SWQ03HGuUe51e16ppxZ3V1AFQvoLAwxwDD6VvBk4n+XEiupWPt+0XSd

View file

@ -1,4 +1,4 @@
# Address = port-87-193-156-225.static.qsc.de Address = port-87-193-156-225.static.qsc.de
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIGJAoGBALo3VfMiPxK5lxWOYqoCZavMp8Lo4HYTmhLR6w3dHDJTI+UKTNDOf3Tc MIGJAoGBALo3VfMiPxK5lxWOYqoCZavMp8Lo4HYTmhLR6w3dHDJTI+UKTNDOf3Tc
reO0q+K85uopAtuu9yEshMxapvmijmEO9YsD+XinLNvnwNxx7qSaVQrPFTa4MutK reO0q+K85uopAtuu9yEshMxapvmijmEO9YsD+XinLNvnwNxx7qSaVQrPFTa4MutK

View file

@ -1,11 +0,0 @@
Address = gw1.freifunk-gera-greiz.de
Port = 10781
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEArLhMleQyfCgADO1vPEHK1hTJ8ZW/NljeiFsZcvTHCRKnnfF0AP1S
XfcviGlQCV3sfhXLdKABe0QZiLeHwbJY2R/n0PJxG/UxfscAKH+vRCa6qA4PqVI7
CLShMe+E/S66UPvYzYYwBpfLBFYlaMzSz+IhvhiRwoCWgk/0+YfPJt85mFSUHNxN
XGiBLJBSRGnGi9BFSw+GbrN86lmknV/fnL4uypFw94TJYF0Q7TexgP7aRtFSOciH
2tDCbzzJh7lmw4XE1Wtz7QWUP/R34zqlOELXlmoilbkTO71y4qlCeTHmaWDOG9/f
VScV3K/v1mrofNlK35GJzfcOp9ueijIbZwIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,10 +1,10 @@
Address = bgp2.guetersloh.freifunk.net Address = bgp2.guetersloh.freifunk.net
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAwNqFwx5UvkekzqCArb2BBFBqtdRbOsY5WlL58qXPVm6buVqZhy0R MIIBCgKCAQEAx3TChQ0jKU/VZOJAnAxFk8IGLowzvhmtAVZrli6JjXp2hyGS0hrC
ZZ497YrX82L3K97sFZ/1jFa/YsY9n6E912Zcca5GxY7ln/wrkO8mSfvCq1KCUpv9 ZS/aZzQhpqeEmAVgqUJSOicIVT2hwyieyZXEM+fPgfEmD04ZDVjSFpjEPdJCp5iC
/00cQxTf+AVlHvryWDupxPasO29wb6b5ftd3HXR1lG/eg3YXmXMAFnWr7wYnrFwW rFU8saEg2c/MBnKAOl6YwjYUCADpjGpFrIvgGIv70OnFRzToQDAOZoW06Ka7OPnk
1YP9YW1cJRZw9AjQ7Y1X2ETa4JkcjCjY7R7hVoJFoVqjf5JLBpqGy/swETrQB0Ln XBAtpzamQpfKjjER5OPkRvj9Ne8KcUHo1vkJO/X4BkuFSOA2HQHYXdLKfPxcBijv
ZpSRSrmfMhf1dIIYnYLoqH9og6ypl6vAqYAOwN9KIFTODK7uXW9ARVyor9I9R4cC XI+9imHtVCZzvU45XkUpOZ8GC8o4z2FszBjsh8skG2DoPckCe8Hz8S+Ajxl1xelG
cMtg3bB/QyS+GJDyvYCGJn/ZL6TrSOw7WwIDAQAB 5wQ3SZ8gEj5NnP+OY/3OjUkJwsG/CAyAYQIDAQAB
-----END RSA PUBLIC KEY----- -----END RSA PUBLIC KEY-----

View file

@ -1,4 +1,4 @@
# Address = ffvpn.3dfxatwork.de Address = ffvpn.3dfxatwork.de
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAsYzXhlTKxR7YBUXHY0JscmtNbrFzZzviVzIhpuml499rh8TVhjMU MIIBCgKCAQEAsYzXhlTKxR7YBUXHY0JscmtNbrFzZzviVzIhpuml499rh8TVhjMU
ozyjbaPhSUy+9RY4F1WpRmDi3lyDx7eT0viRlOkFG8huApXEgGLQgah0M/pfwkc1 ozyjbaPhSUy+9RY4F1WpRmDi3lyDx7eT0viRlOkFG8huApXEgGLQgah0M/pfwkc1

View file

@ -1,11 +0,0 @@
Address = 01.icvpn.hamburg.freifunk.net
Port = 656
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEA3IbMWLjnM3S4HsFfKvhJdg9TYRPnzxRyL2CaL5KtcCTu8mMMOeCX
arfhaM0l7l/hr2/TrpjDH3NO+lT0mn9cwl1Jlq3bkNXiBghf+tgGJAr29DLm0teB
bvxy5YgL4qbWknNvqDRuLr7IFn0bScd8twN9mLeXzAmRCl43zzLMoYIf1A67Bt3H
pZ6MoIVF9ziw9E4s0cdaRx4S6Ok3h6ochCfoNAUAJhJvodOdjW9++Ffy+LLayBIZ
S21vezhhcb7fJ2qSO6x42Kp3FBaEY8zpOVdtPRX171xTUIv0vxYfRGsaOsT0biQc
EGCG3ch2HiwR7TDe4gpe7XV7+QpUY1dR/wIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,5 +1,5 @@
# Address = 02.icvpn.hamburg.freifunk.net Address = 02.icvpn.hamburg.freifunk.net
# Port = 656 Port = 656
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEApyg+KLP9XfIwOIgBHjbGgt0l5ve+/O1Mec3ed/d0q6Bh+oTkJxOn MIIBCgKCAQEApyg+KLP9XfIwOIgBHjbGgt0l5ve+/O1Mec3ed/d0q6Bh+oTkJxOn

11
hosts/hamburg31 Normal file
View file

@ -0,0 +1,11 @@
Address = 31c3.icvpn.hamburg.freifunk.net
Port = 656
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAwxJL8dxTEgfM/oSOzZivDL2NxOtplh6yCusY+cbH5u+x1aRWhfbe
ZBv37xYGXQq1Gx+SX9zASsj50AX/XK634+NQWCHVVcBtcB8VDMA3d4WAnDtvvdwA
L/uZQzFuWzi60Y76LZZJXmvICxatHYO+1TUUdHyxnInLjVVFotKsmNRm5T4EwOoj
US414QvjO3Z8Hdmv8N/mA4RsMfJ7udrIbf7Rbne0w+Tfy7qgeYu1knNYcTObSHSe
JXf0byElmtlCXP/B+/gocvCFAXg87JVrVN8OxoZgF6GvH5GYOD/nz63uQ/SXc6P7
qsIfCa/XW2J5Jgt7DIfjQImjII55udo7DwIDAQAB
-----END RSA PUBLIC KEY-----

6
hosts/hannover1 Normal file
View file

@ -0,0 +1,6 @@
#Address = vpn.hannover.freifunk.net
-----BEGIN RSA PUBLIC KEY-----
MIGJAoGBAJsf2VLpTQlglzwBWe2B9RIgTEl4Y2a22Xt0DMPRw2vRc4aLcYh9G9TC
IvlXl87TKILdkZ8jlK9cMmwupAmtoxlRUCDkode1dqZ/Knf+iIOCP3jBPDggKKcR
/8MmS/ao+Ujb9tTuzv8KhVOqAcezKAHh1rVjriVyhCS/PhmZDViZAgMBAAE=
-----END RSA PUBLIC KEY-----

View file

@ -1,15 +0,0 @@
Address = albufer1.ffka.net
-----BEGIN RSA PUBLIC KEY-----
MIICCgKCAgEAv3w8au8y75sWMzfi1sRzOjI/f+7Gak0qqHcGAQGd+TCwF88OgGDk
c7TUQJfUG1FcLSiEMKUSKyokFBU6qbzrnwxsK+/foEGrcde4CKaJ1/q+wxL1lRu0
/12ZVIvr6rMHugjD7XfRbHaUoH1p6ki1+mpwRiLKgKimYxaKoTTJGzkR5Gkabu59
J7zq6NhzDl+n4usI16Hd2rCtdvG5txDQJvnQTXS4oaidYMDbOulAK+FmDSwkPIcU
uaGELGD1eMDKR6e/cp3DqTLG54GgmxamL1i44iGwOWfFGC+JfeNEcS/FgOzIhTrR
a8SRnwJ7FnfqaOee0Ktht1iRmuhJQxtrgusi++WII77SC9jH1kZw2bqh60YbQVlh
szNPfbpu/TRiqlduDJDmmJgXDG0J3eSvzLWT1D+qXG5Swk7R04VYLCh/oXHAiHol
l/3D7423tcW51hq316if/9ncfXpKXcdQiEIjmhVt1vi7FQk+1lwmTOKXBAAXnZDb
7zO2aY1p7YncAudL1CP3oQPazWQHW+2XmLvnOL5guBb/3LL/3CltwBUAz6zfm2Pj
YKNiQJG5+YBZaPAIy+y4mhDbh9TIO3Zw0eNt4jinu7486iWstkjj+V8E7fWkTBZd
t2kGBpR5xOVsd8ettZr5pDni9n/e/SJasizsqGjsQnPjWqEUj+wZKn8CAwEAAQ==
-----END RSA PUBLIC KEY-----

9
hosts/kiel3 Normal file
View file

@ -0,0 +1,9 @@
Address=vpn3.freifunk.in-kiel.de
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAqDth8oT1QRrt1usUz2qb+QfWCrva67Vup3TOuV1Lf6Zo6veRDOcT
3jCQtQ+BYGAiLgwhrYtJ13oiMlTbpd32ns1dvp5BgaiTWexJuObsC04LVry0kML5
WyoInGpUD26sqPdXtcs9bAgNzkDCm7cxMtQiu4SGWyNYpfkkIb+4miUKyjnWCrqi
nWTX2KC4MJh7AMWSrk6vX7aYmV/qmHkIXBqhPKe0Ah6rufc8+ZkSATJJxTM78qwD
sOO78I3V6av1+QlaF9wCr5/X/eAD6XUEOJWPuiTflC27mDcihW2NE2YwCIDX8vk0
Ccuo6OGrjJpZz+ncEjCcFICPpKrL8kYCdwIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,11 +0,0 @@
Address = vpn4.freifunk.in-kiel.de
Port = 656
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEA49H0NRDyDqVy5eJygLHuwLq7VUhrPhyGMhHNcbJ/ZgnwAMkV2wfd
A+fO4ZXZ498rW3jNLvIxpUH81jsQBe4rFkvnTGZQcY2Lu7Q46XGIp4BNPjtUFIeH
1qhSANElylo6sZtu651pj2Lu3oV/9cxPDLrKWFaLSLmCrJoh9gkB4Xk4T0T7RWxG
NyNqdwcCzd+9ITIpRFtcB/pxlO/Ovirvwie+N/aZw8uC52ZOskhI/MSEYzFw+YYR
aWcoc1sAJ935EY7DET0MV/9yuM+hfRQyex3jKkXzykQL8kQ4t1+0dl3VYMiW6lr6
LeCasMGtby5sVeA/18H+fu+viZ+qc+wn9wIDAQAB
-----END RSA PUBLIC KEY-----

9
hosts/koblenz1 Normal file
View file

@ -0,0 +1,9 @@
#Address=dsserver.homelinux.org
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAsnls6tKZlZLjmOhjiMTh63GbOaEJ5L3/N4WQPNZN67YOoL0ISECv
QeQ/p/3iRRhN4EG58CxAJ0X8uqpjqP6xLcbBSDfLbAawjFzU7OrKWiCAmHeW5ZTk
5sRc6FlR45x63AkaUxiX8VEjBLdrxr6WlHG7XdJtaSYtSpeCESjtWnD3qSQVl7Zr
CNekrY0TUC4Q0nlmKhNnSISMmJxqvrlGvV+shH2QKSSTOyvOYhl7SwQpJHKfuIOx
9RbWDG4rrcqks/Kx4WBq/hwiUa8cy0tdoZcbrbjt6rzdIgByDQvcNJ0+hjypbW7H
j0nr+4GJ9zRGWvE2KopZ3WHE3SvvBeHynQIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,5 +1,5 @@
# Address = fastd3.kbu.freifunk.net Address = fastd3.kbu.freifunk.net
# Port = 656 Port = 656
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIICCgKCAgEAwzH7Z0W0yIDp80G8sHpaxez7GXL3Lql7DAdJkrNf6KEzZAsZ7usn MIICCgKCAgEAwzH7Z0W0yIDp80G8sHpaxez7GXL3Lql7DAdJkrNf6KEzZAsZ7usn

View file

@ -1,4 +1,4 @@
# Address = vpn1.leipzig.freifunk.net Address = vpn1.leipzig.freifunk.net
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIGJAoGBAKL7eWHmD2Rn6IP7JlSWtkphokN785g8nccBmfcjbwEwiZv+EFaVoid/ MIGJAoGBAKL7eWHmD2Rn6IP7JlSWtkphokN785g8nccBmfcjbwEwiZv+EFaVoid/
0dPfvHaX0GaQGOhpef3PVHEbIMuU8dD9+7WbXO3+hUSIAfHoIdGK7n8qFtzTpzqn 0dPfvHaX0GaQGOhpef3PVHEbIMuU8dD9+7WbXO3+hUSIAfHoIdGK7n8qFtzTpzqn

View file

@ -1,4 +1,4 @@
# address = gw.kiberpipa.net address = gw.kiberpipa.net
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIGJAoGBAL4X76pBCF0b/z45rFPbgTrKpISle9MbLqvq3tDc2fTERowis0aBTTuK MIGJAoGBAL4X76pBCF0b/z45rFPbgTrKpISle9MbLqvq3tDc2fTERowis0aBTTuK
mfVIQkF3W+8JMcjQdez5tQWKHnfpz4PmdSC4Dmxolgk/d9b7HNQTP8MCmCLzf+D7 mfVIQkF3W+8JMcjQdez5tQWKHnfpz4PmdSC4Dmxolgk/d9b7HNQTP8MCmCLzf+D7

6
hosts/ljubljana2 Normal file
View file

@ -0,0 +1,6 @@
#Address = AS64768.linuxshell.org
-----BEGIN RSA PUBLIC KEY-----
MIGJAoGBALVdchpMeSOA0JBBLwMMdX7hVMlLI2nXZ/0+b8R+36chmsajbKjsDa04
aw/t/YFo7iLFi3AAXj7Tm/8AXkRz6Rf93rplwo91k47Dz4iEwC/kn7kI8wrGyaTY
iVdBNp2InZzDeD621OfJa1nhh5ROI0q8T0P76b29Z6XkYJJpCa9pAgMBAAE=
-----END RSA PUBLIC KEY-----

View file

@ -1,5 +1,5 @@
# Address = 2.icvpn.md.freifunk.net Address = 2.icvpn.md.freifunk.net
# Port = 656 Port = 656
-----BEGIN RSA PUBLIC KEY----- -----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEA6v9HoQhGnAaWsSofuT4gplTOBhzmDz23wdQeWkVKM2tY7WCA1KNO MIIBCgKCAQEA6v9HoQhGnAaWsSofuT4gplTOBhzmDz23wdQeWkVKM2tY7WCA1KNO

View file

@ -1,15 +0,0 @@
address = 003.freifunk-moehne.de
-----BEGIN RSA PUBLIC KEY-----
MIICCgKCAgEAt9L7wOZhCIIoRZSFE+AiQ6evhH+I7z2duDULC3COb8EorKZzaFse
cTCfaOdZ6+cbraqFOiwAzigSf6CoaE8XdnSsWcowQGfESL+CJopoC3Be8h3Cz7ct
mWz+XmuRl6hHOKqGKxWRxihHQs5zdhF3k/iloWbBqozgKfqqaD8qkeKF32Fn14Ze
UUm7hWQgicyemGGZhBE3dluV9svN/XmAFty2r05y03wnHB37jc9RdegW3TcNSO4m
Y9K/q7pXQiA9TwoSpOEv+tKzWoVPf6Rp2ZXZb64vgl+tBnjvT8URL+EiYDHz0LTa
EuhHuK8pulXOQ5rZ1WmzuQDHBZWVMOLsiAepNd/zMXVpbp5CHpMW0zAbCDwtSdIv
qKODY28jWPvIxKK+7RyVaIehGrtu38zkelLYBaGuDUI6WLPkF8nM1BuJj69e47cF
NccaZah1wDIHk7WCCSUs9vPCb+rsNoDJUMm0/2dYG4dbDKJVCve6aYfEddlOxlTW
7wtjv592H9KGmf7+xMrcOt9Wvc1eDVvSrf6Ld9nv5Myd03YGYJau5JPPoyDVfCnI
MI8OMdNbEggXBSFFvlkU63JLgJGecuzJsVmb1MJjOMTuzOTl3WUvME8mtCdzZA53
LrQCHKBfQsK4V5MNURxvmMrLytUfEzjjMsP65HCiaEz9GCsNliNvuCcCAwEAAQ==
-----END RSA PUBLIC KEY-----

View file

@ -1,15 +0,0 @@
address = 103.freifunk-moehne.de
-----BEGIN RSA PUBLIC KEY-----
MIICCgKCAgEAzBMf2LQ7pa12n6VwBMUhMlJ0OXq6QYpPjfJpzJM4mnZ5j4oecpuN
Y1WO3FcbMuvU87eVNUUe+qetK1EuneqFadw4vILI5RNFYoWolqHqEDZmO2rLe9QK
T/CGYcLUi0SAOlXhXtPOod6XY+wcYJC8bq/tZDp/kWUbrwPJ+pl/bIAjex8WddaV
REJEayNvbgy5ehQ9+2JYHm1RSPfsz5UXD6hcgcKbQyqZZfvuL/r1WWQ+7gednVR9
ZQwgenLCVBZRDs5K7rH0oyv3VrY3SYJijoBTuTLcLiso9s7jJn9gsbv3DtyqkRXD
nhxGGFAfpMk1i4lcf40l9xkoCjiajRvcpCHuXUddl1TNVUXUd6KcciRHLLlqM/hr
Od0QzuW3PGvWHqTPinSvtkwIh+7t2LUlDsH1QfB2FOHppYbjci3YpwnLWJUlzuAh
mAJRM+jBiofKlWnJiU3nnncs58+bGgqhBO8b7F2pjoT5j9qqvOzgZnYAN+g+kvWJ
Abq0eWodCcvLmcbiycVP2HzI/A4lhRGjjvfFLRmLO7R6ZO5iXuBoM6W4AKwoxJrw
SBpf04nphfWBsez1QW6YqxxsTEDI1+y43VQmu1DVxhrQwexldRaMNLpyNVDZzZCv
hmPpPDJLfdAlr3ld78aBZHVAB5mCOygPuNHbtxnTc3xMWW+zDVeBQvcCAwEAAQ==
-----END RSA PUBLIC KEY-----

View file

@ -1,11 +0,0 @@
Address = gw05.4830.org
Port = 655
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAuizkPDLiPvMxnom5i6RG0ijqT9tKmuAFWdMT8FIPoP+d4x0M+1WF
F8tPZk6Si1t7AX9Cp4ZhPHbbwvSXb/P4Q2VLX2w0A9F67bZQFUBKCaGdRuFPXd2/
aPr2mQQFB0agA5rkQgegRVbFhKhxGE3UMLhP2DYkfTSI7Yw0oyzGOnSK1Jga5Y9Z
8W/sxPxj0rpAt/NFfl88qI9aiOYmOD8aFu+spQnNi9/K2yXVdYul0w7w2KAnCyjq
QWZbNzxFT6Lnlr4YnpuN3Yd81eeThPbH9of2wdMKyJSL6cYM+zZxCeniscspWrRw
3LPyinT/hEHLChkrQY507QQWXCM588yZeQIDAQAB
-----END RSA PUBLIC KEY-----

10
hosts/schwarzach1 Normal file
View file

@ -0,0 +1,10 @@
#Address = schwarzach1.hopto.org
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEApZQmRinQZQq7gPjFmltgFxXAv4REhkCAGcPwYl3uUeOwqe4adSDu
90G99x2sCMAdteQ5YrZsDqYw2DQJS4F0a5IF81+U4wfv97KNil/DG0rxqXALX8v0
OWfkUJUiblegeBo5R7/x+wDtdJbzmLszsfObo5W+jiyBSBM37RoHI2lfYEhu1+GE
2t1xWhZXsn65krEnF0mwg6sHzZPza051cQiCLIMSyqmI5jk17FzHfuKwdSKFQKMN
7rhVwgUgzL6RI5HQYDNjM5VEKHShIZ0MUvUQlhQuZglzIS9W0kvBhAFWg1zkUpaH
pGl/IK7z2VS5oayGIOpX8e/B0ITWuuzxVQIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,15 +0,0 @@
Address = gw1.freifunk-trier.starletp9.de
Port = 655
-----BEGIN RSA PUBLIC KEY-----
MIICCgKCAgEAtZakSOECioGgkCutgDyq28LLklVstsowc4oahDHhQt5pTv0ncUzE
D1rAVWGxYQuD21wu2gCW6zJpS+ZYxGnREIa799tdRtBSL/bH6QQsVpiQiWzpMk0D
HyOh17fbtqAekOzz3nY6hQFcB3CaJoqY2jrI/iQE15N1iNkA8m1nDnwpHxVtKNmh
9qq+2EtdXuuJP6o7gayjMLXiB0Iaz6rehlS8jzh6FdrCUQbyuRPW/XtT4tiwd0Ch
lVXoCnSrM0+tUW++0yQz9aCpLE+IMKcTGm1W3elNOA107R9BiJrPqM3ClP05ThRx
qWO/hCeJ7/Y0wFZBM2IWNX5ig3bAyhdUOaZA2Pr3HQ7dxRkHMDPOOjIzxPNQUvCm
M4yKXoC9Fuhy7iujd7fVovXqvwBfLAhm/krMZRftEU01qHdN+Qiemqawz/zx9Yok
GJwrVEttqXt1CP0yrm2GpLS0YOFCcTO6OGnzOP1AyCi8XjeoshqhT1GgHGky8TMs
GhMD227a9AIK+XTIGzvOEpYC04CYm9zcWBbcLwQZxZuX4XUIhCsgFtWYN0qHTbc3
ivhy6Z/MPvJGxiGbipMeZlHu4fEKCtOu4EdddkFLlMKdpA7Jo8PEMXy1zg+LRgWt
qZJ6AL52KEnR+2zjl3aLoXJ7H0eTAGJjiSMDfp4PXiIWr5amoH7d8QUCAwEAAQ==
-----END RSA PUBLIC KEY-----

View file

@ -1,10 +0,0 @@
Address = gw2.freifunk-trier.starletp9.de
Port = 655
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAu5IiDnY5Ix54b0fb6HqXM5GggH9TQCPTXqUnKgurPkiOHr+OcMSB
6LlE3v0N2HJYS+UJmjHZtNd9z4SdhQoft6t1vEM48G9gi0HDJoLvi+ZnEHbW0LdP
PE5H2gwEzrZ6YAtbFiyM55dVY/5G3fYEF7nrB1ItAkqujUfWoLSVE1q08Gt/MbnK
7X5rnr8JWquuj2vcn4KBn4YHuLBMNCotNINzDOECqst3CZLUioKoxQenhpyX/ZP0
A0RNqpf6msFMiRY5+qEhXQYqP7ztc9MaLb5+7dvSePkjR4tEvBEizV5Qxxzpb6FA
ZnOEZT5UV+Pgx8iyBuyXnHeDB4X4F3gbLwIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,11 +0,0 @@
Address = gw02.freifunk-westpfalz.de
Port = 656
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAvBxfjw2x1RB9nlypB0uXbb0Ad+bsPA3lVPUTiqf1jp9J7mq3SzQr
8XXbXSfYENjyLw6rif/7fYvnZsV9Pn+pj+sw7Hwj4JKyloNmLGe26youx+Ik3YXj
kvmPAF+6SShVAv4TEbOeqVNMggksXevJawPdR9lUrdu86uT49ncAWh29x9LBtLM7
ZzxacAn/ysIsH8oY+niFT0xTysLD0mxbvWuSrXjFaL4zTtGyT1jOvLyTvkpE10OK
bVid5JGlkK8+NWFC6pruy1UR0j3+OZ7lsiQsEFrBcj08Dot/msXlvYjcDVtCVFMU
/SAolG+xq5Olg8dOql4E64N5yoLp7wbTRwIDAQAB
-----END RSA PUBLIC KEY-----

View file

@ -1,5 +0,0 @@
berlin2
darmstadt2
luebeck2
trier1
hamburg03

View file

@ -1,197 +0,0 @@
#!/usr/bin/env python
import sys
import os
import socket
import subprocess
import nmap
from optparse import OptionParser
ip4, ip6 = 0, 0
ANSI_COLOR_ERR = "\x1b[31m"
ANSI_COLOR_WARN = "\x1b[33m"
ANSI_COLOR_OK = "\x1b[32m"
ANSI_COLOR_RESET = "\x1b[0m"
def error(*arg):
print(ANSI_COLOR_ERR, *arg, file=sys.stderr,
end='%s\n' % ANSI_COLOR_RESET)
def warn(*arg):
print(ANSI_COLOR_WARN, *arg, file=sys.stderr,
end='%s\n' % ANSI_COLOR_RESET)
def ok(*arg):
print(ANSI_COLOR_OK, *arg, file=sys.stderr,
end='%s\n' % ANSI_COLOR_RESET)
def check_host_lookup(hostname, port):
try:
return socket.getaddrinfo(hostname, port)
except Exception:
error("DNS Lookup for {hostname} failed".format(hostname=hostname))
return []
def check_icmp_reachability(gai_record):
host = gai_record[4][0]
family = gai_record[0]
if family is socket.AddressFamily.AF_INET:
process_name = 'ping'
else:
process_name = 'ping6'
child = subprocess.Popen([process_name, host, '-c', '1', '-W', '5'],
stdout=subprocess.PIPE)
child.communicate()
if child.returncode:
error("{host} is icmp unreachable".format(host=host))
return True if child.returncode == 0 else False
def check_udp_reachability(gai_record):
global ip4, ip6
host, port = gai_record[4][:2]
family = gai_record[0]
if family is socket.AddressFamily.AF_INET:
arguments = '-sU -PN'
else:
arguments = '-sU -PN -6'
scanner = nmap.PortScanner()
result = scanner.scan(host, str(port), arguments) # -sU requires root
state = result['scan'][host]['udp'][port]['state']
if state == 'closed':
error("{host} port {port}/udp is {state}"
.format(host=host, port=port, state=state))
else:
ok("{host} port {port}/udp is {state}"
.format(host=host, port=port, state=state))
if family is socket.AddressFamily.AF_INET:
ip4 += 1
else:
ip6 += 1
return False if state == 'closed' else True
def get_hosts_data(srcdir):
for fname in sorted(list(set(os.listdir(srcdir)))):
if fname.startswith("."):
continue
fpath = os.path.join(srcdir, fname)
if os.path.isfile(fpath):
with open(fpath) as f:
ignore_key = False
addresses = []
port = 655 # tinc default port
for line in f.readlines():
if '-----BEGIN RSA PUBLIC KEY-----' in line:
ignore_key = True
elif '-----END RSA PUBLIC KEY-----' in line:
ignore_key = False
if line.startswith("#") or ignore_key:
continue
chunks = line.split("=")
if len(chunks) == 2:
(k, v) = (x.strip().lower() for x in chunks)
if k == "port":
try:
port = int(v)
except ValueError:
error("non-integer default port given")
elif k == "address":
if " " in v:
parts = v.split(' ')
if len(parts) != 2:
error("unknown address format")
try:
int(parts[1])
addresses.append(parts)
except ValueError:
error("non-integer port given")
else:
addresses.append((v, None))
elif k in ('ecdsapublickey'):
continue
else:
error("unknown key {key} with value {val}"
.format(key=k, val=v))
# set explicit port for address/port pairs
for i, addr in enumerate(addresses):
if addr[1] is None:
item = (addr[0], port)
addresses[i] = item
yield(dict(community=fname, addresses=addresses))
def do_checks(srcdir):
global ip4, ip6
errcnt = 0
warncnt = 0
for host in get_hosts_data(srcdir):
print("Checking {community}".format(community=host['community']))
if not host['addresses']:
warn("no addresses specified")
warncnt += 1
for address in host['addresses']:
host, port = address
# dns lookup
records = check_host_lookup(host, port)
if not records:
errcnt += 1
else:
for record in records:
if record[1] is not socket.SOCK_DGRAM:
# vpn connections are udp based, so skip
# everything else
continue
if not check_icmp_reachability(record):
errcnt += 1
else:
port_state = check_udp_reachability(record)
if not port_state:
errcnt += 1
print("\nfound {}/{} working ipv4/ipv6 peers".format(ip4, ip6))
error("{} errors".format(errcnt))
warn("{} warnings".format(warncnt))
return 0 if errcnt == 0 else 1
if __name__ == "__main__":
parser = OptionParser()
parser.add_option("-s", "--sourcedir", dest="src",
help="Location of tinc host files. Default: ../hosts",
metavar="DIR",
default="../hosts/")
(options, args) = parser.parse_args()
ret = do_checks(options.src)
sys.exit(ret)

View file

@ -18,13 +18,13 @@ test -w $TINCCFG || fail "ERR: $TINCCFG is not writeable"
sed -i '/^ConnectTo/d' $TINCCFG sed -i '/^ConnectTo/d' $TINCCFG
while read HOST; do for HOST in hosts/*; do
# skip hosts without address # skip hosts without address
grep -iq '^Address' -- hosts/"$HOST" || continue grep -q '^Address' -- "$HOST" || continue
echo "ConnectTo = $HOST" >> $TINCCFG echo "ConnectTo = ${HOST##*/}" >> $TINCCFG
done < metanodes done
/usr/sbin/invoke-rc.d tinc reload icvpn invoke-rc.d tinc reload icvpn
exit 0 exit 0