php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #34763 imap_headers() using pop3, throws notices, fetches entire message
Submitted: 2005-10-06 17:56 UTC Modified: 2005-10-15 01:00 UTC
Votes:11
Avg. Score:3.5 ± 1.1
Reproduced:9 of 10 (90.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: peterp at podbox dot co dot za Assigned:
Status: No Feedback Package: IMAP related
PHP Version: 5.0.5 OS: FreeBSD 5.3
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: peterp at podbox dot co dot za
New email:
PHP Version: OS:

 

 [2005-10-06 17:56 UTC] peterp at podbox dot co dot za
Description:
------------
Calling imap_headers() appears to fetch the ENTIRE message, instead of just the headers whilst using a pop3 mailbox. Not tested on IMAP, I assume it works though.

It also produces a bunch of notices, are these because of malformed emails?




Reproduce code:
---------------
$mBox = imap_open("{my.host.com:110/pop3}INBOX", $Username, $Password);

$mHeaders = @imap_headers($mBox);

echo '<pre>';
print_r($mHeaders);
echo '</pre>';


Expected result:
----------------
imap_headers(); to work correctly. 

1) Fetching only the headers
2) Using '@' to supress notices should work?
3) Not produce the PHP "notices."

Actual result:
--------------
<pre>
Array
(
    [0] => N        1) 6-Oct-2005 WASP ENQUIRIES       RE: BULK MMS Testing- wor (24382 chars)
    [1] => N        2) 6-Oct-2005 JC                   Fw: technicals.. (1517988 chars)
    [2] => N        3) 6-Oct-2005 Wynand Meijer - GTMT telkom (2493 chars)
    [3] => N        4) 6-Oct-2005 Willie van der Merwe Fw: Banking Integration (5313 chars)
)


*NOTE* I've removed some of my emails for the sake of keeping this bug report small.


Notice: Unknown: Unterminated mailbox: Undisclosed-Recipient@.MISSING-HOST-NAME. (errflg=3) in Unknown on line 0

Notice: Unknown: Unexpected characters at end of address: :;> (errflg=3) in Unknown on line 0

Notice: Unknown: Unterminated mailbox: Undisclosed-Recipient@.MISSING-HOST-NAME. (errflg=3) in Unknown on line 0

Notice: Unknown: Unexpected characters at end of address: :;> (errflg=3) in Unknown on line 0

Notice: Unknown: Unterminated mailbox: Undisclosed-Recipient@.MISSING-HOST-NAME. (errflg=3) in Unknown on line 0

Notice: Unknown: Unexpected characters at end of address: :;> (errflg=3) in Unknown on line 0
</pre>

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-10-07 09:25 UTC] sniper@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip


 [2005-10-15 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 12:01:29 2024 UTC