TUN is a virtual network layer device which operates in OSI layer 3.
Questions tagged [tun]
149 questions
0
votes
1 answer
Terminal not seeing ping messages from TUN port
Hi I'm working on a project and I had a question involving ping commands and how they interface over network TUN ports.
Basically I'm sending out ping requests which are routed to my TUN port and the reply's are sent to the TUN port over the VPN.…

fmc5046
- 73
- 1
- 1
- 4
0
votes
0 answers
ip link set command throws error.RTNETLINK answers: Operation not permitted
I am using linux mint.I want to set up a tun virtual Ethernet device.
sudo ip tuntap add dev tun0 mod tun
sudo ip address add 192.168.82.22/24 dev tun0
sudo ip link set dev tun0 address 54:e1:ad:b9:12:ee
the last command throws out a…

conquer66666
- 59
- 1
- 10
0
votes
1 answer
How to handle the leading 4-byte protocol of tun FD packets when reading tun FD directly in C instead of through packetFlow.readPackets in Swift?
In iOS SimpleTunnel VPN demo app, it reads the virtual tun interface through packetFlow.readPackets(). In my case, Swift hands over control to C to move data packets between the tunnel and the virtual tun interface. The tun file descriptor will be…

Jim
- 51
- 3
0
votes
1 answer
Why tun/tap multiqueue can not balance between each queue?
refer: tuntap
I have create multithread for each tun/tap queue. And each thread use their own libev loop. And when use ping to create low-speed flow, every queue will be awakened. But when use iperf3 create high-speed flow, all packet will be…

jianxi sun
- 340
- 1
- 19
0
votes
1 answer
TCP push packet not delivered from tun
I setup simple packet intercept program, using two tuns, setup like this:
# ip tuntap add mode tun name tun0
# ip link set tun0 up
# ip addr add 10.0.0.0/31 dev tun0
# ip tuntap add mode tun name tun1
# ip link set tun1 up
# ip addr add 10.0.1.0/31…

Kyras
- 63
- 1
- 5
0
votes
1 answer
Server in Go not listening on tun0
I'm running a simple, standard Go TCP server and I want to bind it to my tun0 interface.
The server is:
func main() {
conn, err := net.Listen("tcp", "10.1.0.21:4444")
if err != nil {
fmt.Println(err)
return
}
defer…

xijitir563
- 1
- 1
0
votes
1 answer
How to receive data from tun interface to dpdk binded NIC?
I want to have any Traffic generator(say iperf,D-ITG or even ping) to send data to a tun interface. This tun interface should automatically forward to NIC which is binded to DPDK. I want to run l3fwd example which picks up data from the interface.
I…

Vishal
- 11
- 6
0
votes
1 answer
Requested registry access is not allowed. even with signed exe and admin Privileged in manifest
I am trying to access HKEY_LOCAL_MACHINE registry,
This is the manifest file:

BluePrion
- 26
- 5
0
votes
1 answer
writing data to linux tun interface
i have created a linux tun interface, set ipaddr, broadcast etc.. using open/ioctl apis.
This is how the tun interface looks like,
TEST_TUN: mtu 1500 qdisc pfifo_fast state UNKNOWN group default qlen 500
link/none
inet 45.45.45.1/24 scope…

guru
- 11
- 1
- 3
0
votes
1 answer
kernel not echo ICMP ping package written to tun device?
I am trying to write a vpn server on my vps. I have setup the tun interface < tun2 > and the packages that received from network can be written to tun device on the server. However when I test the connectivity by ping command from client, there is…

sevenever
- 773
- 1
- 8
- 14
0
votes
1 answer
How to connect the host to her virtual bridge?
A bridge brOnline is connected to eth0 which provides access to the LAN / Internet. The setup is archived within modifying /etc/network/interfaces like below.
Why? The aim of this adventure is establish a virtual network between several virtual…

Cutton Eye
- 3,207
- 3
- 20
- 39
0
votes
0 answers
Tun interface and IPv6
I'd like to ask you a question about tun interfaces, but without OpenVPN.
I have two applications that tunnel traffic:
"sgsn userspace app" reads IP packets from the tun interface "tun sgsn", sends them to "ggsn userspace app", this app writes them…

Gloria Pozuelo
- 1
- 1
0
votes
1 answer
Connecting a Tun to a socket
I want to connect a Tun to a socket so that whatever data is stored in the Tun file will then end up being pushed out to a socket which will receive the data. I am struggling with the higher level conceptual understanding of how I am supposed to…

user3662531
- 71
- 1
- 7
0
votes
2 answers
How to send untouched tun packets?
I have a software which uses a TUN device to read datapackets, process something on them and send them out. Now I am asking myself, if it is possible, to send the "tun packets" without touching them.
Over the TUN device I get IP Packets but over a…

JUehV
- 53
- 7
0
votes
1 answer
How to overcome TUN.KO driver issue in Android for VPN
How to overcome "Tun.ko" driver issue in few android devices because of which VPN never connects. Is there any way to identify the presence of "Tun.ko" driver and disable VPN or if possible to install driver without rooting?
Thanks

user45678
- 1,504
- 6
- 29
- 58