home *** CD-ROM | disk | FTP | other *** search
/ chilidog.highland.cc.ks.us / chilidog.highland.cc.ks.us.zip / chilidog.highland.cc.ks.us / backup / bradford.20120521.etc.tar.gz / bradford.20120521.etc.tar / etc / init.d / SuSEfirewall2_init < prev    next >
Text File  |  2006-04-22  |  1KB  |  64 lines

  1. #! /bin/sh
  2. # Copyright (c) 2000-2002 SuSE GmbH Nuernberg, Germany.
  3. #
  4. # Author: Marc Heuse <marc@suse.de>
  5. #
  6. # /etc/init.d/SuSEfirewall2_init
  7. #
  8. ### BEGIN INIT INFO
  9. # Provides: SuSEfirewall2_init
  10. # Required-Start: $local_fs boot.localnet
  11. # Required-Stop: 
  12. # Should-Stop: $network
  13. # Default-Start: B
  14. # Default-Stop:
  15. # Short-Description: SuSEfirewall2 phase 1
  16. # Description: SuSEfirewall2_init does some basic setup and is the
  17. #    phase 1 of 2 of the SuSEfirewall initialization
  18. ### END INIT INFO
  19.  
  20. SUSEFWALL="/sbin/SuSEfirewall2"
  21. BOOTLOCKFILE="/var/lock/SuSEfirewall2.booting"
  22.  
  23. test -x $SUSEFWALL || exit 5
  24. test -r /etc/sysconfig/SuSEfirewall2 || exit 6
  25.  
  26. . /etc/rc.status
  27.  
  28. rc_reset
  29.  
  30. case "$1" in
  31.     start)
  32.     echo -n "Starting Firewall Initialization "
  33.     echo -n '(phase 1 of 2) '
  34.     $SUSEFWALL --bootlock -q close
  35.     rc_status -v
  36.     ;;
  37.     stop)
  38.     rc_failed 0
  39.     rc_status
  40.     ;;
  41.     restart|force-reload)
  42.     $0 start
  43.     ;;
  44.     try-restart|reload)
  45.     if ($0 status) >/dev/null 2>&1; then
  46.         $0 start
  47.     else
  48.         rc_reset
  49.     fi
  50.     ;;
  51.     status)
  52.     echo -n "Checking the status of SuSEfirewall2 "
  53.     iptables -nL reject_func >/dev/null 2>&1 || rc_failed 3
  54.     rc_status -v
  55.     ;;
  56.     *)
  57.     echo "Usage: $0 {start|stop|status|restart|reload|force-reload}"
  58.     exit 1
  59.     ;;
  60. esac
  61.  
  62. # Set exit status
  63. rc_exit
  64.