diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2023-02-21 14:31:08 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2023-02-21 14:31:08 +0000 |
commit | 96cfb9c0017ce8d105160cbb66d4ab9e76b9be56 (patch) | |
tree | e38c7415700e7dd4efac7a88b2d4734f78bb551d /sys/kern | |
parent | ce5d1860fc7b454003c4387f4fd4775663e47014 (diff) |
for process kills due to execve from non-pinned syscall address, export
a new AEXECVE bit to acct(4), and print it in lastcomm(8)
ok bluhm
Diffstat (limited to 'sys/kern')
-rw-r--r-- | sys/kern/kern_exec.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c index 01f92235e3b..5ee43baf74a 100644 --- a/sys/kern/kern_exec.c +++ b/sys/kern/kern_exec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_exec.c,v 1.245 2023/02/17 18:08:32 deraadt Exp $ */ +/* $OpenBSD: kern_exec.c,v 1.246 2023/02/21 14:31:07 deraadt Exp $ */ /* $NetBSD: kern_exec.c,v 1.75 1996/02/09 18:59:28 christos Exp $ */ /*- @@ -278,6 +278,7 @@ sys_execve(struct proc *p, void *v, register_t *retval) (pc >= vm->vm_execve_end || pc < vm->vm_execve)) { printf("%s(%d): execve %lx outside %lx-%lx\n", pr->ps_comm, pr->ps_pid, pc, vm->vm_execve, vm->vm_execve_end); + p->p_p->ps_acflag |= AEXECVE; sigabort(p); return (0); } |