-
Notifications
You must be signed in to change notification settings - Fork 2
Clone of https://code.google.com/archive/p/udptunnel/
License
antonbutanaev/udptunnel
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
============================================================================= UDPTUNNEL README Author: Daniel Meekins Contact: dmeekins - gmail Copyright (C) 2009 Daniel Meekins ============================================================================= This project tunnels TCP data through a UDP tunnel. The executable can act as the server or client. The server acts as a proxy for the client, listening on a specified UDP port and creating a connection to a TCP server that the client specifies. The client listens on a TCP port, acting as the server that some TCP client connects to. The client recevies any TCP data on that port and sends the data to the udpserver, which sends it to the TCP connection it made with the desired TCP server. ----------------------------------------------------------------------------- 1.) Building Use cmake to build. ----------------------------------------------------------------------------- 2.) Running usage: udptunnel [-v] [-6] <-s|-c> <args> -c client mode (default) <args>: [local host] <local port> <proxy host> <[proxy source port,]proxy port> <remote host> <remote port> -s server mode <args>: [host] port [acl ...] acl: [s=<src ip>,][d=<dst ip>,][dp=<dst port>,][a=allow|deny] -6 use IPv6 -v show some debugging output (use up to 3 for increaing levels) -h show this junks and exit example: A$ udptunnel -s 40000 B$ udptunnel -c localhost 40001 A 40000 localhost 22 B$ ssh -p 40001 localhost To run the server: udptunnel -s [-6] [host] port [acl ...] where the port is a UDP port to listen for messages from the udpclient and host is the address to listen on. Use the -6 option to listen on IPv6 addresses. After the port, the rest of the arguments are the access control list, with comma-separated parameters for each entry. Access can be control based on the source IP, destination IP, source port, and destination port. A catch-all entry is added at the end of every list that allows everything. To deny anything that doesn't match your entries, put "a=deny" as the last entry. In a Window's shell, each acl entry needs double quotes (") around them. Server Examples: udptunnel -s 4444 udptunnel -s -6 2001::10:3 4444 udptunnel -s 4444 d=10.0.0.1,dport=80,a=deny dport=80,a=allow a=deny To run the client: udptunnel -c [-6] [local host] <local port> <proxy host> <proxy port> <remote host> <remote port> local host/port - Host and port for the TCP server to listen on. If the host isn't supplied, it will listen on all available addresses. proxy host/port - Host and port that udpserver is listening on. remote host/port - Host and port to forward the received TCP data to. The host is relative to the proxy machine (e.g. specifiying 127.0.0.1 is the proxy machine itself). Use the -6 option to listen and connect using IPv6 addresses. Example for tunneling ssh data through the tunnel between two computers with IP addresses 192.168.1.2 (client) and 192.168.1.1 (server): server# ./udptunnel -s 192.168.1.1 4444 client# ./udptunnel -c 127.0.0.1 3333 192.168.1.1 4444 127.0.0.1 22 client# ssh -p 3333 user@127.0.0.1 This code has been tested and works on Linux, Solaris 10 x86, and Cygwin (but requires the IPv6 extension - http://win6.jp/Cygwin/index.html). Please send any bugs or issues to the contact listed above.
Releases
No releases published
Packages 0
No packages published