ID: 22939 Updated by: [EMAIL PROTECTED] Reported By: simon dot wilmer at milestoneip dot com -Status: Open +Status: Feedback Bug Type: IMAP related Operating System: Red Hat 8.0 PHP Version: 4.3.1 New Comment:
Please try using this CVS snapshot: http://snaps.php.net/php4-STABLE-latest.tar.gz For Windows: http://snaps.php.net/win32/php4-win32-STABLE-latest.zip Previous Comments: ------------------------------------------------------------------------ [2003-03-28 09:53:17] simon dot wilmer at milestoneip dot com Hi, Using PHP 4.3.0 and 4.3.1 with IMAP_2001.RELEASE-CANDIDATE.1 and IMAP_2003.DEV.SNAP-0303181124 and Apache 1.3.27. The imap_header_info function returns an obkect with headers from an email, when trying to read the ->to, ->toaddress, ->cc, ->ccaddress, ->bcc, ->bccaddress values the page will crash if the from, cc or bcc field in the email itself is "()" or "<>" in the headers. Any normal text is fine, but the values above cause the page to crash. There is no error message returned unfortunately. Below is some sample code to test this. Also you will need to set the "from" in an email to () or <> to cause the problem. If anyone thinks it's a good idea I might email [EMAIL PROTECTED] as someone could "break" the mailbox of any web based email system by mailing an email with a "broken" from field. Sample code: <? $connection = imap_open('{localhost:143}INBOX', 'username', 'password'); $headers = imap_headerinfo($connection, 1); echo $headers->subject." <br>"; $var = $headers->from; if (is_array($var)) { //This line is where the script "hangs" echo $var[0]->mailbox."@".$var[0]->host; } ?> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=22939&edit=1