[PATCH v3 0/7] NFSD size, offset, and count sanity

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Dan Aloni reported a problem with the way NFSD's READ implementation
deals with the very upper end of file sizes, and I got interested in
how some of the other operations handled it. I found some issues,
and have started a (growing) pile of patches to deal with them.

Since at least the SETATTR case appears to cause a crash on some
filesystems, I think several of these are 5.17-rc fodder (i.e.,
priority bug fixes).

I've already posted an update to the pynfs CMT4 test. A similar
pynfs test for out-of-range READ is forthcoming.

Changes since v2:
- Addressed concerns with "Fix NFSv3 SETATTR/CREATE's handling of
  large file sizes"
- Added fix for READ underflow, as initially reported; series is now
  complete
- Trace points now report wire input values before type cast

Changes since RFC:
- Series reordered so priority fixes come first
- Setattr size check is now in a common function
- Patch descriptions clarified

---

Chuck Lever (7):
      NFSD: Fix the behavior of READ near OFFSET_MAX
      NFSD: Fix ia_size underflow
      NFSD: Fix NFSv3 SETATTR/CREATE's handling of large file sizes
      NFSD: Clamp WRITE offsets
      NFSD: COMMIT operations must not return NFS?ERR_INVAL
      NFSD: Fix offset type in I/O trace points
      NFSD: Deprecate NFS_OFFSET_MAX


 fs/nfsd/nfs3proc.c  | 19 ++++++++-------
 fs/nfsd/nfs3xdr.c   |  4 ++--
 fs/nfsd/nfs4proc.c  | 13 +++++++----
 fs/nfsd/nfs4xdr.c   | 10 +++-----
 fs/nfsd/trace.h     | 14 +++++------
 fs/nfsd/vfs.c       | 57 +++++++++++++++++++++++++++++++--------------
 fs/nfsd/vfs.h       |  4 ++--
 include/linux/nfs.h |  8 -------
 8 files changed, 74 insertions(+), 55 deletions(-)

--
Chuck Lever



[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux