Actions
Bug #77490
closedgeturl stream context doesn't respect ssl_* settings
Status:
Rejected
Priority:
Should have
Assignee:
-
Category:
System/Bootstrap/Configuration
Target version:
-
Start date:
2016-08-12
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:
Description
Hi all.
if ['SYS']['curlUse'] is false, we are using stream context in GeneralUtility::getUrl().
But there the ['HTTP']['ssl_*'] are not respected.
i think something like this is needed:
$sslOptions = array();
$sslOptions['verify_peer'] = $GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_verify_peer'];
$sslOptions['verify_peer_name'] = $GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_verify_host'];
if ($GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_verify_peer']) {
if ($GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_cafile']) {
$sslOptions['cafile'] = $GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_cafile'];
}
if ($GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_capath']) {
$sslOptions['capath'] = $GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_capath'];
}
}
stream_context_set_option( $ctx, $sslOptions);
greets, jochen
Actions