All Projects → MarkoPaul0 → DatagramTunneler

MarkoPaul0 / DatagramTunneler

Licence: GPL-3.0 license
Simple C++ cross-platform client/server app forwarding UDP datagrams through a TCP connection.

Programming Languages

C++
36643 projects - #6 most used programming language
Makefile
30231 projects
c
50402 projects - #5 most used programming language

Projects that are alternatives of or similar to DatagramTunneler

Socketify
Raw TCP and UDP Sockets API on Desktop Browsers
Stars: ✭ 67 (-42.24%)
Mutual labels:  socket, tcp, udp
Zserver4d
ZServer4D 是一套从商业项目剥离而出的云服务器中间件,可以承载百万级的分布式负载服务,并且支持IoT及内网穿透
Stars: ✭ 199 (+71.55%)
Mutual labels:  tunnel, socket, tcp
Udp2raw Tunnel
A Tunnel which Turns UDP Traffic into Encrypted UDP/FakeTCP/ICMP Traffic by using Raw Socket,helps you Bypass UDP FireWalls(or Unstable UDP Environment)
Stars: ✭ 4,839 (+4071.55%)
Mutual labels:  tunnel, tcp, udp
Kcp
⚡ KCP - A Fast and Reliable ARQ Protocol
Stars: ✭ 10,473 (+8928.45%)
Mutual labels:  tunnel, socket, udp
udp2raw
A Tunnel which Turns UDP Traffic into Encrypted UDP/FakeTCP/ICMP Traffic by using Raw Socket,helps you Bypass UDP FireWalls(or Unstable UDP Environment)
Stars: ✭ 5,256 (+4431.03%)
Mutual labels:  tunnel, tcp, udp
Nps
一款轻量级、高性能、功能强大的内网穿透代理服务器。支持tcp、udp、socks5、http等几乎所有流量转发,可用来访问内网网站、本地支付接口调试、ssh访问、远程桌面,内网dns解析、内网socks5代理等等……,并带有功能强大的web管理端。a lightweight, high-performance, powerful intranet penetration proxy server, with a powerful web management terminal.
Stars: ✭ 19,537 (+16742.24%)
Mutual labels:  tunnel, tcp, udp
Pingtunnel
ping tunnel is a tool that advertises tcp/udp/socks5 traffic as icmp traffic for forwarding.
Stars: ✭ 1,904 (+1541.38%)
Mutual labels:  tunnel, tcp, udp
Kalm.js
The socket manager
Stars: ✭ 155 (+33.62%)
Mutual labels:  socket, tcp, udp
gnb udp over tcp
gnb_udp_over_tcp 是一个为GNB开发的通过tcp链路中转UDP分组转发的服务
Stars: ✭ 32 (-72.41%)
Mutual labels:  socket, tcp, udp
AndroidNetMonitor
This project aims to collect and analyze traffic information of Android.(采集手机发送和接收的报文简要信息,并且根据socket记录每个报文对应哪个手机app)
Stars: ✭ 25 (-78.45%)
Mutual labels:  socket, tcp, udp
Ssokit Qmake
A Simple & Strong Tool for TCP&UDP Debug
Stars: ✭ 231 (+99.14%)
Mutual labels:  socket, tcp, udp
KingNetwork
KingNetwork is an open source library to facilitate the creation and communication of clients and servers via TCP, UDP, WebSocket and RUDP sockets.
Stars: ✭ 78 (-32.76%)
Mutual labels:  socket, tcp, udp
Pypacker
📦 The fastest and simplest packet manipulation lib for Python
Stars: ✭ 216 (+86.21%)
Mutual labels:  socket, tcp, udp
socket
Dazzle Async Socket
Stars: ✭ 19 (-83.62%)
Mutual labels:  socket, tcp, udp
Ohsce
PHP HI-REL SOCKET TCP/UDP/ICMP/Serial .高可靠性PHP通信&控制框架SOCKET-TCP/UDP/ICMP/硬件Serial-RS232/RS422/RS485 AND MORE!
Stars: ✭ 206 (+77.59%)
Mutual labels:  socket, tcp, udp
Mr2
Mr.2 can help you expose local server to external network. Support both TCP/UDP, of course support HTTP. Zero-Configuration.
Stars: ✭ 1,102 (+850%)
Mutual labels:  tunnel, tcp, udp
Socket
Non-blocking socket and TLS functionality for PHP based on Amp.
Stars: ✭ 122 (+5.17%)
Mutual labels:  socket, tcp, udp
Async Sockets Cpp
Simple thread-based asynchronous TCP & UDP Socket classes in C++.
Stars: ✭ 127 (+9.48%)
Mutual labels:  socket, tcp, udp
Frpc Android
Android,安卓版frpc,一个快速反向代理,可帮助您将NAT或防火墙后面的本地服务器暴露给Internet。
Stars: ✭ 205 (+76.72%)
Mutual labels:  tunnel, tcp, udp
RRQMSocket
TouchSocket是.Net(包括 C# 、VB.Net、F#)的一个整合性的、超轻量级的网络通信框架。包含了 tcp、udp、ssl、http、websocket、rpc、jsonrpc、webapi、xmlrpc等一系列的通信模块。一键式解决 TCP 黏分包问题,udp大数据包分片组合问题等。使用协议模板,可快速实现「固定包头」、「固定长度」、「区间字符」等一系列的数据报文解析。
Stars: ✭ 286 (+146.55%)
Mutual labels:  socket, tcp, udp

DatagramTunneler

Author License: GPL v3 GitHub last commit Stars

Simple cross-platform client/server program forwarding UDP datagrams through a TCP connection (aka tunnel). The client joins a multicast group and forwards the received datagrams to the server, which in turns multicasts them on its own subnet.

  • Designed with simplicity in mind
  • Tested on OSX 10.13.3, Ubuntu 16.04 and Centos 7.4
  • NOT Windows compatible

Content

Requirements
Installation
Synopsis
Examples
How does it work?
The DTEP Protocol
Licensing

Requirements

  • A computer running a Linux or Mac OS distribution
  • A c++ compiler

Installation in 10 seconds

  • Download or clone the repository.
  • Go into the repository:
cd <path_to_the_repo>/DatagramTunneler
  • Build the DatagramTunneler by simply running make:
make
  • You're ready to run the DatagramTunneler binary:
./bin/DatagramTunneler -h

For more info about how to run it, checkout the Synopsis below

Synopsis

In order to use the DatagramTunneler you need to start the server side first, then the client side. If you don't, the client will just fail to connect to the server and exit right away.

Server

  dgramtunneler --server -i <udp_iface_ip> -t <tcp_listen_port> [-u <udp_dst_ip>:<port>]
  • <udp_iface_ip>: interface used to publish the forwarded datagrams
  • <tcp_listen_port>: tcp port used to listen for client connections
  • <udp_dst_ip>:<port>: (optional) udp destination IP and port where the server is publishing the forwarded datagrams. If not provided, datagrams are published on the same channel joined by the client.

Client

  dgramtunneler --client -i <udp_iface_ip> -t <tcp_srv_ip>:<tcp_srv_port> -u <udp_dst_ip>:<port>
  • <udp_iface_ip>: interface used to join the multicast channel provided by -u
  • <tcp_srv_ip>:<port>: IP and port of the server to which the datagram will be forwarded
  • <udp_dst_ip>:<port>: udp destination IP and port of the channel we want to join

Examples

(Don't forget to give a little star if this tool is useful to you :]) server side:

./bin/datagramtunneler --server -i 192.168.0.104 -u 228.14.28.52:1234 -t 28052

client side:

./bin/datagramtunneler --client -i 192.168.0.105 -u 228.1.2.3:7437 -t 192.168.0.104:28052

How does it work?

The purpose of the DatagramTunneler is to transfer multicast data from one subnet A to another subnet B where that multicast channel is not available. To achieve this, the DatagramTunneler is split into 2 sides: a client side and a server side, as shown on the diagram below: Datagram Tunneler

The Client Side

The client side should run in the subnet where the multicast channel is joinable. Once started it will do the following:

The Server Side

The server side should run in the subnet where the multicast is not available. Once started it will do the following:

  • listen for a client connection (note that only one connection is accepted throughout the lifetime of the Server/Client instances. Once the tunnel is disconnected, both ends exit.
  • once a connection with a client is established, it will publish all the datagrams sent by the client to a multicast channel. That channel can be anything specified when launching the server, or if not specified, it will used the same multicast channel encoded with the datagram it received (c.f. DTEP).

The Datagram Tunneler Encapsulation Protocol (DTEP)

The Datagram Tunneler Protocol or DTEP is a simple binary protocol, which is described by the following diagram:

A DTEP packet has a 1 byte header specifying the type of payload it contains.

Packet Type 0x00 = HEARTBEAT

This type of packet has no payload. It is sent by the client to the server and helps ensure both ends of the connection know if the other end is alive.

Packet Type 0x01 = DATAGRAM

This packet encapsulates the datagram observed by the client. Here is its complete description:

Although this diagram should be self explanatory, here is a break down of all the fields:

  • Datagram Length: number of bytes of the encapsulated datagram (the DTEP header length is NOT included)
  • UDP Channel Address: destination address of the multicast group which the client joined to receive that datagram
  • UDP Channel Port: destination port of the multicast group which the client joined to receive that datagram
  • Encapsulated UDP Datagram: actual datagram received by the client from the multicast channel

Licensing

C.f. LICENSE

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].