blob limits

git-svn: trunk@3633
remotes/push_mirror/metadata
aCaB 18 years ago
parent 965220979f
commit 561b5297bd
  1. 3
      ChangeLog
  2. 4
      libclamav/blob.c
  3. 3
      libclamav/matcher.c

@ -1,3 +1,6 @@
Thu Feb 14 19:21:03 CET 2008 (acab)
* libclamav: limits in blobs
Thu Feb 14 16:25:11 CET 2008 (acab)
-----------------------------------
* libclamav: fix warnings in pdf and untar

@ -628,8 +628,8 @@ fileblobAddData(fileblob *fb, const unsigned char *data, size_t len)
if(ctx->scanned)
*ctx->scanned += (unsigned long)len / CL_COUNT_PRECISION;
fb->bytes_scanned += (unsigned long)len;
if((len > 5) && (cli_scanbuff(data, (unsigned int)len, ctx->virname, ctx->engine, CL_TYPE_BINARY_DATA) == CL_VIRUS)) {
if((len > 5) && cli_updatelimits(ctx, len)==CL_CLEAN && (cli_scanbuff(data, (unsigned int)len, ctx->virname, ctx->engine, CL_TYPE_BINARY_DATA) == CL_VIRUS)) {
cli_dbgmsg("fileblobAddData: found %s\n", *ctx->virname);
fb->isInfected = 1;
}

@ -60,9 +60,6 @@ int cli_scanbuff(const unsigned char *buffer, uint32_t length, cli_ctx *ctx, cli
return CL_ENULLARG;
}
if(cli_updatelimits(ctx, length)!=CL_CLEAN)
return CL_CLEAN;
groot = engine->root[0]; /* generic signatures */
if(ftype) {

Loading…
Cancel
Save