diff mbox series

[4/5] nfs: Fix -o sec=none output in /proc/mounts

Message ID 20240912130220.17032-5-pali@kernel.org (mailing list archive)
State New
Headers show
Series nfs: Fix mounting NFS3 AUTH_NULL exports | expand

Commit Message

Pali Rohár Sept. 12, 2024, 1:02 p.m. UTC
Linux nfs userspace tools supports AUTH_NULL flavor under name 'none'.
This name is used in /etc/exports file and also in '-o sec' mount option.

So for compatibility show AUTH_NULL flavor in /proc/mounts output as 'none'
instead of 'null'.

Signed-off-by: Pali Rohár <pali@kernel.org>
Cc: stable@vger.kernel.org
---
 fs/nfs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/fs/nfs/super.c b/fs/nfs/super.c
index 4cb319be55ca..86d98d15ee22 100644
--- a/fs/nfs/super.c
+++ b/fs/nfs/super.c
@@ -321,7 +321,7 @@  static const char *nfs_pseudoflavour_to_name(rpc_authflavor_t flavour)
 		const char *str;
 	} sec_flavours[NFS_AUTH_INFO_MAX_FLAVORS] = {
 		/* update NFS_AUTH_INFO_MAX_FLAVORS when this list changes! */
-		{ RPC_AUTH_NULL, "null" },
+		{ RPC_AUTH_NULL, "none" },
 		{ RPC_AUTH_UNIX, "sys" },
 		{ RPC_AUTH_GSS_KRB5, "krb5" },
 		{ RPC_AUTH_GSS_KRB5I, "krb5i" },