kernel-fxtec-pro1x/net/sunrpc
Martijn de Gouw af74b4a25f SUNRPC: fix copying of multiple pages in gss_read_proxy_verf()
[ Upstream commit d48c8124749c9a5081fe68680f83605e272c984b ]

When the passed token is longer than 4032 bytes, the remaining part
of the token must be copied from the rqstp->rq_arg.pages. But the
copy must make sure it happens in a consecutive way.

With the existing code, the first memcpy copies 'length' bytes from
argv->iobase, but since the header is in front, this never fills the
whole first page of in_token->pages.

The mecpy in the loop copies the following bytes, but starts writing at
the next page of in_token->pages.  This leaves the last bytes of page 0
unwritten.

Symptoms were that users with many groups were not able to access NFS
exports, when using Active Directory as the KDC.

Signed-off-by: Martijn de Gouw <martijn.de.gouw@prodrive-technologies.com>
Fixes: 5866efa8cbfb "SUNRPC: Fix svcauth_gss_proxy_init()"
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-10-30 10:38:23 +01:00
..
auth_gss SUNRPC: fix copying of multiple pages in gss_read_proxy_verf() 2020-10-30 10:38:23 +01:00
xprtrdma svcrdma: fix bounce buffers for unaligned offsets and multiple pages 2020-10-30 10:38:22 +01:00
addr.c net: sunrpc: Fix off-by-one issues in 'rpc_ntop6' 2020-06-25 15:33:00 +02:00
auth.c
auth_generic.c SUNRPC: Fix a bogus get/put in generic_key_to_expire() 2018-12-01 09:37:33 +01:00
auth_null.c
auth_unix.c
backchannel_rqst.c sunrpc: whitespace fixes 2018-07-31 12:53:40 -04:00
cache.c sunrpc: fix crash when cache_head become valid before update 2019-12-17 20:35:52 +01:00
clnt.c net :sunrpc :clnt :Fix xps refcount imbalance on the error path 2019-07-14 08:11:15 +02:00
debugfs.c
Kconfig
Makefile
netns.h
rpc_pipe.c sunrpc: fixed rollback in rpc_gssd_dummy_populate() 2020-06-30 23:17:18 -04:00
rpcb_clnt.c SUNRPC: stop printk reading past end of string 2020-09-23 12:10:58 +02:00
sched.c SUNRPC: Fix priority queue fairness 2019-11-24 08:19:24 +01:00
socklib.c
stats.c sunrpc: whitespace fixes 2018-07-31 12:53:40 -04:00
sunrpc.h sunrpc: whitespace fixes 2018-07-31 12:53:40 -04:00
sunrpc_syms.c
svc.c sunrpc: use-after-free in svc_process_common() 2019-01-16 22:04:37 +01:00
svc_xprt.c SUNRPC: Fix a potential buffer overflow in 'svc_print_xprts()' 2020-10-01 13:14:40 +02:00
svcauth.c
svcauth_unix.c
svcsock.c svcrdma: Fix leak of svc_rdma_recv_ctxt objects 2020-05-02 17:25:52 +02:00
sysctl.c
timer.c
xdr.c SUNRPC: Properly set the @subbuf parameter of xdr_buf_subsegment() 2020-06-30 23:17:18 -04:00
xprt.c sunrpc: Fix connect metrics 2019-11-24 08:19:49 +01:00
xprtmultipath.c
xprtsock.c sunrpc: safely reallow resvport min/max inversion 2019-12-01 09:16:41 +01:00