Date: Thu, 16 Nov 2006 19:11:29 GMT From: Todd Miller <millert@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 110119 for review Message-ID: <200611161911.kAGJBTej065386@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=110119 Change 110119 by millert@millert_macbook on 2006/11/16 19:11:19 Update vanity policy with fdesc-related entrypoints Affected files ... .. //depot/projects/trustedbsd/sedarwin8/policies/vanity/vanity.c#9 edit Differences ... ==== //depot/projects/trustedbsd/sedarwin8/policies/vanity/vanity.c#9 (text+ko) ==== @@ -3,6 +3,9 @@ #include <sys/kernel.h> #include <sys/sysctl.h> +#include <sys/posix_sem.h> +#include <sys/posix_shm.h> +#include <sys/pipe.h> #include <sys/proc.h> #include <sys/file_internal.h> #include <sys/mount_internal.h> @@ -116,12 +119,58 @@ } static void +vanity_vnode_label_associate_file(struct ucred *cred, + struct mount *mp, struct label *mntlabel, + struct fileglob *fg, struct label *label, + struct vnode *vp, struct label *vlabel) +{ + if (vp->v_lflag & VL_LABELED) + v_print("VANITY: vanity_vnode_label_associate_file() already associated", vp); +} + +static void +vanity_vnode_label_associate_posixshm(struct ucred *cred, + struct pshminfo *pshm, struct label *pshmlabel, + struct vnode *vp, struct label *vlabel) +{ + if (vp->v_lflag & VL_LABELED) + v_print("VANITY: vanity_vnode_label_associate_posixshm() already associated", vp); +} + +static void +vanity_vnode_label_associate_posixsem(struct ucred *cred, + struct pseminfo *psem, struct label *psemlabel, + struct vnode *vp, struct label *vlabel) +{ + if (vp->v_lflag & VL_LABELED) + v_print("VANITY: vanity_vnode_label_associate_posixsem() already associated", vp); +} + +static void +vanity_vnode_label_associate_pipe(struct ucred *cred, + struct pipe *cpipe, struct label *pipelabel, + struct vnode *vp, struct label *vlabel) +{ + if (vp->v_lflag & VL_LABELED) + v_print("VANITY: vanity_vnode_label_associate_pipe() already associated", vp); +} + +static void vanity_vnode_label_associate_singlelabel(struct mount *mp, struct label *mntlabel, struct vnode *vp, struct label *vlabel) { if (vp->v_lflag & VL_LABELED) v_print("VANITY: vanity_vnode_label_associate_singlelabel() already associated", vp); } +static void +vanity_vnode_label_associate_socket(struct ucred *cred, + struct xsocket *xso, struct label *solabel, + struct vnode *vp, struct label *vlabel) +{ + if (vp->v_lflag & VL_LABELED) + v_print("VANITY: vanity_vnode_label_associate_socket() already associated", vp); +} + static int vanity_vnode_notify_create(struct ucred *cred, struct mount *mp, struct label *mntlabel, struct vnode *dvp, struct label *dlabel, struct vnode *vp, struct label *vlabel, struct componentname *cnp) { @@ -476,7 +525,12 @@ .mpo_vnode_label_update_extattr = vanity_vnode_label_update_extattr, .mpo_vnode_label_associate_devfs= vanity_vnode_label_associate_devfs, .mpo_vnode_label_associate_extattr= vanity_vnode_label_associate_extattr, + .mpo_vnode_label_associate_file = vanity_vnode_label_associate_file, .mpo_vnode_label_associate_singlelabel= vanity_vnode_label_associate_singlelabel, + .mpo_vnode_label_associate_posixshm= vanity_vnode_label_associate_posixshm, + .mpo_vnode_label_associate_posixsem= vanity_vnode_label_associate_posixsem, + .mpo_vnode_label_associate_pipe = vanity_vnode_label_associate_pipe, + .mpo_vnode_label_associate_socket= vanity_vnode_label_associate_socket, .mpo_vnode_notify_create = vanity_vnode_notify_create, .mpo_vnode_label_update = vanity_vnode_label_update, .mpo_vnode_label_store = vanity_vnode_label_store,
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200611161911.kAGJBTej065386>