Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/tests/kernel Correct securelevel in attach_pid1_securelevel
details: https://anonhg.NetBSD.org/src/rev/a575b65f1175
branches: trunk
changeset: 352456:a575b65f1175
user: kamil <kamil%NetBSD.org@localhost>
date: Sat Apr 01 23:51:27 2017 +0000
description:
Correct securelevel in attach_pid1_securelevel
Assert that a debugger cannot attach to PID 1 with securelevel >= 0
(as root) instead of >= 1.
Sponsored by <The NetBSD Foundation>
diffstat:
tests/kernel/t_ptrace.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diffs (36 lines):
diff -r b24cfa9521cd -r a575b65f1175 tests/kernel/t_ptrace.c
--- a/tests/kernel/t_ptrace.c Sat Apr 01 23:34:17 2017 +0000
+++ b/tests/kernel/t_ptrace.c Sat Apr 01 23:51:27 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: t_ptrace.c,v 1.18 2017/01/13 21:30:41 christos Exp $ */
+/* $NetBSD: t_ptrace.c,v 1.19 2017/04/01 23:51:27 kamil Exp $ */
/*-
* Copyright (c) 2016 The NetBSD Foundation, Inc.
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: t_ptrace.c,v 1.18 2017/01/13 21:30:41 christos Exp $");
+__RCSID("$NetBSD: t_ptrace.c,v 1.19 2017/04/01 23:51:27 kamil Exp $");
#include <sys/param.h>
#include <sys/types.h>
@@ -98,7 +98,7 @@
{
atf_tc_set_md_var(tc, "descr",
"Assert that a debugger cannot attach to PID 1 with "
- "securelevel >= 1 (as root)");
+ "securelevel >= 0 (as root)");
atf_tc_set_md_var(tc, "require.user", "root");
}
@@ -111,7 +111,7 @@
ATF_REQUIRE(sysctlbyname("kern.securelevel", &level, &len, NULL, 0)
!= -1);
- if (level < 1) {
+ if (level < 0) {
atf_tc_skip("Test must be run with securelevel >= 1");
}
Home |
Main Index |
Thread Index |
Old Index