Doc #52945 [Opn->Csd]: ssl stream context options misdocument capture_peer_chain

From: Date: Fri, 01 Oct 2010 10:14:51 +0000
Subject: Doc #52945 [Opn->Csd]: ssl stream context options misdocument capture_peer_chain
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-5150@lists.php.net to get a copy of this message
Edit report at http://bugs.php.net/bug.php?id=52945&edit=1 ID: 52945 Updated by: cataphract@php.net Reported by: blacklight332 at aol dot com Summary: ssl stream context options misdocument capture_peer_chain -Status: Open +Status: Closed Type: Documentation Problem Package: Documentation problem Operating System: Ubuntu Linux 10.10 PHP Version: 5.3.3 -Assigned To: +Assigned To: cataphract Block user comment: N New Comment: This bug has been fixed in the documentation's XML sources. Since the online and downloadable versions of the documentation need some time to get updated, we would like to ask you to be a bit patient. Thank you for the report, and for helping us make our documentation better. Previous Comments: ------------------------------------------------------------------------ [2010-10-01 12:14:40] cataphract@php.net Automatic comment from SVN on behalf of cataphract Revision: http://svn.php.net/viewvc/?view=revision&revision=303915 Log: - SSL context option capture_peer_chain is actually named capture_peer_cert_chain (fixes bug #52945). ------------------------------------------------------------------------ [2010-09-28 22:21:18] blacklight332 at aol dot com Updated email address to an email that I don't care if it gets spammed, cause this page is publicly accessible. ------------------------------------------------------------------------ [2010-09-28 22:03:50] jonesmw at gmail dot com documenting the segfault in a different php bug... this php bug is only about the misdocumentation ------------------------------------------------------------------------ [2010-09-28 22:02:15] blacklight332 at aol dot com Description: ------------ http://www.php.net/manual/en/context.ssl.php shows two options capture_peer_cert and capture_peer_chain capture_peer_chain does nothing. I tried everything... then I grepped the source code of php 5.3.3 and found it was actually named capture_peer_cert_chain solution: change the name in the documentation to capture_peer_cert_chain instead of capture_peer_chain on http://www.php.net/manual/en/context.ssl.php Test script: --------------- //$g = stream_context_create (array("ssl" => array("capture_peer_cert" => true,"capture_peer_cert_chain" => true,))); $g = stream_context_create (array("ssl" => array("capture_peer_cert" => true,"capture_peer_chain" => true,))); $r = stream_socket_client("ssl://www.digicert.com:443", $errno, $errstr, 30, STREAM_CLIENT_CONNECT, $g); $cont = stream_context_get_params($r); var_dump($cont['options']['ssl']); Expected result: ---------------- array(3) { ["capture_peer_cert"]=> bool(true) ["capture_peer_chain"]=> bool(true) ["peer_certificate"]=> resource(6) of type (OpenSSL X.509) ["peer_certificate_chain"]=> [something here] } Actual result: -------------- array(3) { ["capture_peer_cert"]=> bool(true) ["capture_peer_chain"]=> bool(true) ["peer_certificate"]=> resource(6) of type (OpenSSL X.509) } ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/bug.php?id=52945&edit=1

« previous php.doc.bugs (#5150) next »