bhyve slirp network backend improvements
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 05 Nov 2025 15:08:33 UTC
A while back I added a libslirp-based network backend to bhyve. It enables usermode networking, very similar to qemu's user networking, but with the limitation that only inbound connections to the VM are permitted. This limitation is imposed by the capsicum sandbox in which the VM runs. For my immediate purposes that was fine, but of course it's fairly limiting in general. I posted a patch which moves the backend into a separate process so that the guest can make outbound connections: https://reviews.freebsd.org/D53454 This is enabled by adding the "open" keyword to the slirp backend configuration. That is, "-s 4:0,virtio-net,slirp,open" will allow unrestricted connections from the guest. One can also add hostfwd rules as before. There's still a fair bit of libslirp configuration that isn't accessible, but this change will hopefully make the slirp backend more useful to many people. Comments on the patch or requests for additional features in this area would be welcome.