[BACK]Return to ipfilter CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / etc / rc.d

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/etc/rc.d/ipfilter between version 1.2 and 1.5

version 1.2, 2000/03/11 20:10:21 version 1.5, 2000/07/17 12:58:14
Line 7 
Line 7 
 # REQUIRE: root beforenetlkm mountcritlocal tty  # REQUIRE: root beforenetlkm mountcritlocal tty
   
 . /etc/rc.subr  . /etc/rc.subr
 . /etc/rc.conf  
   
 name="ipfilter"  name="ipfilter"
   start_precmd="ipfilter_prestart"
 start_cmd="ipfilter_start"  start_cmd="ipfilter_start"
 stop_precmd="checkyesno ipfilter && [ -f /etc/ipf.conf ]"  stop_precmd="checkyesno ipfilter && [ -f /etc/ipf.conf ]"
 stop_cmd="ipfilter_stop"  stop_cmd="ipfilter_stop"
 reload_precmd="$stop_precmd"  reload_precmd="$stop_precmd"
 reload_cmd="ipfilter_reload"  reload_cmd="ipfilter_reload"
   status_precmd="$stop_precmd"
   status_cmd="ipfilter_status"
   extra_commands="reload status"
   
 ipfilter_start()  ipfilter_prestart()
 {  {
         if ! checkyesno ipfilter; then          if ! checkyesno ipfilter; then
                 return 0                  return 1
         fi          fi
   
         #       if /etc/ipf.conf isn't readable, abort the boot rather  
         #       than risk a security problem  
         #  
         if [ ! -f /etc/ipf.conf ]; then          if [ ! -f /etc/ipf.conf ]; then
                 err 1 "/etc/ipf.conf not readable; ipfilter start aborted."                  warn "/etc/ipf.conf not readable; ipfilter start aborted."
                   return 1
         fi          fi
           return 0
   }
   
   ipfilter_start()
   {
         echo "Enabling ipfilter."          echo "Enabling ipfilter."
         /sbin/ipf -E -Fa -f /etc/ipf.conf          /sbin/ipf -E -Fa -f /etc/ipf.conf
 }  }
Line 49  ipfilter_reload()
Line 54  ipfilter_reload()
         fi          fi
 }  }
   
 run_rc_command "$1" "reload"  ipfilter_status()
   {
           /sbin/ipf -V
   }
   
   load_rc_config $name
   run_rc_command "$1"

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.5

CVSweb <webmaster@jp.NetBSD.org>