Bug 496069 - php-imap imap_header() will crash with [toaddress] > 16384
php-imap imap_header() will crash with [toaddress] > 16384
Product: Fedora
Classification: Fedora
Component: php (Show other bugs)
x86_64 Linux
low Severity medium
: ---
: ---
Assigned To: Joe Orton
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2009-04-16 09:18 EDT by shr
Modified: 2009-07-14 11:37 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2009-07-14 11:37:16 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description shr 2009-04-16 09:18:36 EDT
Description of problem:
php-imap imap_header() will crash when [toaddress] > 16384

Version-Release number of selected component (if applicable):
php-imap-5.2.6-5.x86_64 (Fedora 10)
php-imap-5.2.6-2.fc9.x86_64 (Fedora 9)

How reproducible:
Call imap_header() with a message which has many receivers such that [toaddress] > 16384

Steps to Reproduce:
1.Get or create a message which has many receivers such that [toaddress] > 16384
2.Call imap_header() with this message
Actual results:

Expected results:
Process all receivers.

Additional info:
Test Program


$mail_user   = 'user';
$mail_passwd = 'pass';

$mbox = imap_open("{mail.org:995/pop3/ssl/novalidate-cert}", $mail_user, $mail_passwd);

$imap_errors = imap_errors();

for ($i = 0; $i < count($imap_errors); $i++) {
     echo "IMAP msg: $imap_errors[$i]\n";

if (!$mbox) {
    die('Could not Connect to imap: ' . $imap_errors[count($imap_errors)-1] . "\n");

$msg_num = imap_num_msg($mbox);

echo "Messages : $msg_num\n";

if ($msg_num == 0) {

$mail_header = imap_header($mbox, 1);

print_r ($mail_header);

Comment 1 shr 2009-04-16 22:33:04 EDT
imap_rfc822_parse_headers crash too.

$mail_header = imap_fecthheader( $mbox, 1 );
$mail_header_2 = imap_rfc822_parse_headers( $mail_header );

Comment 2 Joe Orton 2009-04-17 04:08:45 EDT
This is probably bug 452808.  Please try the 5.2.9 builds:

Comment 3 shr 2009-04-20 04:33:18 EDT

5.2.9 builds solve the problem
Comment 4 shr 2009-04-26 21:17:29 EDT

The 5.2.9 builds solve the problem, but they are not on the update server (Fedora 9 & 10) yet.

I was wondering when they will be on update server so we can update using yum.
Comment 5 Remi Collet 2009-04-27 03:00:56 EDT
You can update using yum from updates-testing repository.
Comment 6 Bug Zapper 2009-06-09 23:40:10 EDT
This message is a reminder that Fedora 9 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 9.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '9'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 9's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 9 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
Comment 7 Bug Zapper 2009-07-14 11:37:16 EDT
Fedora 9 changed to end-of-life (EOL) status on 2009-07-10. Fedora 9 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.