php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #59476 Segmentation Fault with parse_http_headers()
Submitted: 2010-10-26 11:16 UTC Modified: 2010-10-26 11:29 UTC
From: preinheimer@php.net Assigned:
Status: Closed Package: pecl_http (PECL)
PHP Version: 5.3.2 OS: Linux
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.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: preinheimer@php.net
New email:
PHP Version: OS:

 

 [2010-10-26 11:16 UTC] preinheimer@php.net
Description:
------------
When running this script at the command line (php ./crash.php) 
I get a 
segmentation fault. 

To reproduce, save this to a script, run an instance of PHP 
with the
pecl_http 
extension installed, make popcorn. 

Reproduce code:
---------------
<?php
$data = <<<DATA
HTTP/1.1 302
Date: Tue, 26 Oct 2010 14:53:04 GMT
Server: Apache/1.3.33 (Unix) mod_ssl/2.8.22 OpenSSL/0.9.7d SE/0.5.3
X-Pingback: http://www.onefortybpm.com/xmlrpc.php
X-Powered-By: PHP/4.4.8
Location: http://www.onefortybpm.com/
Content-Length: 0
Connection: close
Content-Type: text/html; charset=UTF-8
DATA;
var_dump($data);
var_dump(http_parse_headers($data));

Expected result:
----------------
no sad

Actual result:
--------------
lots of sad. (in seg fault form)



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-10-26 11:29 UTC] ilia@php.net
This bug has been fixed in SVN.

In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on pecl.php.net.

In case this was a pecl.php.net website problem, the change will show
up on the website in short time.
 
Thank you for the report, and for helping us make PECL better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 12:01:31 2024 UTC