Skip to content

[wordpress] Failed to enable crypto stream_socket_client

Published: at 02:32 PM (1 min read)

最近在優化 wordpress 的 site health,遇到了以下錯誤

/wp-json/wp/v2/types/post?context=edit
The REST API request failed due to an error.
Error: stream_socket_client(): SSL operation field with code 1. OpenSSL Error messages: error:0A000410:SSL routines::sslv3 alert handshake failure stream_socket_client: Failed to enable crypto stream_socket_client

解法:

  1. 安裝正確的 php7.4-curl (php-${version}-curl)

  2. 重啟 web server service nginx restart