From 71d487cb9d21f08c80f135c6dcf3473e68723c61 Mon Sep 17 00:00:00 2001 From: saltzimania <83274494+saltzimania@users.noreply.github.com> Date: Sun, 21 Nov 2021 05:23:06 -0700 Subject: [PATCH] Environment Variable for PARSER_IMAP_IGNORE_ERROR (#14) * Update dmarcts-report-parser.conf Was getting the example error so added env variable so we can use docker-compose.yml to ignore errors. This was experienced with Exchange Online in Microsoft 365. This appears to have resolved the issue and dmarc reports were successfully retrieved and moved into the processed folder. * Update README.md * Update README.md Fixed tab character --- README.md | 5 ++++- manifest/usr/bin/dmarcts-report-parser.conf | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index b4b453f..50df31b 100644 --- a/README.md +++ b/README.md @@ -76,4 +76,7 @@ Use SSL instead of default TLS. Set both to 0 to turn off encryption. (not recom - "PARSER_IMAP_SSL=1" - "PARSER_IMAP_TLS=0" ``` - +Ignore ERROR: message_string() issue experienced with Exchange Online. +```yaml + - "PARSER_IMAP_IGNORE_ERROR=1" +``` diff --git a/manifest/usr/bin/dmarcts-report-parser.conf b/manifest/usr/bin/dmarcts-report-parser.conf index 332e5c9..3443c04 100644 --- a/manifest/usr/bin/dmarcts-report-parser.conf +++ b/manifest/usr/bin/dmarcts-report-parser.conf @@ -28,7 +28,7 @@ $imappass = $ENV{'PARSER_IMAP_PASS'}; $imapssl = $ENV{'PARSER_IMAP_SSL'} // '0'; # If set to 1, remember to change server port to 993 and disable imaptls. $imaptls = $ENV{'PARSER_IMAP_TLS'} // '1'; # Enabled as the default and best-practice. $tlsverify = $ENV{'PARSER_IMAP_VERIFY'} // '0'; # Enable verify server cert as the default and best-practice. -$imapignoreerror = 0; # set it to 1 if you see an "ERROR: message_string() +$imapignoreerror = $ENV{'PARSER_IMAP_IGNORE_ERROR'} // '0';# set it to 1 if you see an "ERROR: message_string() # expected 119613 bytes but received 81873 you may # need the IgnoreSizeErrors option" because of malfunction # imap server as MS Exchange 2007, ...