Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP2:Update
nfs-utils.12300
0003-mountd-Don-t-export-unmounted-exports-to-N...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0003-mountd-Don-t-export-unmounted-exports-to-NFSv4.patch of Package nfs-utils.12300
From d2eefb393dc6eebf83baf78e261c5c8904c8b18d Mon Sep 17 00:00:00 2001 From: NeilBrown <neilb@suse.com> Date: Wed, 13 Jul 2016 11:56:14 +1000 Subject: [PATCH] mountd: Don't export unmounted exports to NFSv4 An export point with the "mountpoint" option should not be exported if it isn't a mount point. For NFSv3, this is handled primarily by failing the MOUNT request. For NFSv4, we must ensure a lookup from the pseduo-root fails too. This means nfsd_export must check for the 'mountpoint' option and handle it correctly. Signed-off-by: NeilBrown <neilb@suse.com> --- utils/mountd/cache.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) --- a/utils/mountd/cache.c +++ b/utils/mountd/cache.c @@ -1217,7 +1217,12 @@ static void nfsd_export(FILE *f) found = lookup_export(dom, path, ai); if (found) { - if (dump_to_cache(f, dom, path, &found->m_export) < 0) { + if (found->m_export.e_mountpoint && + !is_mountpoint(found->m_export.e_mountpoint[0]? + found->m_export.e_mountpoint: + found->m_export.e_path)) + dump_to_cache(f, dom, path, NULL); + else if (dump_to_cache(f, dom, path, &found->m_export) < 0) { xlog(L_WARNING, "Cannot export %s, possibly unsupported filesystem" " or fsid= required", path);
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor