Replace KAUTH_GENERIC_ISSUSER with a better alternative.

This commit is contained in:
elad 2009-05-07 20:32:51 +00:00
parent 88003af1dc
commit 13385da3e6
1 changed files with 4 additions and 4 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: lfs_vnops.c,v 1.220 2009/02/22 20:28:07 ad Exp $ */
/* $NetBSD: lfs_vnops.c,v 1.221 2009/05/07 20:32:51 elad Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@ -60,7 +60,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: lfs_vnops.c,v 1.220 2009/02/22 20:28:07 ad Exp $");
__KERNEL_RCSID(0, "$NetBSD: lfs_vnops.c,v 1.221 2009/05/07 20:32:51 elad Exp $");
#ifdef _KERNEL_OPT
#include "opt_compat_netbsd.h"
@ -1544,8 +1544,8 @@ lfs_fcntl(void *v)
#ifdef COMPAT_30
case LFCNIFILEFH_COMPAT:
/* Return the filehandle of the Ifile */
if ((error = kauth_authorize_generic(l->l_cred,
KAUTH_GENERIC_ISSUSER, NULL)) != 0)
if ((error = kauth_authorize_system(l->l_cred,
KAUTH_SYSTEM_FILEHANDLE, 0, NULL, NULL, NULL)) != 0)
return (error);
fhp = (struct fhandle *)ap->a_data;
fhp->fh_fsid = *fsidp;