|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2015-08-29 11:47 UTC] cmb@php.net
-Status: Open
+Status: Not a bug
-Assigned To:
+Assigned To: cmb
[2015-08-29 11:47 UTC] cmb@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Oct 29 12:00:01 2025 UTC |
Description: ------------ Debian GNU/Linux 7 - PHP 5.4.36-0+deb7u3 Ubuntu 14.10 - PHP 5.5.12-2ubuntu4.2 Problem with parse imap headers from mailer delivery daemon. Header from isn't properly handled in case when mail came form mailer daemon. Test script: --------------- This is mail: Delivered-To: addr@foo.bar Received: by 10.64.25.193 with SMTP id e1csp360082ieg; Wed, 18 Feb 2015 23:21:19 -0800 (PST) X-Received: by 10.180.73.241 with SMTP id o17mr7637081wiv.16.1424330476433; Wed, 18 Feb 2015 23:21:16 -0800 (PST) Return-Path: <> Received: from antyspam.addr@bar.baz (smtp.addr@bar.baz. [0.0.0.0]) by mx.google.com with ESMTPS id ft7si39444898wjb.169.2015.02.18.23.21.15 for <addr@foo.bar> (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 18 Feb 2015 23:21:16 -0800 (PST) Received-SPF: none (google.com: antyspam.addr@bar.baz does not designate permitted sender hosts) client-ip=0.0.0.0; Authentication-Results: mx.google.com; spf=none (google.com: antyspam.addr@bar.baz does not designate permitted sender hosts) smtp.mail= Received: by antyspam.addr@bar.baz (Spam Firewall) id 40635119E0BB; Thu, 19 Feb 2015 08:21:15 +0100 (CET) Date: Thu, 19 Feb 2015 08:21:15 +0100 (CET) From: MAILER-DAEMON (Mail Delivery System) Subject: Undelivered Mail Returned to Sender $result = imap_headerinfo($, 1); Expected result: ---------------- stdClass Object ( [date] => Thu, 19 Feb 2015 08:21:15 +0100 (CET) [Date] => Thu, 19 Feb 2015 08:21:15 +0100 (CET) [subject] => Undelivered Mail Returned to Sender [Subject] => Undelivered Mail Returned to Sender [message_id] => <20150219072115.40635119E0BB@antyspam.foo.foo> [fromaddress] => MAILER-DAEMON [toaddress] => addr@foo.bar [to] => Array ( [0] => stdClass Object ( [mailbox] => addr [host] => foo.bar ) ) [Recent] => [Unseen] => U [Flagged] => [Answered] => [Deleted] => [Draft] => [Msgno] => 752 [MailDate] => 20-Feb-2015 08:20:13 +0000 [Size] => 23704 [udate] => 1424420413 ) Actual result: -------------- stdClass Object ( [date] => Thu, 19 Feb 2015 08:21:15 +0100 (CET) [Date] => Thu, 19 Feb 2015 08:21:15 +0100 (CET) [subject] => Undelivered Mail Returned to Sender [Subject] => Undelivered Mail Returned to Sender [message_id] => <20150219072115.40635119E0BB@antyspam.foo.foo> [toaddress] => addr@foo.bar [to] => Array ( [0] => stdClass Object ( [mailbox] => addr [host] => foo.bar ) ) [Recent] => [Unseen] => U [Flagged] => [Answered] => [Deleted] => [Draft] => [Msgno] => 752 [MailDate] => 20-Feb-2015 08:20:13 +0000 [Size] => 23704 [udate] => 1424420413 )