SYSTEM WARNING: 'file_get_contents(https://www.clearos.com/?rendertype=json&get=header): failed to open stream: Connection refused' in '/var/www/virtual/newwrapper/cf_topmenu.inc' line 5

ClearOS Bug Tracker


View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000212ClearOSapp-mail-archive - Mail Archivepublic2010-11-18 13:212012-04-18 19:39
Reporterbchambers 
Assigned Touser2 
PriorityhighSeveritymajorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version5.2-SP1 
Target VersionFixed in Version5.2-SP1 
Summary0000212: Mail Archive stops importing messages to database when header exceeds 4kb
DescriptionMessages having headers of 4kb or larger (think very long to or cc lists) will cause one of the PHP functions used to grab message headers segfaults. This causes a permanent impairment to move mail messages that should be archived from the IMAP store to the server MySQL database.

Only known workaround to date (other than using a mail client and deleting the message(s) with > 4kb headers) is to skip over them:

Around line 1540 in /var/webconfig/api/Archive.class.php, add:

if (strlen(imap_fetchheader($mbox, $index)) > 4096) {
  echo "Skipping message with header that exceds 4kb";
  imap_delete($mbox, $index);
  continue;
}
Additional InformationAdditional References:
http://bugs.php.net/bug.php?id=47736 [^]
http://www.redhat.com/archives/rhl-devel-list/2004-September/msg00872.html [^]
http://webaugur.com/dave/blogger/2009/06/php-imap-extension-evil.html [^]
http://www.washington.edu/imap/documentation/RELNOTES.html [^]
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0000344)
dloper (administrator)
2011-03-24 11:04

Needs testing against 5.2. Doesn't show up on my system when used with a 7k header.
(0000349)
flygarvagen (reporter)
2011-04-19 08:53

I just would like to confirm that the fix shown in the decription works in 5.2. After fix installation, all mail slowly began to show up in archived e-mails.
(0000355)
user2
2011-05-24 15:11

A "yum upgrade" will install the more recent version of libc-client

- Issue History
Date Modified Username Field Change
2010-11-18 13:21 bchambers New Issue
2010-11-18 13:22 bchambers Status new => confirmed
2010-11-18 13:22 bchambers Description Updated
2011-03-24 11:04 dloper Note Added: 0000344
2011-04-19 08:53 flygarvagen Note Added: 0000349
2011-05-24 15:11 user2 Note Added: 0000355
2011-05-24 15:11 user2 Status confirmed => resolved
2011-05-24 15:11 user2 Fixed in Version => 5.2-SP1
2011-05-24 15:11 user2 Resolution open => fixed
2011-05-24 15:11 user2 Assigned To => user2
2012-04-18 19:39 user2 Status resolved => closed

SYSTEM WARNING: 'file_get_contents(https://www.clearos.com/?rendertype=json&get=footer): failed to open stream: Connection refused' in '/var/www/virtual/newwrapper/cf_footer.inc' line 7