Re: [PATCH] SUNRPC: copy the GSS init token with read_bytes_from_xdr_buf()
From: Chuck Lever
Date: Fri Nov 20 2026 - 17:46:45 EST
On Fri, 20 Nov 2026 01:00:07 -0500, Yiran Qiu wrote:
> gss_read_proxy_verf() copies the token from the head of rq_arg and then
> from rq_arg.pages, assuming the rest of the token is in the page list.
> svcrdma rebuilds a Call that carries one Read chunk as head (inline data
> before the chunk position), pages (the chunk) and tail (inline data
> after it), and xdr_stream_remaining() counts the tail. When the token
> starts at the chunk and continues into the tail, the copy runs past the
> chunk's pages. If the chunk fills rq_pages, the copy takes the NULL
> entry at rq_pages[rq_maxpages] and memcpy() reads from
> page_address(NULL); otherwise the stale contents of the next page go to
> gssproxy in place of the tail. This runs in svcauth_gss_proxy_init()
> before any credential is checked, so a client of an NFS/RDMA server that
> uses gssproxy can oops nfsd threads without authenticating.
>
> [...]
Applied to nfsd-testing, thanks!
[1/1] SUNRPC: copy the GSS init token with read_bytes_from_xdr_buf()
commit: 6d817b9ca893bc2603446e340030e149e5c8b207
--
Chuck Lever <cel@xxxxxxxxxx>