comparison src/event/ngx_event_openssl.h @ 7431:294162223c7c

SSL: avoid reading on pending SSL_write_early_data(). If SSL_write_early_data() returned SSL_ERROR_WANT_WRITE, stop further reading using a newly introduced c->ssl->write_blocked flag, as otherwise this would result in SSL error "ssl3_write_bytes:bad length". Eventually, normal reading will be restored by read event posted from successful SSL_write_early_data(). While here, place "SSL_write_early_data: want write" debug on the path.
author Sergey Kandaurov <pluknet@nginx.com>
date Tue, 18 Dec 2018 15:15:15 +0300
parents 548a63b354a2
children a68799465b19
comparison
equal deleted inserted replaced
7430:286ae954009d 7431:294162223c7c
96 unsigned no_send_shutdown:1; 96 unsigned no_send_shutdown:1;
97 unsigned handshake_buffer_set:1; 97 unsigned handshake_buffer_set:1;
98 unsigned try_early_data:1; 98 unsigned try_early_data:1;
99 unsigned in_early:1; 99 unsigned in_early:1;
100 unsigned early_preread:1; 100 unsigned early_preread:1;
101 unsigned write_blocked:1;
101 }; 102 };
102 103
103 104
104 #define NGX_SSL_NO_SCACHE -2 105 #define NGX_SSL_NO_SCACHE -2
105 #define NGX_SSL_NONE_SCACHE -3 106 #define NGX_SSL_NONE_SCACHE -3