root/psad/tags/psad-2.1.2/init-scripts/psad-init.generic

Revision 1211, 0.7 kB (checked in by mbr, 4 years ago)

removed grep test on syslog.conf since this file may not exist (syslog-ng.conf etc.)

  • Property svn:eol-style set to native
  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
Line 
1 #!/bin/sh
2 #
3 # Startup script for psad
4 #
5 # chkconfig: 345 99 05
6 # description: The Port Scan Attack Detector (psad)
7 # processname: psad
8 # pidfile: /var/run/psad.pid
9 # config: /etc/psad/psad.conf
10 #
11 # $Id$
12
13 restart() {
14     $0 stop
15     $0 start
16 }
17
18 # See how we were called.
19 case "$1" in
20 start)
21     echo -n "Starting psad: "
22     ### psad enables signature matching and auto
23     ### danger level assignment by default, so
24     ### command line args are not necessary here.
25     /usr/sbin/psad
26     echo
27     ;;
28 stop)
29     /usr/sbin/psad --Kill
30     ;;
31 status)
32     /usr/sbin/psad --Status
33     ;;
34 restart)
35     restart
36     ;;
37 *)
38     echo "Usage: psad {start|stop|status|restart}"
39     exit 1
40 esac
Note: See TracBrowser for help on using the browser.