[Pkg-clamav-commits] [SCM] Debian repository for ClamAV branch, debian/unstable, updated. debian/0.95+dfsg-1-6633-g2c817b2

Michael Tautschnig mt at debian.org
Tue Jan 18 23:26:37 UTC 2011


The following commit has been merged in the debian/unstable branch:
commit b8392cb2bf345d17f254cde18af3471bfe26afcd
Author: Michael Tautschnig <mt at debian.org>
Date:   Tue Jan 18 23:20:44 2011 +0000

    libclamav/scanners.c: improve scanning of mail files in raw mode (bb#2244)
    
    Conflicts:
    
    	ChangeLog
    	libclamav/scanners.c
    
    Signed-off-by: Michael Tautschnig <mt at debian.org>

diff --git a/libclamav/scanners.c b/libclamav/scanners.c
index 8f22ffb..4aa5308 100644
--- a/libclamav/scanners.c
+++ b/libclamav/scanners.c
@@ -1869,8 +1869,10 @@ static int cli_scanraw(cli_ctx *ctx, cli_file_t type, uint8_t typercg, cli_file_
 	    case CL_TYPE_MAIL:
 		ctx->container_type = CL_TYPE_MAIL;
 		ctx->container_size = map->len;
-		if(SCAN_MAIL && type == CL_TYPE_TEXT_ASCII && (DCONF_MAIL & MAIL_CONF_MBOX))
+		if(SCAN_MAIL && type == CL_TYPE_TEXT_ASCII && (DCONF_MAIL & MAIL_CONF_MBOX)) {
+		    *dettype = CL_TYPE_MAIL;
 		    nret = cli_scanmail(map->fd, ctx);
+		}
 		ctx->container_type = current_container_type;
 		ctx->container_size = current_container_size;
 		break;
@@ -2347,7 +2349,7 @@ static int magic_scandesc(int desc, cli_ctx *ctx, cli_file_t type)
 	case CL_TYPE_TEXT_UTF8:
 	    if((DCONF_DOC & DOC_CONF_SCRIPT) && dettype != CL_TYPE_HTML)
 	        ret = cli_scanscript(ctx);
-	    if(ret != CL_VIRUS && ctx->container_type == CL_TYPE_MAIL) {
+	    if(SCAN_MAIL && (DCONF_MAIL & MAIL_CONF_MBOX) && ret != CL_VIRUS && (ctx->container_type == CL_TYPE_MAIL || dettype == CL_TYPE_MAIL)) {
 		lseek(desc, 0, SEEK_SET);
 		ret = cli_scandesc(desc, ctx, CL_TYPE_MAIL, 0, NULL, AC_SCAN_VIR, NULL);
 	    }

-- 
Debian repository for ClamAV



More information about the Pkg-clamav-commits mailing list