smtp: fix file logging and matching

When no rules with 'file content' keywords like filemd5 or filestore
were used, and non of the file outputs would force 'output' like
'force-md5' and 'force-magic', the file would not be tracked at all.

This meant that logging wouldn't work and neither would filename and
fileext inspection.

This patch removes the tracking bypass from the SMTP code and leaves
decisions to the file API.
pull/2028/head
Victor Julien 9 years ago
parent 9d3fd82849
commit 5c514c904f

@ -406,13 +406,6 @@ int SMTPProcessDataChunk(const uint8_t *chunk, uint32_t len,
flags |= FILE_NOMD5;
}
/* Determine whether to process files */
if ((flags & (FILE_NOSTORE | FILE_NOMAGIC | FILE_NOMD5)) ==
(FILE_NOSTORE | FILE_NOMAGIC | FILE_NOMD5)) {
SCLogDebug("File content ignored");
return 0;
}
/* Find file */
if (entity->ctnt_flags & CTNT_IS_ATTACHMENT) {

Loading…
Cancel
Save