KernelScan.io

HIGH Introduced in 4.8

nfsd ModeCheck Panic

CVE-2026-89711

CVSS 8.2 / 10.0 NVD

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H

KernelScan AI7.5HIGH

01

In the Linux kernel, the following vulnerability has been resolved: NFSD: remove flawed WARN_ON_ONCE from nfsd_mode_check The header for commit e75b23f9e323 ("nfsd: check d_can_lookup in fh_verify of directories") details the assumption that justified adding the WARN_ON_ONCE to nfsd_mode_check(), that assumption is invalid (in the case of NFS reexport). When NFSD exports an NFS filesystem it is very possible for nfsd_mode_check() to encounter a @dentry that doesn't have i_op->lookup (see nfs_fhget()'s NFS_ATTR_FATTR_MOUNTPOINT and NFS_ATTR_FATTR_V4_REFERRAL handling, and d_flags_for_inode()). So remove nfsd_mode_check()'s WARN_ON_ONCE(). The nfserr_notdir return on that branch must stay. It guards the subsequent lookup_one_unlocked() -> __lookup_slow() path, which calls inode->i_op->lookup() with no NULL check, so returning nfserr_notdir is what keeps a client LOOKUP into such a @dentry from dereferencing a NULL method pointer.

02

Engine v0.6.0

Risk summary

An NFS client can trigger a kernel panic on a host running nfsd when it re-exports an NFS filesystem. The panic occurs because a WARN_ON_ONCE fires on a legitimate code path involving NFS mountpoints or referrals, which can be triggered by normal client LOOKUP operations.

Affectedfs/nfsd/nfsfh.c (nfsd)

Vulnerability analysis

When the kernel NFS server re-exports an NFS filesystem, directory entries representing NFS mountpoints or referrals lack a lookup inode operation. The server's mode-checking code contained a debug assertion that assumed all directories it sees must support lookup, which is not true for re-exported NFS filesystems. A client performing a LOOKUP into such a directory triggers the assertion, causing a kernel warning that, depending on configuration (panic_on_warn), can crash the system. The fix removes the flawed assertion while keeping the error return that prevents a subsequent NULL pointer dereference in the lookup path. The vulnerability is reachable from any NFS client that can access an export on the affected server, requiring no special privileges beyond network access to the NFS service.

03

BranchIntroducedFixed inPatch commit
5.104.85.10.270ae251937c6f0
6.14.86.1.1889f4434893a27
6.64.86.6.1572ef131323999
6.124.86.12.109b55b4d880bb0
7.24.87.2.4a275de3bac56
mainline4.87.3-rc1aa0cf48a448c
6.184.86.18.507ef182a8fe9c
5.154.85.15.221e145e8d67a5d
cip/6.124.86.12.111-cip32b55b4d880bb0