This is the libvdeplug plugin module to join slirp networks. It is based on the libvdeslirp library.
This module of libvdeplug4 can be used in any program supporting VDE like vde_plug, vdens, kvm, qemu, user-mode-linux
and virtualbox
.
Requirements: vdeplug4 and libvdeslirp.
vdeplug_slirp
uses cmake, so the standard procedure to build and install
this vdeplug plugin module is the following:
$ mkdir build
$ cd build
$ cmake ..
$ make
$ sudo make install
vdens -R 10.0.2.3 slirp://
Inside the namespace the ip address can be defined by hand or using a dhcp client. e.g.:
/sbin/udhcpc -i vde0
vde_plug vxvde:// slirp://
TCP port 8080 is forwarded to port 80 of 10.0.2.15
vde_plug tap://mytap slirp:///tcpfwd=8080:10.0.2.15:80"
kvm .... -device e1000,netdev=vde0,mac=52:54:00:00:00:01 -netdev vde,id=vde0,sock="slirp:///addr=10.1.1.2"
This version obsoletes the previous implementation based on the deprecated old libslirp.
The only feature still unimplemented in this new code is the redirection to a unix port. We are working to add this missing feature.