From 57b7565e7d5f35dd23d1be8fbb1d655400f6faab Mon Sep 17 00:00:00 2001 From: deraadt Date: Thu, 6 Jul 2023 07:49:52 +0000 Subject: [PATCH] remove during-development special cases for MNT_WXALLOWED and chrome and IBT/BTI, because many more things are about to work correctly --- sys/kern/kern_exec.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c index e7cf2962d41..2622fb4a961 100644 --- a/sys/kern/kern_exec.c +++ b/sys/kern/kern_exec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_exec.c,v 1.248 2023/05/30 08:30:01 jsg Exp $ */ +/* $OpenBSD: kern_exec.c,v 1.249 2023/07/06 07:49:52 deraadt Exp $ */ /* $NetBSD: kern_exec.c,v 1.75 1996/02/09 18:59:28 christos Exp $ */ /*- @@ -531,18 +531,6 @@ sys_execve(struct proc *p, void *v, register_t *retval) if (otvp) vrele(otvp); - /* - * XXX As a transition mechanism, we don't enforce branch - * target control flow integrity on partitions mounted with - * the wxallowed flag. - */ - if (pr->ps_textvp->v_mount && - (pr->ps_textvp->v_mount->mnt_flag & MNT_WXALLOWED)) - pack.ep_flags |= EXEC_NOBTCFI; - /* XXX XXX But enable it for chrome. */ - if (strcmp(p->p_p->ps_comm, "chrome") == 0) - pack.ep_flags &= ~EXEC_NOBTCFI; - atomic_setbits_int(&pr->ps_flags, PS_EXEC); if (pr->ps_flags & PS_PPWAIT) { atomic_clearbits_int(&pr->ps_flags, PS_PPWAIT); -- 2.20.1