activate archive scanning option
authorPaul Mangan <paul@claws-mail.org>
Sat, 12 Apr 2003 18:46:14 +0000 (18:46 +0000)
committerPaul Mangan <paul@claws-mail.org>
Sat, 12 Apr 2003 18:46:14 +0000 (18:46 +0000)
ChangeLog.claws
configure.ac
src/plugins/clamav/clamav_plugin.c

index b648647..b391338 100644 (file)
@@ -1,3 +1,10 @@
+2003-04-12 [paul]      0.8.11claws87
+
+       * src/plugins/clamav/clamav_plugin.c
+               activate enable/disable archive scanning option
+               
+       * src/plugins/clamav/.cvsignore         ** NEW FILE **
+
 2003-04-12 [paul]      0.8.11claws86
 
        * src/plugins/Makefile.am
index 4c0c359..a3de32d 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=8
 MICRO_VERSION=11
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws86
+EXTRA_VERSION=claws87
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl set $target
index 5b999aa..0d729b8 100644 (file)
@@ -81,6 +81,7 @@ static gboolean mail_filtering_hook(gpointer source, gpointer data)
        MimeInfo *child;
        gchar *infile;
        gchar *outfile;
+       gint scan_archive = 0;
 
        int ret, no;
        unsigned long int size;
@@ -127,6 +128,9 @@ static gboolean mail_filtering_hook(gpointer source, gpointer data)
        limits.maxfilesize = config.clamav_max_size * 1048576; /* maximal archived file size == 10 Mb */
        limits.maxreclevel = 8; /* maximal recursion level */
 
+       if (config.clamav_archive_enable)
+               scan_archive = TRUE;
+
        while (child != NULL) {
                if (child->children || child->mime_type == MIME_MULTIPART) {
                        child = procmime_mimeinfo_next(child);
@@ -144,9 +148,8 @@ static gboolean mail_filtering_hook(gpointer source, gpointer data)
                        g_warning("Can't get the part of multipart message.");
                else {
                        debug_print("Scanning %s\n", outfile);
-
                        if((ret = cl_scanfile(outfile, &virname, &size, root, 
-                                             &limits, CL_ARCHIVE)) == CL_VIRUS) {
+                                             &limits, scan_archive)) == CL_VIRUS) {
                                is_infected = TRUE;
                                debug_print("Detected %s virus.\n", virname); 
                        } else {