New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent mail fetch failure #2126

Open
wants to merge 1 commit into
base: develop
from

Conversation

Projects
None yet
3 participants
@ericLemanissier
Contributor

ericLemanissier commented Jun 1, 2015

For some incoming emails, the php function imap_headerinfo just fails to get the headers right, an example can be found below (see also http://php.net/manual/fr/function.imap-headerinfo.php#98809). Using imap_rfc822_parse_headers(imap_fetchheader()) corrects this

Return-Path: <>
Delivery-Date: Fri, 11 Apr 2014 03:27:57 +0100
Received: from spamreport by localhost id ******-********-**** for
 support@*****.com (mailbox m******-*****);
 Fri, 11 Apr 2014 03:27:57 +0100
From: =?utf-8?q?D=C3=A9tection_de_spam_=3Cnoreply=401and1=2Efr=3E?=
Subject: Rapport quotidien du dossier Spam du compte email
 support@*****.com
Date: Fri, 11 Apr 2014 03:27:57 +0100
To: <support@*****.com>
Message-Id: <******-******-****@spamreport.1and1.fr>
Envelope-To: support@*******.com
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable

Votre dossier Spam contient 1 nouveau message.

Les messages contenus dans ce dossier seront automatiquement
supprim=C3=A9s dans 28 jour(s).

More details available on the issue #850

Prevent mail fetch failure
For some incoming emails, the php function imap_headerinfo just fails to get the headers right, an example can be found below (see also http://php.net/manual/fr/function.imap-headerinfo.php#98809). Using imap_rfc822_parse_headers(imap_fetchheader()) corrects this

Return-Path: <>
Delivery-Date: Fri, 11 Apr 2014 03:27:57 +0100
Received: from spamreport by localhost id ******-********-**** for
 support@*****.com (mailbox m******-*****);
 Fri, 11 Apr 2014 03:27:57 +0100
From: =?utf-8?q?D=C3=A9tection_de_spam_=3Cnoreply=401and1=2Efr=3E?=
Subject: Rapport quotidien du dossier Spam du compte email
 support@*****.com
Date: Fri, 11 Apr 2014 03:27:57 +0100
To: <support@*****.com>
Message-Id: <******-******-****@spamreport.1and1.fr>
Envelope-To: support@*******.com
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable

Votre dossier Spam contient 1 nouveau message.

Les messages contenus dans ce dossier seront automatiquement
supprim=C3=A9s dans 28 jour(s).
@sdolemelipone

This comment has been minimized.

Show comment
Hide comment
@sdolemelipone

sdolemelipone Mar 22, 2017

This issue has been waiting to be fixed for a while now...is there any prospect of it being merged into a future version? Thanks.

sdolemelipone commented Mar 22, 2017

This issue has been waiting to be fixed for a while now...is there any prospect of it being merged into a future version? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment