https://github.com/lu-zero/tcptunnel
Simple udp -> tcp -> udp tunnel
https://github.com/lu-zero/tcptunnel
Last synced: 11 months ago
JSON representation
Simple udp -> tcp -> udp tunnel
- Host: GitHub
- URL: https://github.com/lu-zero/tcptunnel
- Owner: lu-zero
- License: gpl-2.0
- Created: 2019-07-08T11:45:38.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2023-05-29T13:02:34.000Z (about 3 years ago)
- Last Synced: 2025-04-19T19:22:28.755Z (about 1 year ago)
- Language: Rust
- Size: 137 KB
- Stars: 11
- Watchers: 1
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: COPYING
Awesome Lists containing this project
README
# UDP -> TCP -> UDP tunnel
## Usage
``` sh
# Start the tunnel on the tcp -> udp side
$ tcptunnel -u -t
# Start the tunnel on the udp -> tcp side
$ tcptunnel -u -t -s
```
``` sh
# Setup two netcat in different consoles
# Input
$ nc6 -u localhost 5555
# Output
$ nc6 -ul localhost -p 6666
# Copy from input to output (NOTE: it prioritizes ipv6 over ipv4)
$ udpcopy -i udp://localhost:5555 -o udp://localhost:6666
```
``` sh
# duplicate the input to two different sockets (any number)
$ rtpbound -i udp://localhost:12340?buffer=100000 -o udp://localhost:12347?buffer=100000 -o udp://localhost:12349?buffer=100000
# read from two identical inputs and forward to an output, one input may fail and the stream stays fine
$ rtpbound -i udp://localhost:12349?buffer=100000 -i udp://localhost:12347?buffer=100000 -o udp://localhost:12348?buffer=100000
```
## Status
- [x] UDP -> TCP
- [x] TCP -> UDP
- [x] copy UDP -> UDP
- [x] copy RTP -> RTP and support multipath
- [x] cli
## Notes
Thanks to Edoardo Morandi for his help in debugging some async problems.