Skip to content

Fix flaky stream_socket_get_crypto_status handshake test#22707

Merged
bukka merged 1 commit into
php:masterfrom
bukka:openssl_socket_crypto_status_test_race
Jul 12, 2026
Merged

Fix flaky stream_socket_get_crypto_status handshake test#22707
bukka merged 1 commit into
php:masterfrom
bukka:openssl_socket_crypto_status_test_race

Conversation

@bukka

@bukka bukka commented Jul 12, 2026

Copy link
Copy Markdown
Member

The test could intermittently fail because a non-blocking TLS handshake can complete in a single stream_socket_enable_crypto() call, so WANT_READ/WANT_WRITE was never observed and $sawWant stayed false.

Route the connection through a plain TCP proxy that forwards the server handshake flight in fragments, forcing the client to see a partial TLS record and report WANT_READ at least once.

The test could intermittently fail because a non-blocking TLS handshake
can complete in a single stream_socket_enable_crypto() call, so
WANT_READ/WANT_WRITE was never observed and $sawWant stayed false.

Route the connection through a plain TCP proxy that forwards the server
handshake flight in fragments, forcing the client to see a partial TLS
record and report WANT_READ at least once.
@bukka bukka force-pushed the openssl_socket_crypto_status_test_race branch from d835cdf to 6f8a127 Compare July 12, 2026 15:20
@bukka

bukka commented Jul 12, 2026

Copy link
Copy Markdown
Member Author

Solaris failure unrelated (poll issue that is being fixed in GH-22708) and the one for this no longer present so merging

@bukka bukka merged commit 2a712fb into php:master Jul 12, 2026
17 of 18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant