From 030393152fe6e7660cc4464be8b65ec1d6ecbbc5 Mon Sep 17 00:00:00 2001 From: Shehjar Tikoo Date: Tue, 9 Nov 2010 00:36:24 +0000 Subject: mnt3: Fail mount requests for disallowed clients Signed-off-by: Shehjar Tikoo Signed-off-by: Anand V. Avati BUG: 1385 (showmount says no access though it can be mounted.) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1385 --- xlators/nfs/server/src/mount3.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'xlators/nfs/server/src/mount3.c') diff --git a/xlators/nfs/server/src/mount3.c b/xlators/nfs/server/src/mount3.c index 47158dcc..2e4a7390 100644 --- a/xlators/nfs/server/src/mount3.c +++ b/xlators/nfs/server/src/mount3.c @@ -767,10 +767,11 @@ mnt3svc_mnt (rpcsvc_request_t *req) } ret = mnt3_check_client_net (ms, req, exp->vol); - if (ret == -1) { + if (ret == RPCSVC_AUTH_REJECT) { mntstat = MNT3ERR_ACCES; gf_log (GF_MNT, GF_LOG_DEBUG, "Client mount not allowed"); - goto rpcerr; + ret = -1; + goto mnterr; } ret = mnt3svc_mount (req, ms, exp); -- cgit