Current Path : /compat/linux/proc/self/root/usr/src/tools/regression/mac/mac_portacl/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //compat/linux/proc/self/root/usr/src/tools/regression/mac/mac_portacl/root.t |
#!/bin/sh # $FreeBSD: release/9.1.0/tools/regression/mac/mac_portacl/root.t 189832 2009-03-14 21:54:19Z pjd $ dir=`dirname $0` . ${dir}/misc.sh echo "1..48" # Verify if security.mac.portacl.suser_exempt=1 really exempts super-user. sysctl security.mac.portacl.suser_exempt=1 >/dev/null bind_test ok ok uid root tcp 77 bind_test ok ok uid root tcp 7777 bind_test ok ok uid root udp 77 bind_test ok ok uid root udp 7777 bind_test ok ok gid root tcp 77 bind_test ok ok gid root tcp 7777 bind_test ok ok gid root udp 77 bind_test ok ok gid root udp 7777 # Verify if security.mac.portacl.suser_exempt=0 really doesn't exempt super-user. sysctl security.mac.portacl.suser_exempt=0 >/dev/null bind_test fl ok uid root tcp 77 bind_test ok ok uid root tcp 7777 bind_test fl ok uid root udp 77 bind_test ok ok uid root udp 7777 bind_test fl ok gid root tcp 77 bind_test ok ok gid root tcp 7777 bind_test fl ok gid root udp 77 bind_test ok ok gid root udp 7777 # Verify if security.mac.portacl.port_high works for super-user. sysctl security.mac.portacl.port_high=7778 >/dev/null bind_test fl ok uid root tcp 77 bind_test fl ok uid root tcp 7777 bind_test fl ok uid root udp 77 bind_test fl ok uid root udp 7777 bind_test fl ok gid root tcp 77 bind_test fl ok gid root tcp 7777 bind_test fl ok gid root udp 77 bind_test fl ok gid root udp 7777 restore_settings