- Saved searches
- Use saved searches to filter your results more quickly
- SSL: Handshake timed out Failed to enable crypto failed to open stream: operation failed #6423
- SSL: Handshake timed out Failed to enable crypto failed to open stream: operation failed #6423
- Comments
- PHP SSL: Handshake timed out?
- Saved searches
- Use saved searches to filter your results more quickly
- stream_socket_enable_crypto(): SSL: Handshake timed out — high CPU usage #73
- stream_socket_enable_crypto(): SSL: Handshake timed out — high CPU usage #73
- Comments
Saved searches
Use saved searches to filter your results more quickly
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SSL: Handshake timed out Failed to enable crypto failed to open stream: operation failed #6423
SSL: Handshake timed out Failed to enable crypto failed to open stream: operation failed #6423
Comments
I try to run composer update both as root user and my normal user and both are giving me this same exact error message all of a sudden and this composer update command was working just fine a few days ago
Trying command as root:
[root@db html]# composer update -vvv
Reading ./composer.json
Loading config file ./composer.json
Checked CA file /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem: valid
Failed to initialize global composer: Composer could not find the config file: /root/.config/composer/composer.json
To initialize a project, please create a composer.json file as described in the https://getcomposer.org/ «Getting Started» section
Reading /var/www/html/vendor/composer/installed.json
Loading plugin MagentoHackathon\Composer\Magento\Plugin
activate magento plugin
Running 1.4.1 (2017-03-10 09:29:45) with PHP 7.0.19 on Linux / 3.14.32-xxxx-grs-ipv6-64
Do not run Composer as root/super user! See https://getcomposer.org/root for details
Loading composer repositories with package information
Downloading https://repo.magento.com/packages.json
Downloading https://repo.magento.com/packages.json
Downloading https://repo.magento.com/packages.json
The «https://repo.magento.com/packages.json» file could not be downloaded: SSL: Handshake timed out
Failed to enable crypto
failed to open stream: operation failed
Exception trace:
() at /usr/share/php/Composer/Util/RemoteFilesystem.php:482
Composer\Util\RemoteFilesystem->get() at /usr/share/php/Composer/Util/RemoteFilesystem.php:101
Composer\Util\RemoteFilesystem->getContents() at /usr/share/php/Composer/Repository/ComposerRepository.php:661
Composer\Repository\ComposerRepository->fetchFile() at /usr/share/php/Composer/Repository/ComposerRepository.php:479
Composer\Repository\ComposerRepository->loadRootServerFile() at /usr/share/php/Composer/Repository/ComposerRepository.php:258
Composer\Repository\ComposerRepository->hasProviders() at /usr/share/php/Composer/DependencyResolver/Pool.php:99
Composer\DependencyResolver\Pool->addRepository() at /usr/share/php/Composer/Installer.php:376
Composer\Installer->doInstall() at /usr/share/php/Composer/Installer.php:223
Composer\Installer->run() at /usr/share/php/Composer/Command/UpdateCommand.php:158
Composer\Command\UpdateCommand->execute() at /usr/share/php/Symfony/Component/Console/Command/Command.php:259
Symfony\Component\Console\Command\Command->run() at /usr/share/php/Symfony/Component/Console/Application.php:849
Symfony\Component\Console\Application->doRunCommand() at /usr/share/php/Symfony/Component/Console/Application.php:193
Symfony\Component\Console\Application->doRun() at /usr/share/php/Composer/Console/Application.php:227
Composer\Console\Application->doRun() at /usr/share/php/Symfony/Component/Console/Application.php:124
Symfony\Component\Console\Application->run() at /usr/share/php/Composer/Console/Application.php:100
Composer\Console\Application->run() at /usr/bin/composer:55
Trying command as normal user:
bash-4.2$ composer update -vvv
Reading ./composer.json
Loading config file /var/lib/nginx/.config/composer/auth.json
Loading config file ./composer.json
Checked CA file /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem: valid
Failed to initialize global composer: Composer could not find the config file: /var/lib/nginx/.config/composer/composer.json
To initialize a project, please create a composer.json file as described in the https://getcomposer.org/ «Getting Started» section
Reading /var/www/html/vendor/composer/installed.json
Loading plugin MagentoHackathon\Composer\Magento\Plugin
activate magento plugin
Running 1.4.1 (2017-03-10 09:29:45) with PHP 7.0.19 on Linux / 3.14.32-xxxx-grs-ipv6-64
Loading composer repositories with package information
Downloading https://repo.magento.com/packages.json
Downloading https://repo.magento.com/packages.json
Downloading https://repo.magento.com/packages.json
Reading /var/lib/nginx/.cache/composer/repo/https—repo.magento.com/packages.json from cache
The «https://repo.magento.com/packages.json» file could not be downloaded: SSL: Handshake timed out
Failed to enable crypto
failed to open stream: operation failed
https://repo.magento.com could not be fully loaded, package information was loaded from the local cache and may be out of date
Exception trace:
() at /usr/share/php/Composer/Util/RemoteFilesystem.php:482
Composer\Util\RemoteFilesystem->get() at /usr/share/php/Composer/Util/RemoteFilesystem.php:101
Composer\Util\RemoteFilesystem->getContents() at /usr/share/php/Composer/Repository/ComposerRepository.php:661
Composer\Repository\ComposerRepository->fetchFile() at /usr/share/php/Composer/Repository/ComposerRepository.php:479
Composer\Repository\ComposerRepository->loadRootServerFile() at /usr/share/php/Composer/Repository/ComposerRepository.php:258
Composer\Repository\ComposerRepository->hasProviders() at /usr/share/php/Composer/DependencyResolver/Pool.php:99
Composer\DependencyResolver\Pool->addRepository() at /usr/share/php/Composer/Installer.php:376
Composer\Installer->doInstall() at /usr/share/php/Composer/Installer.php:223
Composer\Installer->run() at /usr/share/php/Composer/Command/UpdateCommand.php:158
Composer\Command\UpdateCommand->execute() at /usr/share/php/Symfony/Component/Console/Command/Command.php:259
Symfony\Component\Console\Command\Command->run() at /usr/share/php/Symfony/Component/Console/Application.php:849
Symfony\Component\Console\Application->doRunCommand() at /usr/share/php/Symfony/Component/Console/Application.php:193
Symfony\Component\Console\Application->doRun() at /usr/share/php/Composer/Console/Application.php:227
Composer\Console\Application->doRun() at /usr/share/php/Symfony/Component/Console/Application.php:124
Symfony\Component\Console\Application->run() at /usr/share/php/Composer/Console/Application.php:100
Composer\Console\Application->run() at /usr/bin/composer:55
The text was updated successfully, but these errors were encountered:
PHP SSL: Handshake timed out?
Здравствуйте, есть сервер Ubuntu 20 на котором присутствуют nginx и php 7.4
Сразу после их установки и настройки, простой тестовый сайт и на html и php запустился без проблем
Но при тесте одиночного php скрипта как из консоли, так и напрямую из браузера всё время появляется ошибка SSL: Handshake timed out и затем Failed to enable crypto
Данные ошибки возникали при использовании базовых функций file(); и file_get_contents();
При использовании curl такой проблемы не было
С чем связанна данная проблема и как её решить?
Средний 14 комментариев
Юрий, а прямо с сервера из консоли можешь попробовать:
curl -s -o /dev/null -D — https://vk.com
А так же: openssl s_client -connect vk.com:443
Александр Карабанов, да, и вк я привёл как пример, так будет при обращении к любому сайту независимо какой у него контент, хоть просто json
php -d display_errors=on -r 'echo (file_get_contents("https://vk.com"));'
Warning: file_get_contents(): SSL: Handshake timed out in Command line code on line 1
Call Stack:
0.0004 464008 1. () Command line code:0
0.0004 464008 2. file_get_contents() Command line code:1
Александр Карабанов,
php -i |grep openssl
libSSH Version => libssh/0.9.3/openssl/zlib
openssl
Openssl default config => /usr/lib/ssl/openssl.cnf
openssl.cafile => no value => no value
openssl.capath => no value => no value
php -r «var_dump(openssl_get_cert_locations());»
Command line code:1:
array(8) ‘default_cert_file’ =>
string(21) «/usr/lib/ssl/cert.pem»
‘default_cert_file_env’ =>
string(13) «SSL_CERT_FILE»
‘default_cert_dir’ =>
string(18) «/usr/lib/ssl/certs»
‘default_cert_dir_env’ =>
string(12) «SSL_CERT_DIR»
‘default_private_dir’ =>
string(20) «/usr/lib/ssl/private»
‘default_default_cert_area’ =>
string(12) «/usr/lib/ssl»
‘ini_cafile’ =>
string(0) «»
‘ini_capath’ =>
string(0) «»
>
Александр Карабанов, это странно и банально, но это сработало
Спасибо вам большое, моё уважение
Только почему он не работает при -1, не понятно
Saved searches
Use saved searches to filter your results more quickly
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
stream_socket_enable_crypto(): SSL: Handshake timed out — high CPU usage #73
stream_socket_enable_crypto(): SSL: Handshake timed out — high CPU usage #73
Comments
Hi @arthurkushman
Can you please take a look at the errors:
[root@testing9920 wss]# php public/hello.old.php PHP Warning: fwrite(): SSL: Broken pipe in /home/wss/vendor/arthurkushman/php-wss/src/Components/Connection.php on line 45 PHP Warning: fwrite(): SSL: Broken pipe in /home/wss/vendor/arthurkushman/php-wss/src/Components/Connection.php on line 45 PHP Warning: fwrite(): SSL: Broken pipe in /home/wss/vendor/arthurkushman/php-wss/src/Components/Connection.php on line 45 PHP Warning: fwrite(): SSL: Broken pipe in /home/wss/vendor/arthurkushman/php-wss/src/Components/Connection.php on line 45 PHP Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:142090FC:SSL routines:tls_early_post_process_client_hello:unknown protocol in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:1408F09C:SSL routines:ssl3_get_record:http request in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:1408F09C:SSL routines:ssl3_get_record:http request in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: fwrite(): SSL: Broken pipe in /home/wss/vendor/arthurkushman/php-wss/src/Components/Connection.php on line 45 PHP Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:1408F10B:SSL routines:ssl3_get_record:wrong version number in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:1408F09C:SSL routines:ssl3_get_record:http request in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL: Handshake timed out in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL: Handshake timed out in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:1408F09C:SSL routines:ssl3_get_record:http request in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: fwrite(): SSL: Broken pipe in /home/wss/vendor/arthurkushman/php-wss/src/Components/Connection.php on line 45 PHP Warning: stream_socket_enable_crypto(): SSL: Handshake timed out in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL: Handshake timed out in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL: Handshake timed out in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL: Handshake timed out in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 PHP Warning: stream_socket_enable_crypto(): SSL: Handshake timed out in /home/wss/vendor/arthurkushman/php-wss/src/WebSocketServer.php on line 194 Terminated [root@testing9920 wss]#
I should be able to find solution but would appriciate if you already have better solution and can provide us.
Thank you.
The text was updated successfully, but these errors were encountered: