Fixing crash during TLS connection shutdown.

A crash was caused by an incorrect timer handler nxt_h1p_idle_timeout() if
SSL_shutdown() returned SSL_ERROR_WANT_READ/SSL_ERROR_WANT_WRITE.

The flag SSL_RECEIVED_SHUTDOWN is used to avoid getting SSL_ERROR_WANT_READ, so
the server won't wait for a close notification from a client.

For SSL_ERROR_WANT_WRITE, a correct timer handler is set up.
This commit is contained in:
Andrey Suvorov
2021-05-26 11:11:58 -07:00
parent d67a0c8711
commit 3efffddd95
5 changed files with 35 additions and 6 deletions

View File

@@ -68,6 +68,12 @@ compatibility with Ruby 3.0.
</para>
</change>
<change type="bugfix">
<para>
the router process could crash while closing TLS connection.
</para>
</change>
<change type="bugfix">
<para>
a segmentation fault might have occurred in the PHP module if