Переглянути джерело

Update nontracked version from 1.7.10 to 1.7.11, repaired logging and fsl configuration, implemented features in ticket #202

Michael Schloh von Bennewitz 22 роки тому
батько
коміт
247fc3b5db
4 змінених файлів з 22 додано та 5 видалено
  1. 1 1
      samhain/fsl.samhain
  2. 5 2
      samhain/rc.samhain
  3. 12 0
      samhain/samhain.patch
  4. 4 2
      samhain/samhain.spec

+ 1 - 1
samhain/fsl.samhain

@@ -2,7 +2,7 @@
 ##  fsl.samhain -- OSSP fsl configuration
 ##
 
-ident (Yule|Samhain)/.+ q{
+ident (samhain)/.+ q{
     prefix(
         prefix="%b %d %H:%M:%S %N <%L> $1[%P]: "
     )

+ 5 - 2
samhain/rc.samhain

@@ -39,15 +39,18 @@
 
 %start -u @l_susr@
     rcService samhain enable yes || exit 0
+    rcService samhain active yes && exit 0
     @l_prefix@/sbin/samhain -t check -D
 
 %stop -u @l_susr@
     rcService samhain enable yes || exit 0
+    rcService samhain active no && exit 0
     samhain_signal TERM
     samhain_wait
 
 %restart -u @l_susr@
     rcService samhain enable yes || exit 0
+    rcService samhain active no && exit 0
     rc samhain stop
     sleep 2
     rc samhain start
@@ -58,8 +61,8 @@
     #   rotate logfile
     shtool rotate -f \
         -n ${samhain_log_numfiles} -s ${samhain_log_minsize} -d \
-        -z ${samhain_log_complevel} -o @l_rusr@ -g @l_rgrp@ -m 644 \
+        -z ${samhain_log_complevel} -o @l_susr@ -g @l_mgrp@ -m 644 \
         -P "${samhain_log_prolog}" \
-        -E "${samhain_log_epilog}" \
+        -E "${samhain_log_epilog} && rc samhain restart" \
         @l_prefix@/var/samhain/samhain.log
 

+ 12 - 0
samhain/samhain.patch

@@ -0,0 +1,12 @@
+diff -Naur samhain-1.7.11.orig/sh_err_syslog.c samhain-1.7.11/sh_err_syslog.c
+--- samhain-1.7.11.orig/sh_err_syslog.c	Fri Mar 21 21:24:50 2003
++++ samhain-1.7.11/sh_err_syslog.c	Fri Sep  5 16:46:26 2003
+@@ -162,7 +162,7 @@
+ 
+   if (init == 0)
+     {
+-      openlog (sh.prg_name, LOG_PID, my_syslog_facility);
++      openlog ("samhain", LOG_PID, my_syslog_facility);
+       init = 1;
+     }
+ 

+ 4 - 2
samhain/samhain.spec

@@ -32,8 +32,8 @@ Packager:     The OpenPKG Project
 Distribution: OpenPKG [PLUS]
 Group:        System
 License:      GPL
-Version:      1.7.10
-Release:      20030728
+Version:      1.7.11
+Release:      20030905
 
 #   package options
 %option       with_fsl  yes
@@ -42,6 +42,7 @@ Release:      20030728
 Source0:      http://la-samhna.de/samhain/samhain-current.tar.gz
 Source1:      rc.samhain
 Source2:      fsl.samhain
+Patch0:       samhain.patch
 
 #   build information
 Prefix:       %{l_prefix}
@@ -65,6 +66,7 @@ AutoReqProv:  no
 %prep
     %setup -q -c samhain-%{version}
     %{l_gzip} -d -c samhain-%{version}.tar.gz | %{l_tar} xf -
+    %patch -p0
 
 %build
     cd samhain-%{version}