[Bug 262676] vimage: on starting jail instant kernel panic

From: <bugzilla-noreply_at_freebsd.org>
Date: Sun, 18 Dec 2022 20:55:48 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=262676

--- Comment #7 from Dirk Meyer <dinoex@FreeBSD.org> ---
Inside the jail:

# /etc/pf.conf
nat on tun0 from any to any -> (tun0)
nat on tun1 from any to any -> (tun1)
pass quick on lo0
pass quick on epair1b
pass quick on vlan14
pass quick on tun0
# eof


It might be related that vimage/vnet jails in 13.x have their own fibs.
Previously the number of fibs have been inherited.
Now each jail can have its own set, defaults to 0.

# sysctl net.fibs
net.fibs: 8

# jexec 3 sysctl net.fibs
net.fibs: 1

# jexec 3 setfib 4 netstat -nr4
setfib: 4: invalid FIB (max 0)

So moving an Interface with fib set in the jail may cause the crash.

Should there be an out of bounds check?
Or Should the fib reset on attach?

-- 
You are receiving this mail because:
You are the assignee for the bug.