gsliepen / tinc

a VPN daemon
http://tinc-vpn.org/
Other
1.93k stars 283 forks source link

how to use tinc with vsock (for KVM/QEMU) #462

Open mabra opened 1 week ago

mabra commented 1 week ago

So far I remember, TINC may use different types of sockets, specified in "DeviceType". What to do to use VSOCK? This would make TINC able to connect to qemu/kvm gest from outside. Or how to use socat to bridge a host-running tincd to vsock? Are there examples? Thanks.

gsliepen commented 1 week ago

Hi, vsock is not meant for network communication, it's meant as a communication channel between guest agents and hypervisor services. If you want tinc on the host to connect to a network interface inside a guest, then use DeviceType multicast, vde or tap in combination with QEMU's -netdev socket, vde or tap respectively.

mabra commented 5 days ago

Hi, vsock is not meant for network communication, it's meant as a communication channel between guest agents and hypervisor services. If you want tinc on the host to connect to a network interface inside a guest, then use DeviceType multicast, vde or tap in combination with QEMU's -netdev socket, vde or tap respectively.

Thank you for your reply. "If you want tinc on the host to connect to a network interface inside a guest" Exactly what I want. I want me to prevent to have a TINC interface inside the guest, but inject packets to the LO(!) interface of the guest. I considered the "mention" of socket in the TINC docs to think, "if socket why not vsock" and I have not heared about "netdev socket" before. I started considering socat, but for your mentioned uses, are there probably any examples, where VDE is too less described to be ussable for me (and requires this additional software) ??