diff --git a/docs/index.rst b/docs/index.rst index ef301fd..b7f09ff 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -663,11 +663,14 @@ Run Davmail Because you are interacting with Davmail server over the loopback -(i.e. 127.0.0.1), pass the following options to ``parsedmarc``: +(i.e. 127.0.0.1), add the following options to ``parsedmarc.ini`` config file: -.. code-block:: bash +.. code-block:: ini - --imap-no-ssl -H 127.0.0.1 --imap-port 1143 + [imap] + host=127.0.0.1 + port=1143 + ssl=False Elasticsearch and Kibana ------------------------ diff --git a/parsedmarc/__init__.py b/parsedmarc/__init__.py index dc3f662..6bcf1e8 100644 --- a/parsedmarc/__init__.py +++ b/parsedmarc/__init__.py @@ -986,9 +986,10 @@ def get_dmarc_reports_from_inbox(host=None, try: raw_msg = server.fetch(msg_uid, ["RFC822"])[msg_uid] - msg_keys = [b'RFC822', b'BODY[NULL]'] + msg_keys = [b'RFC822', b'BODY[NULL]', b'BODY[]'] msg_key = '' - logging.debug("msg_keys: {0}".format(",".join(msg_keys))) + logging.debug("msg_keys: {0}".format(",".join( + raw_msg.keys()))) for key in msg_keys: if key in raw_msg.keys(): msg_key = key