emanuele-f
928fc9f22e
Add ability to insert linux routes in n2n
The new -n option can now be used to setup routes directly from the edge command line.
It supports both network routes and default gateway routes. Here is an example:
- "-n 192.168.100.0/24:192.168.99.1" routes the 192.168.100.0/24 network traffic via 192.168.99.1
- "-n 0.0.0.0/0:192.168.99.1" routes all the host traffic via 192.168.99.1
4 years ago
Logan007
f2524196b1
added optional payload compression (zstd) for all transforms
4 years ago
Logan007
7c2648c1e2
added cli option for ChaCha20 (-A4)
4 years ago
Logan007
9076ed1bab
added optional payload compression (lzo) for all transforms
4 years ago
Logan007
9e5934acc8
added ChaCha20 (cc20)
4 years ago
emanuele-f
46aaa86629
Fix multicast dropped when routing is disabled
5 years ago
realjiangms
9601e82daf
More reliable punching:
1. Some nat router blocks the port if incoming traffic arrives before outcoming traffic being sent. Give edge ability to set proper TTL so that the registration packet is dropped before it arrives peer.
2. Support Symmetric NAT by predicting 15 more ports when sending registration packet
3. Purge pending mac also on P2P normal packet. This is actually more usual condition.
4. Add doc for new flag.
5 years ago
emanuele-f
7e7782f965
Possibly fix mingw compilation
5 years ago
emanuele-f
1b49b37a75
Disable PMTU options on apple to fix compilation issues
5 years ago
emanuele-f
8f3009c448
Fix occasional connection issues on startup due to bad MAC address read
5 years ago
emanuele-f
0538c5261d
Disable PMTU in other platforms
5 years ago
emanuele-f
6c67ed0440
MTU changes to avoid connection stall on PMTU discovery failures
5 years ago
emanuele-f
27da194872
Reduce log level due to invalid supernode register ACK cookies
5 years ago
emanuele-f
2f671cf6d9
Add support for TOS setting in edge
5 years ago
emanuele-f
eea0c9b46b
Add option to disable p2p
5 years ago
emanuele-f
4e9d66a0a2
Rework log levels
Now "-v" only returns high level information, whereas "-vv" can be used to further increase the verbosity.
5 years ago
emanuele-f
6bb7e3d9c5
Fix dropped broadcast traffic
Fixes #161
5 years ago
emanuele-f
035b66b1a9
Fix mtu with AES
This avoids fragmentation when possible
5 years ago
emanuele-f
6328962752
Improve packet length log
5 years ago
emanuele-f
8880330c41
Windows compilation fix
5 years ago
emanuele-f
1c9e029b88
Retry multicast group join instead of exiting
Multicast group join failures can occur during system startup
5 years ago
Luca
1512f20eaa
Compilation fix
5 years ago
emanuele-f
a70641897d
Graceful termination in Windows
5 years ago
emanuele-f
41bff29df6
Disable multicast peers discovery in windows
5 years ago
Teteros
ba38ab70de
Fix typo: 'enstablished' -> 'established'
5 years ago
emanuele-f
447c3ad8c3
Replace peers linked list with hash
5 years ago
emanuele-f
4eacea7d57
Little improvement
5 years ago
emanuele-f
f36814b152
Implement query peer to try p2p during send
When a lot of monodirection traffic is sent, p2p can be hard to
enstablish because a reply is needed in order to start the registration.
Now a sending peer can query the peer information via the supernode.
This is based on the following commits:
- 1236f37a70
- ad2d416510
- 5348671299
- b2806dcde8
5 years ago
emanuele-f
b36754eae0
Set last_p2p ib peer_set_p2p_confirmed
5 years ago
emanuele-f
3db1cab276
Split broadcast stats from other supernode stats
5 years ago
emanuele-f
0e6db6361e
Fix connection stall when idle p2p refresh occurs
The edge received packets from the supernode and thought that the other
peer was still active, but the other peer had dropped the p2p connection
due to refresh
5 years ago
emanuele-f
f038f22a0b
Fix too many registrations going on
5 years ago
emanuele-f
623a9e480c
Improve log messages
5 years ago
fengdaolong
69e3b49bec
eliminate compilation warnings
5 years ago
yunbox
f48c170c26
Fix supernode handling REGISTER message from edge and let edge ask supernode to forward REGISTER message in case of non-p2p-reflection.
This is reliable way to PUNCH UDP HOLE (following STUN spec)
5 years ago
emanuele-f
3aec02d3e6
Fix unidirectional P2P connection due to pending registration
If A is directly available and B is NATted and B sends the first message to A via the supernode S,
A will try to register to B via the port used by B to talk to S. This will not work as B is NAT-ted,
so A must discard such pending registration as soon as it receives a P2P Registration from B.
5 years ago
emanuele-f
fb813e5438
Fix "invalid transop ID" when encryption is disabled
5 years ago
emanuele-f
52d33ed880
Fix missing destination MAC in REGISTER preventing proper P2P
As explained in #109
5 years ago
Jiang Zihao
0edca7e16a
Fix purge_expired_registrations to accept passed-in last_purge instead of static function var.
5 years ago
emanuele-f
59011308b2
Ignore invalid community when not received from supernode
The packet may be received from a multicast registration from a local peer.
Fixes #107
5 years ago
emanuele-f
04226c09c8
Fix compilation warnings and little leak
5 years ago
emanuele-f
bc904cfbcc
Skip localhost received sockets
5 years ago
emanuele-f
e2861e5f71
Fix send error in peer registration refresh
5 years ago
emanuele-f
49fd9fc5da
Discard idle known_peers to avoid connection blocking on disconnection
Fixes #103
5 years ago
emanuele-f
824b45a808
Add linux termination handler and print stats on shutdown
5 years ago
emanuele-f
d5387945b4
Add the -i option to specify registration interval on edge nodes
Registration is bound to UDP NAT hole punching, so the edges should choose their own value.
5 years ago
emanuele-f
856dbae44c
Cosmetic changes to improve edge registration tracing
5 years ago
Luca Deri
fbc3754601
Compilation fix
5 years ago
emanuele-f
c89ece71ca
Code rework changes
- Remove keyschedule leftover and adapt to new API
- Fix cleanup functions
- Remove unused random_device_mac
5 years ago
emanuele-f
f577d997a7
Drop keyschedule support
- Legacy features are now moved to the legacy directory with readme
- Keyschedule feature is not supported anymore
5 years ago