|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #67224 stream_socket_enable_crypto() requires crypto type when enabling
Submitted: 2014-05-07 10:20 UTC Modified: 2014-05-07 14:20 UTC
From: Assigned: rdlowrey (profile)
Status: Closed Package: Streams related
PHP Version: 5.6.0beta2 OS: Any
Private report: No CVE-ID: None
 [2014-05-07 10:20 UTC]
Since 5.6.x the crypto type can be determined from the ssl->crypto_method stream context value, it should no longer be a required argument. An error should emitted only when neither value is supplied.

Test script:
$sock = stream_socket_client('tcp://');
stream_context_set_option($sock, 'ssl', 'crypto_method', STREAM_CRYPTO_METHOD_TLS_CLIENT);
stream_socket_enable_crypto($sock, true);

Expected result:
Crypto enabling succeeds, with method determined from the stream's context options

Actual result:
Crypto enabling fails because 3rd argument is not supplied


Add a Patch

Pull Requests

Pull requests:

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2014-05-07 14:18 UTC]
-Status: Open +Status: Assigned -Assigned To: +Assigned To: rdlowrey
 [2014-05-07 14:20 UTC]
-Status: Assigned +Status: Closed
 [2014-05-07 14:20 UTC]
PR607 has been merged and this should now be fixed in PHP-5.6 and master. The changes will be reflected in the 5.6beta3 release.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Apr 15 04:01:28 2024 UTC