freebsd-nq/sys/rpc
Rick Macklem 984c71f903 nfsd: Fix the failure return for non-fh NFSv4 operations
Without this patch, nfsd_checkrootexp() returns failure
and then the NFSv4 operation would reply NFSERR_WRONGSEC.
RFC5661 Sec. 2.6 only allows a few NFSv4 operations, none
of which call nfsv4_checktootexp(), to return NFSERR_WRONGSEC.
This patch modifies nfsd_checkrootexp() to return the
error instead of a boolean and sets the returned error to an RPC
layer AUTH_ERR, as discussed on nfsv4@ietf.org.
The patch also fixes nfsd_errmap() so that the pseudo
error NFSERR_AUTHERR is handled correctly such that an RPC layer
AUTH_ERR is replied to the NFSv4 client.

The two new "enum auth_stat" values have not yet been assigned
by IANA, but are the expected next two values.

The effect on extant NFSv4 clients of this change appears
limited to reporting a different failure error when a
mount that does not use adequate security is attempted.

MFC after:	2 weeks
2021-06-02 15:28:07 -07:00
..
rpcsec_gss rpcsec_gss: Use a designated initializer for rpc_gss_ops 2021-05-26 10:45:40 -04:00
rpcsec_tls nfs-over-tls: handle res.gid.gid_val correctly for memory allocation 2021-01-12 13:59:52 -08:00
auth_none.c
auth_unix.c
auth.h nfsd: Fix the failure return for non-fh NFSv4 operations 2021-06-02 15:28:07 -07:00
authunix_prot.c
clnt_bck.c Add TLS support to the kernel RPC. 2020-08-22 03:57:55 +00:00
clnt_dg.c Change the xid for client side krpc over UDP to a global value. 2020-04-05 21:08:17 +00:00
clnt_rc.c nfsv4 client: do the BindConnectionToSession as required 2021-04-11 14:34:57 -07:00
clnt_stat.h
clnt_vc.c Add TLS support to the kernel RPC. 2020-08-22 03:57:55 +00:00
clnt.h nfsv4 client: do the BindConnectionToSession as required 2021-04-11 14:34:57 -07:00
getnetconfig.c
krpc.h nfsv4 client: do the BindConnectionToSession as required 2021-04-11 14:34:57 -07:00
netconfig.h
nettype.h
pmap_prot.h
replay.c
replay.h
rpc_callmsg.c
rpc_com.h
rpc_generic.c Add TLS support to the kernel RPC. 2020-08-22 03:57:55 +00:00
rpc_msg.h
rpc_prot.c Move M_RPC malloc type into XDR. Both RPC and XDR libraries use 2020-04-17 06:02:13 +00:00
rpc.h
rpcb_clnt.c
rpcb_clnt.h
rpcb_prot.c
rpcb_prot.h
rpcm_subs.h
rpcsec_gss.h
rpcsec_tls.h Add a new "tlscertname" NFS mount option. 2020-12-23 13:42:55 -08:00
svc_auth_unix.c
svc_auth.c Add TLS support to the kernel RPC. 2020-08-22 03:57:55 +00:00
svc_auth.h
svc_dg.c
svc_generic.c
svc_vc.c Add TLS support to the kernel RPC. 2020-08-22 03:57:55 +00:00
svc.c nfsd: fix a NFSv4.1 Linux client mount stuck in CLOSE_WAIT 2021-04-27 15:32:35 -07:00
svc.h Add TLS support to the kernel RPC. 2020-08-22 03:57:55 +00:00
types.h
xdr.h