aboutsummaryrefslogtreecommitdiffstats
path: root/packages/clamav/files
diff options
context:
space:
mode:
authorJamie Lenehan <lenehan@twibble.org>2007-05-16 01:32:57 +0000
committerJamie Lenehan <lenehan@twibble.org>2007-05-16 01:32:57 +0000
commit196fe037fda65eaa9c1c3e07d0651f8cd6c363e2 (patch)
tree9fffd92778cd6172269e7248241fe70a2ff90b93 /packages/clamav/files
parentafb0b01f1860f482b916fa3570912dc2091c928f (diff)
downloadopenembedded-196fe037fda65eaa9c1c3e07d0651f8cd6c363e2.tar.gz
clamav: Add 0.90.2 version, remove older versions plus a number of other
changes: * Remove 0.88.6 * Added 0.90.2 * Add a new clamav-conf package to hold clamd.conf. This is needed by both clamd and freshclam and previously you needed to install clamd even if you didn't want it just to get freshclam to work. * Assume that /var/lib is non-volatile. Move the virus database there by default. * Update configuration files for the new 0.9x syntax. * Simplify the init scripts. * Indicate the freshclam also provides clamav data, so if you install freshclam you don't need data. * NOTE: There are incompatible changes to libclamav in this release, anything that links directly against the library will need to be updated.
Diffstat (limited to 'packages/clamav/files')
-rw-r--r--packages/clamav/files/clamav-daemon.default1
-rw-r--r--packages/clamav/files/clamav-daemon.init14
-rw-r--r--packages/clamav/files/clamav-freshclam.init58
-rw-r--r--packages/clamav/files/clamd.conf25
-rw-r--r--packages/clamav/files/cross-compile-fix.patch74
-rw-r--r--packages/clamav/files/freshclam.conf19
-rw-r--r--packages/clamav/files/libtool-fix.patch23
-rw-r--r--packages/clamav/files/volatiles.02_clamav-data4
-rw-r--r--packages/clamav/files/volatiles.03_clamav-data4
9 files changed, 25 insertions, 197 deletions
diff --git a/packages/clamav/files/clamav-daemon.default b/packages/clamav/files/clamav-daemon.default
deleted file mode 100644
index bc19984183..0000000000
--- a/packages/clamav/files/clamav-daemon.default
+++ /dev/null
@@ -1 +0,0 @@
-# Options for clamav-daemon (clamd process)
diff --git a/packages/clamav/files/clamav-daemon.init b/packages/clamav/files/clamav-daemon.init
index bab7a184d7..6fd07146ea 100644
--- a/packages/clamav/files/clamav-daemon.init
+++ b/packages/clamav/files/clamav-daemon.init
@@ -3,18 +3,20 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/sbin/clamd
NAME="clamd"
DESC="ClamAV daemon"
-CLAMAVCONF=/etc/clamd.conf
+CLAMAV_CONF=/etc/clamd.conf
+PID=/var/run/clamav/clamd.pid
set -e
-test -r /etc/default/clamav-daemon && . /etc/default/clamav-daemon
test -x "$DAEMON" || exit 0
-test ! -r "$CLAMAVCONF" && exit 0
-if [ `grep -q "^Example" $CLAMAVCONF` ]; then
+if [ ! -r "$CLAMAV_CONF" ]; then
+ echo "ClamAV configuration file $CLAMAV_CONF not found. Exiting"
+ exit 0
+fi
+if [ `grep -q "^Example" $CLAMAV_CONF` ]; then
echo "$DESC is not configured."
exit 0
fi
-pidfile="`grep ^PidFile $CLAMAVCONF | awk '{print $2}'`"
case "$1" in
start)
@@ -25,7 +27,7 @@ case "$1" in
stop)
echo -n "Stopping $DESC: "
- start-stop-daemon -K -p $pidfile
+ start-stop-daemon -K -p $PID
;;
restart|force-reload)
diff --git a/packages/clamav/files/clamav-freshclam.init b/packages/clamav/files/clamav-freshclam.init
index 490a41e31f..21f02008f5 100644
--- a/packages/clamav/files/clamav-freshclam.init
+++ b/packages/clamav/files/clamav-freshclam.init
@@ -3,70 +3,38 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/bin/freshclam
NAME=freshclam
DESC="ClamAV virus database updater"
-CLAMAV_CONF_FILE=/etc/clamd.conf
-FRESHCLAM_CONF_FILE=/etc/freshclam.conf
-pidfile=/var/run/clamav/freshclam.pid
+FRESHCLAM_CONF=/etc/freshclam.conf
+CLAMAV_CONF=/etc/clamd.conf
+PID=/var/run/clamav/freshclam.pid
set -e
-test -r /etc/default/clamav-freshclam && . /etc/default/clamav-freshclam
test -x "$DAEMON" || exit 0
-test ! -r "$CLAMAV_CONF_FILE" && exit 0
-
-slurp_config()
-{
- CLAMAVCONF="$1"
-
- if [ -e "$CLAMAVCONF" ]; then
- for variable in `egrep -v '^[[:space:]]*(#|$)' "$CLAMAVCONF" | awk '{print $1}'`; do
- if [ "$variable" = 'DatabaseMirror' ]; then
- if [ -z "$DatabaseMirror" ]; then
- for i in `grep ^$variable $CLAMAVCONF | awk '{print $2}'`; do
- value="$i $value"
- done
- else
- continue
- fi
- elif [ "$variable" = 'VirusEvent' -o "$variable" = 'OnUpdateExecute' -o "$variable" = 'OnErrorExecute' ]; then
- value=`grep ^$variable $CLAMAVCONF | head -n1 | sed -e s/$variable\ //`
- else
- value=`grep ^$variable $CLAMAVCONF | head -n1 | awk '{print $2}'`
- fi
- if ! [ "$value" = "$variable" -o "$value" = "" ]; then
- export "$variable"="$value"
- else
- export "$variable"="true"
- fi
- unset value
- done
- fi
-}
-
-slurp_config "$FRESHCLAM_CONF_FILE"
-
-[ -z "$UpdateLogFile" ] && UpdateLogFile=/var/log/clamav/freshclam.log
-
-if [ -z "$DatabaseDirectory" ]; then
- [ -r "$CLAMAV_CONF_FILE" ] && DatabaseDirectory=$(grep 'DataDirectory' "$CLAMAV_CONF_FILE" | awk '{print $2}')
- [ -z "$DatabaseDirectory" ] && DatabaseDirectory=/var/lib/clamav/
+if [ ! -r "$CLAMAV_CONF" ]; then
+ echo "ClamAV configuration file $CLAMAV_CONF not found. Exiting"
+ exit 0
+fi
+if [ ! -r "$FRESHCLAM_CONF" ]; then
+ echo "Freshclam configuration file $FRESHCLAM_CONF not found. Exiting"
+ exit 0
fi
case "$1" in
no-daemon)
echo "It takes freshclam ~3min to timeout and try the next mirror in the list"
- freshclam -l "$UpdateLogFile" --datadir "$DatabaseDirectory"
+ freshclam
;;
start)
echo -n "Starting $DESC: "
- start-stop-daemon -S -x $DAEMON -- -d --quiet -p $pidfile
+ start-stop-daemon -S -x $DAEMON -- -d --quiet -p $PID
echo "$NAME."
;;
stop)
echo -n "Stopping $DESC: "
- start-stop-daemon -K -p $pidfile
+ start-stop-daemon -K -p $PID
;;
restart|force-reload)
diff --git a/packages/clamav/files/clamd.conf b/packages/clamav/files/clamd.conf
deleted file mode 100644
index 485c80d420..0000000000
--- a/packages/clamav/files/clamd.conf
+++ /dev/null
@@ -1,25 +0,0 @@
-## Please read the clamd.conf(5) manual before editing this file.
-LocalSocket /var/run/clamav/clamd.ctl
-FixStaleSocket
-User clamav
-AllowSupplementaryGroups
-ScanMail
-ScanArchive
-ArchiveMaxRecursion 5
-ArchiveMaxFiles 1000
-ArchiveMaxFileSize 10M
-ArchiveMaxCompressionRatio 250
-ReadTimeout 180
-MaxThreads 12
-MaxConnectionQueueLength 15
-LogFile /var/log/clamav/clamav.log
-LogTime
-LogFileMaxSize 0
-PidFile /var/run/clamav/clamd.pid
-DatabaseDirectory /var/lib/clamav
-SelfCheck 3600
-ScanOLE2
-ScanPE
-DetectBrokenExecutables
-ScanHTML
-ArchiveBlockMax
diff --git a/packages/clamav/files/cross-compile-fix.patch b/packages/clamav/files/cross-compile-fix.patch
deleted file mode 100644
index 690d680c66..0000000000
--- a/packages/clamav/files/cross-compile-fix.patch
+++ /dev/null
@@ -1,74 +0,0 @@
-Add some caching of values which can't be determined when
-cross-compiling. This lets us define the values via the site files.
-
---- clamav-0.88.4/configure.in 2006/09/12 05:49:09 1.1
-+++ clamav-0.88.4/configure.in 2006/09/12 06:24:27
-@@ -56,19 +56,18 @@
-
- dnl Check for broken snprintf (code by Phil Oleson <oz*nixil.net>)
- if test "x$ac_cv_func_snprintf" = "xyes" ; then
-- AC_MSG_CHECKING([whether snprintf correctly terminates long strings])
-- AC_TRY_RUN(
-- [
-+ AC_CACHE_CHECK([whether snprintf correctly terminates long strings],
-+ [clamav_av_func_working_snprintf_long], [
-+ AC_TRY_RUN(
-+ [
- #include <stdio.h>
- int main(void){char b[5];snprintf(b,5,"123456789");return(b[4]!='\0');}
-- ],
-- [AC_MSG_RESULT(yes)],
-- [
-- AC_MSG_RESULT(no)
-- AC_DEFINE(BROKEN_SNPRINTF,1,[Define if your snprintf is busted])
-- AC_MSG_WARN([****** Your snprintf() function is broken, complain to your vendor])
-- ]
-- )
-+ ])
-+ ])
-+ if test "x$clamav_av_func_working_snprintf_long" = "xno"; then
-+ AC_DEFINE(BROKEN_SNPRINTF,1,[Define if your snprintf is busted])
-+ AC_MSG_WARN([****** Your snprintf() function is broken, complain to your vendor])
-+ fi
- fi
-
- have_pthreads=no
-@@ -331,18 +330,28 @@
- AC_DEFINE_UNQUOTED(CONFDIR,"$cfg_dir",[where to look for the config file])
-
- dnl check for in_port_t definition
--AC_TRY_RUN([
--#include <sys/types.h>
--#include <netinet/in.h>
--int main(int argc, char **argv) { in_port_t pt; pt = 0; return pt; }
--], AC_DEFINE(HAVE_IN_PORT_T,1,[in_port_t is defined]), AC_MSG_RESULT(in_port_t is not defined))
-+AC_CACHE_CHECK([for in_port_t], [clamav_av_have_in_port_t], [
-+ AC_TRY_RUN([
-+ #include <sys/types.h>
-+ #include <netinet/in.h>
-+ int main(int argc, char **argv) { in_port_t pt; pt = 0; return pt; }
-+ ])
-+ ])
-+if test "$clamav_av_have_in_port_t" = "yes"; then
-+ AC_DEFINE(HAVE_IN_PORT_T,1,[in_port_t is defined])
-+fi
-
- dnl check for in_addr_t definition
--AC_TRY_RUN([
--#include <sys/types.h>
--#include <netinet/in.h>
--int main(int argc, char **argv) { in_addr_t pt; pt = 0; return pt; }
--], AC_DEFINE(HAVE_IN_ADDR_T,1,[in_addr_t is defined]), AC_MSG_RESULT(in_addr_t is not defined))
-+AC_CACHE_CHECK([for in_addr_t], [clamav_av_have_in_addr_t], [
-+ AC_TRY_RUN([
-+ #include <sys/types.h>
-+ #include <netinet/in.h>
-+ int main(int argc, char **argv) { in_addr_t pt; pt = 0; return pt; }
-+ ])
-+ ])
-+if test "$clamav_av_have_in_addr_t" = "yes"; then
-+ AC_DEFINE(HAVE_IN_ADDR_T,1,[in_addr_t is defined])
-+fi
-
- case "$target_os" in
- linux*)
diff --git a/packages/clamav/files/freshclam.conf b/packages/clamav/files/freshclam.conf
deleted file mode 100644
index 770490b3ab..0000000000
--- a/packages/clamav/files/freshclam.conf
+++ /dev/null
@@ -1,19 +0,0 @@
-## Please read the freshclam.conf(5) manual before editing this file.
-
-# Comment or remove the line below.
-Example
-
-# Uncomment the following line and replace XY with your country
-# code. See http://www.iana.org/cctld/cctld-whois.htm for the full list.
-# Default: There is no default, which results in an error when running freshclam
-#DatabaseMirror db.XY.clamav.net
-
-DatabaseMirror database.clamav.net
-DatabaseOwner clamav
-UpdateLogFile /var/log/clamav/freshclam.log
-LogFileMaxSize 0
-MaxAttempts 5
-Checks 24
-DatabaseDirectory /var/lib/clamav/
-NotifyClamd
-DNSDatabaseInfo current.cvd.clamav.net
diff --git a/packages/clamav/files/libtool-fix.patch b/packages/clamav/files/libtool-fix.patch
deleted file mode 100644
index 05a4876dd0..0000000000
--- a/packages/clamav/files/libtool-fix.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Use our own libtool that knows about cross compiling, not the libtool
-that is included.
-
---- clamav-0.88.4/acinclude.m4 2006/09/12 08:07:27 1.1
-+++ clamav-0.88.4/acinclude.m4 2006/09/12 08:16:31
-@@ -520,7 +520,7 @@
- LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
-
- # Always use our own libtool.
--LIBTOOL='$(SHELL) $(top_builddir)/libtool'
-+LIBTOOL="$host_alias-libtool"
- AC_SUBST(LIBTOOL)dnl
-
- # Prevent multiple expansion
-@@ -1238,7 +1238,7 @@
- rm="rm -f"
-
- # Global variables:
--default_ofile=libtool
-+default_ofile=${host_alias}-libtool
- can_build_shared=yes
-
- # All known linkers require a `.a' archive for static linking (except M$VC,
diff --git a/packages/clamav/files/volatiles.02_clamav-data b/packages/clamav/files/volatiles.02_clamav-data
deleted file mode 100644
index 99dc98b323..0000000000
--- a/packages/clamav/files/volatiles.02_clamav-data
+++ /dev/null
@@ -1,4 +0,0 @@
-# <type> <owner> <group> <mode> <path> <linksource>
-d clamav clamav 0755 /var/lib/clamav none
-l clamav clamav 0644 /var/lib/clamav/main.cvd /usr/lib/clamav/main.cvd
-l clamav clamav 0644 /var/lib/clamav/daily.cvd /usr/lib/clamav/daily.cvd
diff --git a/packages/clamav/files/volatiles.03_clamav-data b/packages/clamav/files/volatiles.03_clamav-data
new file mode 100644
index 0000000000..8fdb0a742a
--- /dev/null
+++ b/packages/clamav/files/volatiles.03_clamav-data
@@ -0,0 +1,4 @@
+# <type> <owner> <group> <mode> <path> <linksource>
+d clamav clamav 0755 /var/lib/clamav none
+f clamav clamav 0644 /var/lib/clamav/main.cvd none
+f clamav clamav 0644 /var/lib/clamav/daily.cvd none
> OpenEmbedded Core user contribution treesGrokmirror user
summaryrefslogtreecommitdiffstats
path: root/meta/files/common-licenses/Motosoto
blob: 7a524f62b8926d2d410dafc9757b03e6a67ca9c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422