|
diff --git a/src/app-layer-smtp.c b/src/app-layer-smtp.c
|
|
index 1b93b3252..fe09a2579 100644
|
|
--- a/src/app-layer-smtp.c
|
|
+++ b/src/app-layer-smtp.c
|
|
@@ -366,7 +366,7 @@ int SMTPProcessDataChunk(const uint8_t *chunk, uint32_t len,
|
|
}
|
|
|
|
/* Find file */
|
|
- if (entity->ctnt_flags & CTNT_IS_ATTACHMENT) {
|
|
+ if (entity->ctnt_flags & (CTNT_IS_ATTACHMENT | CTNT_IS_TEXT)) {
|
|
|
|
/* Make sure file container allocated */
|
|
if (smtp_state->files_ts == NULL) {
|
|
diff --git a/src/util-decode-mime.c b/src/util-decode-mime.c
|
|
index ded4cd604..e93ec9a51 100644
|
|
--- a/src/util-decode-mime.c
|
|
+++ b/src/util-decode-mime.c
|
|
@@ -1567,11 +1567,6 @@ static int ProcessBodyLine(const uint8_t *buf, uint32_t len,
|
|
memcpy(state->data_chunk + state->data_chunk_len, buf + offset, tobuf);
|
|
state->data_chunk_len += tobuf;
|
|
|
|
- /* Now always add a CRLF to the end */
|
|
- if (tobuf == remaining) {
|
|
- memcpy(state->data_chunk + state->data_chunk_len, CRLF, EOL_LEN);
|
|
- state->data_chunk_len += EOL_LEN;
|
|
- }
|
|
|
|
if ((int) (DATA_CHUNK_SIZE - state->data_chunk_len) < 0) {
|
|
SCLogDebug("Error: Invalid Chunk length: %u",
|