Gentoo Archives: gentoo-commits

From: "Matsuu Takuto (matsuu)" <matsuu@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-forensics/aide/files: aide.cron aide-0.13.1-configure.patch
Date: Sun, 13 Apr 2008 16:18:02
Message-Id: E1Jl4u0-0008At-AE@stork.gentoo.org
1 matsuu 08/04/13 16:18:00
2
3 Modified: aide.cron
4 Added: aide-0.13.1-configure.patch
5 Log:
6 removed mailx dependency, bug #215637.
7 (Portage version: 2.1.4.4)
8
9 Revision Changes Path
10 1.2 app-forensics/aide/files/aide.cron
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-forensics/aide/files/aide.cron?rev=1.2&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-forensics/aide/files/aide.cron?rev=1.2&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-forensics/aide/files/aide.cron?r1=1.1&r2=1.2
15
16 Index: aide.cron
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/app-forensics/aide/files/aide.cron,v
19 retrieving revision 1.1
20 retrieving revision 1.2
21 diff -u -r1.1 -r1.2
22 --- aide.cron 30 Sep 2005 15:19:38 -0000 1.1
23 +++ aide.cron 13 Apr 2008 16:17:59 -0000 1.2
24 @@ -29,6 +29,7 @@
25 LOGFILE="aide.log"
26 CONFFILE="/etc/aide/aide.conf"
27 ERRORLOG="aide_error.log"
28 +MAILLOG="aide_mail.log"
29 ERRORTMP=`tempfile --directory "/tmp" --prefix "$ERRORLOG"`
30
31 [ -f /usr/bin/aide ] || exit 0
32 @@ -44,10 +45,13 @@
33 AIDEARGS="-V4"
34
35 if [ ! -f $DATABASE ]; then
36 - (
37 - echo "Fatal error: The AIDE database does not exist!"
38 - echo "This may mean you haven't created it, or it may mean that someone has removed it."
39 - ) | /bin/mail -s "Daily AIDE report for $FQDN" $MAILTO
40 + /usr/sbin/sendmail $MAILTO <<EOF
41 +Subject: Daily AIDE report for $FQDN
42 +From: root@${FQDN}
43 +To: ${MAILTO}
44 +Fatal error: The AIDE database does not exist!
45 +This may mean you haven't created it, or it may mean that someone has removed it.
46 +EOF
47 exit 0
48 fi
49
50 @@ -63,7 +67,9 @@
51 exit 0
52 fi
53
54 -(cat << EOF;
55 +MAILTMP=`tempfile --directory "/tmp" --prefix "$MAILLOG"`
56 +
57 +(cat << EOF
58 This is an automated report generated by the Advanced Intrusion Detection
59 Environment on $FQDN ${DATE}.
60
61 @@ -72,7 +78,7 @@
62 # include error log in daily report e-mail
63
64 if [ "$RETVAL" != "0" ]; then
65 - cat > "$LOGDIR/$ERRORLOG" << EOF;
66 + cat > "$LOGDIR/$ERRORLOG" << EOF
67
68 *****************************************************************************
69 * aide returned a non-zero exit value *
70 @@ -89,7 +95,7 @@
71 if [ -s "$LOGDIR/$ERRORLOG" ]; then
72 errorlines=`wc -l "$LOGDIR/$ERRORLOG" | awk '{ print $1 }'`
73 if [ ${errorlines:=0} -gt $LINES ]; then
74 - cat << EOF;
75 + cat << EOF
76
77 ****************************************************************************
78 * aide has returned many errors. *
79 @@ -129,7 +135,7 @@
80 if [ -s "$NOISETMP" ]; then
81 loglines=`< $NOISETMP wc -l | awk '{ print $1 }'`
82 if [ ${loglines:=0} -gt $LINES ]; then
83 - cat << EOF;
84 + cat << EOF
85
86 ****************************************************************************
87 * aide has returned long output which has been truncated in this mail *
88 @@ -155,7 +161,7 @@
89 if [ -s "$LOGDIR/$LOGFILE" ]; then
90 loglines=`wc -l "$LOGDIR/$LOGFILE" | awk '{ print $1 }'`
91 if [ ${loglines:=0} -gt $LINES ]; then
92 - cat << EOF;
93 + cat << EOF
94
95 ****************************************************************************
96 * aide has returned long output which has been truncated in this mail *
97 @@ -172,4 +178,15 @@
98 else
99 echo "AIDE detected no changes."
100 fi
101 -) | /bin/mail -s "Daily AIDE report for $FQDN" $MAILTO
102 +) > ${MAILTMP}
103 +
104 +(
105 +cat <<EOF
106 +Subject: Daily AIDE report for $FQDN
107 +From: root@${FQDN}
108 +To: ${MAILTO}
109 +EOF
110 +cat ${MAILTMP}
111 +) | /usr/sbin/sendmail $MAILTO
112 +
113 +rm -f "$MAILTMP"
114
115
116
117 1.1 app-forensics/aide/files/aide-0.13.1-configure.patch
118
119 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-forensics/aide/files/aide-0.13.1-configure.patch?rev=1.1&view=markup
120 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-forensics/aide/files/aide-0.13.1-configure.patch?rev=1.1&content-type=text/plain
121
122 Index: aide-0.13.1-configure.patch
123 ===================================================================
124 --- configure.in.old 2008-01-26 15:07:28.000000000 +0100
125 +++ configure.in 2008-01-26 15:14:05.000000000 +0100
126 @@ -160,7 +160,9 @@
127 fi
128
129 # Check whether static linking has explicitly been disabled
130 -AC_ARG_ENABLE(static,[ --disable-static Disable static linking (lowers the security of aide)], [aide_static_choice=$enableval], [aide_static_choice=yes])
131 +AC_ARG_ENABLE(static,
132 + AC_HELP_STRING([--disable-static],[Disable static linking (lowers the security of aide)]),
133 + [aide_static_choice=$enableval], [aide_static_choice=yes])
134
135 if test "$aide_static_choice" != "yes"; then
136 LD_STATIC_FLAG=""
137 @@ -190,8 +192,8 @@
138 AC_CHECK_FUNCS(stricmp strnstr strnlen)
139
140 AC_ARG_WITH([mmap],
141 - [AC_HELP_STRING([--with-mmap],
142 - [use mmap @<:@default=check@:>@])],
143 + AC_HELP_STRING([--with-mmap],
144 + [use mmap @<:@default=check@:>@]),
145 [],
146 [with_mmap=check]
147 )
148 @@ -283,8 +285,8 @@
149 AC_CHECK_HEADERS(syslog.h inttypes.h fcntl.h)
150
151 AC_ARG_WITH([locale],
152 - [AC_HELP_STRING([--with-locale],
153 - [use locale stuff])],
154 + AC_HELP_STRING([--with-locale],
155 + [use locale stuff]),
156 [],
157 [with_locale=no]
158 )
159 @@ -369,10 +371,10 @@
160 [AC_HELP_STRING([--with-posix-acl],
161 [use POSIX ACLs (no checking)])],
162 [],
163 - [with_posix_acl_support=no]
164 + [with_posix_acl=no]
165 )
166
167 -AS_IF([test "x$with_posix_acl_support" != xno],
168 +AS_IF([test "x$with_posix_acl" != xno],
169 [AC_DEFINE(WITH_POSIX_ACL,1,[use POSIX ACLs])
170 AC_DEFINE(WITH_ACL,1,[use ACL])
171 ACLLIB="-lacl"
172 @@ -388,10 +390,10 @@
173 [AC_HELP_STRING([--with-selinux],
174 [use SELinux (no checking)])],
175 [],
176 - [with_selinux_support=no]
177 + [with_selinux=no]
178 )
179
180 -AS_IF([test "x$with_selinux_support" != xno],
181 +AS_IF([test "x$with_selinux" != xno],
182 [AC_DEFINE(WITH_SELINUX,1,[use SELinux])
183 if test -n "$PKG_CONFIG" && $PKG_CONFIG --exists libselinux; then
184 SELINUXLIB=$(${PKG_CONFIG} --libs libselinux --static)
185 @@ -410,10 +412,10 @@
186 [AC_HELP_STRING([--with-xattr],
187 [use xattr (no checking)])],
188 [],
189 - [with_xattr_support=no]
190 + [with_xattr=no]
191 )
192
193 -AS_IF([test "x$with_xattr_support" != xno],
194 +AS_IF([test "x$with_xattr" != xno],
195 [AC_DEFINE(WITH_XATTR,1,[use xattr])
196 ATTRLIB=-lattr
197 compoptionstring="${compoptionstring}WITH_XATTR\\n"
198
199
200
201 --
202 gentoo-commits@l.g.o mailing list