Date: Sat, 18 Jul 2015 13:36:10 GMT From: def@FreeBSD.org To: svn-soc-all@FreeBSD.org Subject: socsvn commit: r288532 - soc2013/def/crashdump-head/etc/rc.d Message-ID: <201507181336.t6IDaAp5054989@socsvn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: def Date: Sat Jul 18 13:36:09 2015 New Revision: 288532 URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=288532 Log: Implement stop command in cryptcore rc.d script. Modified: soc2013/def/crashdump-head/etc/rc.d/cryptcore Modified: soc2013/def/crashdump-head/etc/rc.d/cryptcore ============================================================================== --- soc2013/def/crashdump-head/etc/rc.d/cryptcore Sat Jul 18 13:19:42 2015 (r288531) +++ soc2013/def/crashdump-head/etc/rc.d/cryptcore Sat Jul 18 13:36:09 2015 (r288532) @@ -8,16 +8,22 @@ name="cryptcore" rcvar="cryptcore_enable" +start_precmd="${name}_check" start_cmd="${name}_start" -stop_cmd=":" +stop_precmd="${name}_check" +stop_cmd="${name}_stop" -cryptcore_start() +cryptcore_check() { sysctl -Nq security.ekcd.enable >/dev/null if [ $? -ne 0 ]; then err 1 "Kernel is missing encrypted kernel crash dumps." fi +} + +cryptcore_start() +{ if [ ! -f "${cryptcore_pubkey}" ]; then err 1 "Invalid path to a public key." @@ -31,5 +37,11 @@ sysctl security.ekcd.enable=1 } +cryptcore_stop() +{ + + sysctl security.ekcd.enable=0 +} + load_rc_config $name run_rc_command "$1"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201507181336.t6IDaAp5054989>