Date: Mon, 16 Sep 2019 16:41:01 +0000 (UTC) From: Alan Somers <asomers@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r352417 - head/sys/fs/fuse Message-ID: <201909161641.x8GGf1p8017637@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: asomers Date: Mon Sep 16 16:41:01 2019 New Revision: 352417 URL: https://svnweb.freebsd.org/changeset/base/352417 Log: Fix an off-by-one error from r351961 That revision addressed a Coverity CID that could lead to a buffer overflow, but it had an off-by-one error in the buffer size check. Reported by: Coverity Coverity CID: 1405530 MFC after: 3 days MFC-With: 351961 Sponsored by: The FreeBSD Foundation Modified: head/sys/fs/fuse/fuse_internal.c Modified: head/sys/fs/fuse/fuse_internal.c ============================================================================== --- head/sys/fs/fuse/fuse_internal.c Mon Sep 16 16:17:29 2019 (r352416) +++ head/sys/fs/fuse/fuse_internal.c Mon Sep 16 16:41:01 2019 (r352417) @@ -390,7 +390,7 @@ fuse_internal_invalidate_entry(struct mount *mp, struc if ((err = uiomove(&fnieo, sizeof(fnieo), uio)) != 0) return (err); - if (fnieo.namelen > sizeof(name)) + if (fnieo.namelen >= sizeof(name)) return (EINVAL); if ((err = uiomove(name, fnieo.namelen, uio)) != 0)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201909161641.x8GGf1p8017637>