]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
krpc: Allow mountd/nfsd to optionally run in a jail
authorRick Macklem <rmacklem@FreeBSD.org>
Sun, 18 Dec 2022 20:40:48 +0000 (12:40 -0800)
committerRick Macklem <rmacklem@FreeBSD.org>
Sun, 18 Dec 2022 20:40:48 +0000 (12:40 -0800)
commit6a76d35cac8e1549f74bd4cdceccc2ee52c8e556
treec95be8faefc53cb6f6628ecb4d83c55a75d966a6
parenta48301a5e0947a261400cc26fb0f57a499b332c6
krpc: Allow mountd/nfsd to optionally run in a jail

This patch modifies the kernel RPC so that it will allow
mountd/nfsd to run inside of a vnet jail.  Running mountd/nfsd
inside a vnet jail will be enabled via a new kernel build
option called VNET_NFSD, which will be implemented in future
commits.

Although I suspect cr_prison can be set from the credentials
of the current thread unconditionally, I #ifdef'd the code
VNET_NFSD and only did this for the jailed case mainly to
document that it is only needed for use in a jail.

The TLS support code has not yet been modified to work in
a jail.  That is planned as future development after the
basic VNET_NFSD support is in the kernel.

This patch should not result in any semantics change until
VNET_NFSD is implemented and used in a kernel configuration.

MFC after: 4 months
sys/rpc/rpcsec_gss/svc_rpcsec_gss.c
sys/rpc/svc.c
sys/rpc/svc_auth.c
sys/rpc/svc_dg.c