Saturday, August 26, 2017

connect udp tunnel to linux host

1- install ubridge
$ git clone
$ cd ubridge
$ make
$ sudo make install

2- virtualbox udp tunnel interface configure as below

Device -- > network --> Adaptor number -->
- attached to :generic driver
- Name :UDPtunnel
- Generic properties:

3- start ubridge in supervision mode
$ ubridge -H 2222

- create bridge and add ports to the bridge
$ telnet localhost 2222
bridge create br0
bridge add_nio_tap br0 tap0
bridge add_nio_udp br0 10005 10001

bridge start br0

now, tap0 will be appear in network interface list and it is paired with virtualbox udp tunnel interface

to show the bridge
bridge show br0
101 bridge 'br0' is running
101 Source NIO: tap1
101 Destination NIO: 30000:

we can also start with configuration file, so no need to do with cli, below is the example of the ubridge.ini file

    ; bridge Ethernet interface eth0 with an UDP tunnel
    source_ethernet = eth0
    destination_udp = 10000: ; syntax is local_port:remote_host:remote_port

    ; bridge TAP interface tap0 with an UDP tunnel
    ; and capture packets to /tmp/bridge1.pcap
    source_tap = tap0
    destination_udp = 11000:
    pcap_file = /tmp/bridge1.pcap
    pcap_protocol = EN10MB ; PCAP data link type, default is EN10MB

    ; it is even possible to bridge two UDP tunnels and capture!
    source_udp = 40000:
    destination_udp = 50000:
    pcap_file = /tmp/bridge2.pcap

    ; or to bridge 2 interfaces
    source_tap = tap0
    destination_ethernet = vmnet2

1 comment:

  1. Its not at all an easy task to connect udp tunnel to linux host,but with your proper guidance thabfully I have been able to do so.