3 # $NetBSD: ipsec,v 1.10 2008/11/12 12:35:52 ad Exp $
7 # REQUIRE: root bootconf mountcritlocal tty
10 $_rc_subr_loaded .
/etc
/rc.subr
14 start_precmd
="ipsec_prestart"
15 start_cmd
="ipsec_start"
16 stop_precmd
="test -f /etc/ipsec.conf"
18 reload_cmd
="ipsec_reload"
19 extra_commands
="reload"
23 if [ ! -f /etc
/ipsec.conf
]; then
24 warn
"/etc/ipsec.conf not readable; ipsec start aborted."
34 echo "Installing ipsec manual keys/policies."
35 /sbin
/setkey
-f /etc
/ipsec.conf
40 echo "Clearing ipsec manual keys/policies."
42 # still not 100% sure if we would like to do this.
43 # it is very questionable to do this during shutdown session, since
44 # it can hang any of remaining IPv4/v6 session.
52 echo "Reloading ipsec manual keys/policies."
55 /sbin
/setkey
-f /etc
/ipsec.conf