diff options
| author | Chuck Lever <chuck.lever@oracle.com> | 2025-09-17 10:31:40 -0400 |
|---|---|---|
| committer | Chuck Lever <chuck.lever@oracle.com> | 2025-11-16 18:20:11 -0500 |
| commit | ccd608e29b7a73b7bee45b06bfeef088a97c4c92 (patch) | |
| tree | cfd27556159a76fdebebc47221c08a5047bb85d4 /tools/lib/python/kdoc/python_version.py | |
| parent | b5fc406bc730806662429272300fb56e4e6592d8 (diff) | |
NFSD: Add array bounds-checking in nfsd_iter_read()
The *count parameter does not appear to be explicitly restricted
to being smaller than rsize, so it might be possible to overrun
the rq_bvec or rq_pages arrays.
Rather than overrunning these arrays (damage done!) and then WARNING
once, let's harden the loop so that it terminates before the end of
the arrays are reached. This should result in a short read, which is
OK -- clients recover by sending additional READ requests for the
remaining unread bytes.
Reported-by: NeilBrown <neil@brown.name>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Reviewed-by: Mike Snitzer <snitzer@kernel.org>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Diffstat (limited to 'tools/lib/python/kdoc/python_version.py')
0 files changed, 0 insertions, 0 deletions
