Junglewise Threat Intelligence

CVE-2022-48828: Linux Kernel NFSD integer underflow in nfsd_setattr

CVE-2022-48828 · Severity: medium · CVSS 5.5 · Published 2024-07-16

Technologies: Linux Kernel. Vendors: Linux.

Executive brief

A vulnerability in the Linux kernel's Network File System (NFS) server could allow a local user to cause a system malfunction. By sending a specially crafted file size value that exceeds the system's handling capacity, an attacker can trigger an internal error. This primarily impacts the availability of the system, potentially leading to a denial-of-service condition.

Technical details

An integer underflow vulnerability exists in the Linux kernel's NFSD component within the nfsd_setattr() function. The issue stems from a type mismatch where NFSv3 and NFSv4 define file sizes as unsigned 64-bit integers, but the kernel's internal iattr::ia_size (loff_t) is a signed 64-bit integer. When decode_fattr4() or similar functions process a value larger than S64_MAX, it results in a negative value in ia_size. An attacker with local access can exploit this by sending malformed NFS requests to trigger unexpected behavior or a denial of service. The fix involves validating that ia_size is not negative in the common nfsd_setattr() path and returning an EFBIG error if it is.

Affected products

  • Linux Linux Kernel versions up to 5.4.295; 5.5 to 5.10.220; 5.11 to 5.15.24; 5.16 to 5.16.10; 5.17-rc1 to 5.17-rc3

Timeline

  • 2022-01-31: other: Patch authored
  • 2024-07-16: advisory: NVD published date

References

Related threats