Support for libslirp
Describe the solution you'd like Idea is to implement libslirp or equivalent networking model for macvz.
With this implementation, we should be able to resolve issues around vpn connection and at the same time with support for multiple network interface we should be able to provide network access among VMs using NAT or Bridge Network support from Apple Virtualization
A clear and concise description of what you want to happen.
Describe alternatives you've considered
- Go binding for libslirp - Gives easier integration within our code
- gvisor-tap-vsock - Example under gvisor branch. One consern is support for arm64 (haven't tested yet)
Additional context Supporting both the architecture is a important one.
The following are the results from the spikes done as of now for this, libslirp Was able to integrate slirp like network using libslirp-rs cli.
- Noticed increased cpu utilisation compared to using NAT
- speedtest results download speed - 250mbps, upload speed - 100mbps
gvisor-tap-vsock Was able to integrate slirp like network but having issues with respect to https packets. Needs further analysis on this to properly support raw dgram sockets.
- Better CPU utilisation
- Golang Integration, we could make use of portfowarding rest API as well
Both these should be tested in mac m1 as well
gvisor-tap-vsock After version upgrade of gvisor, working seemlessly with Virtualization framework. https://github.com/balajiv113/gvisor-tap-vsock
We will proceed with this integration, as this has direct golang integration and has better performance than libslirp-cli