tinyFecVPN v20210116.0 releases: VPN Designed for Lossy Links
tinyFecVPN
A Lightweight VPN with Build-in Forward Error Correction Support(or A Network Improving Tool which works in VPN mode). Improves your Network Quality on a High-latency Lossy Link.
TinyFecVPN uses Forward Error Correction(Reed-Solomon code) to reduce packet loss rate, at the cost of additional bandwidth usage.
Assume your local network to your server is lossy. Just establish a VPN connection to your server with tinyFecVPN, access your server via this VPN connection, then your connection quality will be significantly improved. With well-tuned parameters, you can easily reduce IP or UDP/ICMP packet-loss-rate to less than 0.01%. Besides reducing packet-loss-rate, tinyFecVPN can also significantly improve your TCP latency and TCP single-thread download speed.
TinyFecVPN uses the same lib as UDPspeeder, supports all FEC features of UDPspeeder. TinyFecVPN works in VPN mode, while UDPspeeder works at UDP tunnel mode.
How does it work
TinyFecVPN uses FEC(Forward Error Correction) to reduce packet loss rate, at the cost of additional bandwidth usage. The algorithm for FEC is called Reed-Solomon.
Reed-Solomon
In coding theory, the Reed–Solomon code belongs to the class of non-binary cyclic error-correcting codes. The Reed–Solomon code is based on univariate polynomials over finite fields.
It is able to detect and correct multiple symbol errors. By adding t check symbols to the data, a Reed–Solomon code can detect any combination of up to t erroneous symbols, or correct up to ⌊t/2⌋ symbols. As an erasure code, it can correct up to t known erasures, or it can detect and correct combinations of errors and erasures. Reed–Solomon codes are also suitable as multiple-burst bit-error correcting codes since a sequence of b + 1 consecutive bit errors can affect at most two symbols of size b. The choice of t is up to the designer of the code and may be selected within wide limits.
Check Wikipedia for more info, https://en.wikipedia.org/wiki/Reed–Solomon_error_correction
Efficacy
Tested on a link with 100ms roundtrip and 10% packet loss in both directions. You can easily reproduce the test result by yourself.
Ping Packet Loss
SCP Copy Speed
Changelog v20210116.0
- updated to lastest UDPspeeder library
Running
Assume your server ip is 44.55.66.77, you have a service listening on udp/tcp port 0.0.0.0:7777.
# Run at server side:
./tinyvpn -s -l0.0.0.0:4096 -f20:10 -k “passwd” –sub-net 10.22.22.0# Run at client side
./tinyvpn -c -r44.55.66.77:4096 -f20:10 -k “passwd” –sub-net 10.22.22.0
Now, use 10.22.22.1:7777 to connect to your service, all traffic will be improved by FEC. If you ping 10.22.22.1, you will get ping reply.
Note
–f20:10 means sending 10 redundant packets for every 20 original packets.
-k enables simple XOR encryption
Note2
You can use udp2raw with tinyFecVPN together to get better speed on some ISP with UDP QoS(UDP throttling).
Source: https://github.com/wangyu-/