Recent versions of iproute2
have native tun/tap support:
~$ip tuntap help Usage: ip tuntap { add | del } [ dev PHYS_DEV ] [ mode { tun | tap } ] [ user USER ] [ group GROUP ] [ one_queue ] [ pi ] [ vnet_hdr ] Where: USER := { STRING | NUMBER } GROUP := { STRING | NUMBER } |
To create a tap (or tun) interface for the openwsn user:
~$sudo ip tuntap add dev mytun mode tun user openwsn ~$sudo ip link set mytun up ~$sudo ip addr add 10.0.0.1/24 dev mytun |
References: