All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] rpc.nfsd: No longer advertise NFS v2 support.
@ 2013-07-28 18:36 Steve Dickson
  2013-07-28 18:36 ` [PATCH 2/2] rpc.nfsd: Allow v4.2 server support with the -V option Steve Dickson
  2013-07-30 15:51 ` [PATCH 1/2] rpc.nfsd: No longer advertise NFS v2 support J. Bruce Fields
  0 siblings, 2 replies; 7+ messages in thread
From: Steve Dickson @ 2013-07-28 18:36 UTC (permalink / raw)
  To: Linux NFS Mailing list

Changed the default protocol versions that rpc.nfsd
register with rpcbind to just 3 and 4. Version 2
can still be enabled with the '-V' flag, but it
will not be on by default.

Signed-off-by: Steve Dickson <steved@redhat.com>
---
 support/include/nfs/nfs.h | 1 +
 utils/nfsd/nfsd.c         | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/support/include/nfs/nfs.h b/support/include/nfs/nfs.h
index 174c2dd..5fd86f6 100644
--- a/support/include/nfs/nfs.h
+++ b/support/include/nfs/nfs.h
@@ -52,6 +52,7 @@ struct nfs_fh_old {
 #define NFSCTL_UDPISSET(_cltbits)     ((_cltbits) & NFSCTL_UDPBIT) 
 #define NFSCTL_TCPISSET(_cltbits)     ((_cltbits) & NFSCTL_TCPBIT) 
 
+#define NFSCTL_VERDEFAULT (0xc)       /* versions 3 and 4 */
 #define NFSCTL_VERSET(_cltbits, _v)   ((_cltbits) |= (1 << ((_v) - 1))) 
 #define NFSCTL_UDPSET(_cltbits)       ((_cltbits) |= NFSCTL_UDPBIT)
 #define NFSCTL_TCPSET(_cltbits)       ((_cltbits) |= NFSCTL_TCPBIT)
diff --git a/utils/nfsd/nfsd.c b/utils/nfsd/nfsd.c
index e87c0a9..df48392 100644
--- a/utils/nfsd/nfsd.c
+++ b/utils/nfsd/nfsd.c
@@ -100,7 +100,7 @@ main(int argc, char **argv)
 	char *haddr = NULL;
 	int	socket_up = 0;
 	int minorvers41 = 0;	/* nfsv4 minor version */
-	unsigned int versbits = NFSCTL_ALLBITS;
+	unsigned int versbits = NFSCTL_VERDEFAULT;
 	unsigned int protobits = NFSCTL_ALLBITS;
 	unsigned int proto4 = 0;
 	unsigned int proto6 = 0;
-- 
1.8.1.4


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2013-08-19 18:26 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-28 18:36 [PATCH 1/2] rpc.nfsd: No longer advertise NFS v2 support Steve Dickson
2013-07-28 18:36 ` [PATCH 2/2] rpc.nfsd: Allow v4.2 server support with the -V option Steve Dickson
2013-07-30 15:59   ` J. Bruce Fields
2013-07-30 16:09     ` Myklebust, Trond
2013-07-30 20:29       ` J. Bruce Fields
2013-08-19 18:26   ` Steve Dickson
2013-07-30 15:51 ` [PATCH 1/2] rpc.nfsd: No longer advertise NFS v2 support J. Bruce Fields

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.