Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-3]: src/bin/systrace Pull up revision 1.18 (requested by elad in ...
details: https://anonhg.NetBSD.org/src/rev/ca4e04fd5444
branches: netbsd-3
changeset: 576421:ca4e04fd5444
user: tron <tron%NetBSD.org@localhost>
date: Sat Jul 02 17:53:45 2005 +0000
description:
Pull up revision 1.18 (requested by elad in ticket #487):
>From marius@openbsd:
Add an exec message so that whenever a set-uid/gid process executes a new
image which we may control, the exec does not go by unnoticed.
diffstat:
bin/systrace/netbsd-syscalls.c | 17 +++++++++++++++--
1 files changed, 15 insertions(+), 2 deletions(-)
diffs (38 lines):
diff -r 6768b38fad6e -r ca4e04fd5444 bin/systrace/netbsd-syscalls.c
--- a/bin/systrace/netbsd-syscalls.c Sat Jul 02 17:53:38 2005 +0000
+++ b/bin/systrace/netbsd-syscalls.c Sat Jul 02 17:53:45 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd-syscalls.c,v 1.17 2004/09/12 11:05:43 jdolecek Exp $ */
+/* $NetBSD: netbsd-syscalls.c,v 1.17.2.1 2005/07/02 17:53:45 tron Exp $ */
/*
* Copyright 2002 Niels Provos <provos%citi.umich.edu@localhost>
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: netbsd-syscalls.c,v 1.17 2004/09/12 11:05:43 jdolecek Exp $");
+__RCSID("$NetBSD: netbsd-syscalls.c,v 1.17.2.1 2005/07/02 17:53:45 tron Exp $");
#include <sys/types.h>
#include <sys/param.h>
@@ -644,6 +644,19 @@
intercept_policy_free(msg.msg_policy);
break;
#endif
+#ifdef SYSTR_MSG_EXECVE
+ case SYSTR_MSG_EXECVE: {
+ struct str_msg_execve *msg_execve = &msg.msg_data.msg_execve;
+
+ intercept_newimage(fd, pid, msg.msg_policy, current->name,
+ msg_execve->path, NULL);
+
+ if (nbsd_answer(fd, pid, seqnr, 0, 0, 0, NULL) == -1)
+ err(1, "%s:%d: answer", __func__, __LINE__);
+
+ break;
+ }
+#endif /* SYSTR_MSG_EXECVE */
}
return (0);
}
Home |
Main Index |
Thread Index |
Old Index