]> git.kaiwu.me - nginx.git/commit
SSL: ignored EIO after shutdown with kernel TLS
authorVadim Zhestikov <v.zhestikov@f5.com>
Tue, 29 Sep 2026 16:33:47 +0000 (09:33 -0700)
committerVadimZhestikov <108960056+VadimZhestikov@users.noreply.github.com>
Thu, 15 Oct 2026 15:13:24 +0000 (08:13 -0700)
commite72a6a0bc398f61b30bb426dd327df02a48ced3d
tree02bb7b6707dfac74d640b279403cb081fe27f92d
parent2b84cd7dd79097e86c06ae1eae1d743c58af164c
SSL: ignored EIO after shutdown with kernel TLS

After SSL shutdown, lingering close reads the socket with recv().  With
kernel TLS receive offload, which OpenSSL enables for TLS 1.3 since
3.2.0, recv() fails with EIO on a record other than application data,
such as the "close notify" alert from the client, and this was logged
at the "alert" level.

Now ngx_ssl_shutdown() marks connections with kernel TLS receive
offload, and EIO on such connections is ignored, so the read ends as
at EOF.

Reported by soukichi on GitHub.

Closes: https://github.com/nginx/nginx/issues/651
src/core/ngx_connection.c
src/core/ngx_connection.h
src/event/ngx_event_openssl.c
src/os/unix/ngx_errno.h