Source-Changes-HG archive

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

[src/netbsd-9]: src/external/cddl/osnet/dist/uts/common/fs/zfs/sys Pull up fo...



details:   https://anonhg.NetBSD.org/src/rev/526f339169be
branches:  netbsd-9
changeset: 964337:526f339169be
user:      martin <martin%NetBSD.org@localhost>
date:      Mon Mar 22 18:22:59 2021 +0000

description:
Pull up following revision(s) (requested by hannken in ticket #1235):

        external/cddl/osnet/dist/uts/common/fs/zfs/sys/zfs_context.h: revision 1.3

Use the right uid / gid for nobody:nobody like FreeBSD does.

Prevents null pointer dereferences when ZFS replaces this
illegal (according to IS_EPHEMERAL()) id with another
illegal id in operation zfs_fuid_create_cred() and
finally zfs_log_create() dereferences fuidp being NULL.

Adresses PR misc/55042 (Panic when creating a directory on a NFS served ZFS)

diffstat:

 external/cddl/osnet/dist/uts/common/fs/zfs/sys/zfs_context.h |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (19 lines):

diff -r ff7c77e8be93 -r 526f339169be external/cddl/osnet/dist/uts/common/fs/zfs/sys/zfs_context.h
--- a/external/cddl/osnet/dist/uts/common/fs/zfs/sys/zfs_context.h      Mon Mar 22 18:20:38 2021 +0000
+++ b/external/cddl/osnet/dist/uts/common/fs/zfs/sys/zfs_context.h      Mon Mar 22 18:22:59 2021 +0000
@@ -157,13 +157,13 @@
 #define fm_panic                       panic
 #define getf                           fd_getfile
 #define getminor(a)                    minor(a)
-#define GID_NOBODY                     (-2)
+#define GID_NOBODY                     (39)
 #define issig(x)                       (sigispending(curlwp, 0))
 #define kmem_debugging()               0
 #define releasef                       fd_putfile
 #define strfree(str)                   kmem_free((str), strlen(str)+1)
 #define td_ru                          l_ru
-#define UID_NOBODY                     (-2)
+#define UID_NOBODY                     (32767)
 #define vnode_pager_setsize(vp, size)  zfs_netbsd_setsize(vp, size)
 #define zone_get_hostid(a)             0
 



Home | Main Index | Thread Index | Old Index