mirror of
https://github.com/nginx/nginx.git
synced 2026-10-24 13:04:26 +00:00
Fixed CRYPTO offset generation.
This commit is contained in:
parent
ccb0049e3f
commit
de095d5f1d
1 changed files with 6 additions and 0 deletions
|
|
@ -45,6 +45,9 @@ struct ngx_quic_connection_s {
|
|||
|
||||
ngx_quic_streams_t streams;
|
||||
ngx_uint_t max_data;
|
||||
|
||||
#define SSL_ECRYPTION_LAST ((ssl_encryption_application) + 1)
|
||||
uint64_t crypto_offset[SSL_ECRYPTION_LAST];
|
||||
};
|
||||
|
||||
|
||||
|
|
@ -228,9 +231,12 @@ ngx_quic_add_handshake_data(ngx_ssl_conn_t *ssl_conn,
|
|||
|
||||
frame->level = level;
|
||||
frame->type = NGX_QUIC_FT_CRYPTO;
|
||||
frame->u.crypto.offset += qc->crypto_offset[level];
|
||||
frame->u.crypto.len = len;
|
||||
frame->u.crypto.data = p;
|
||||
|
||||
qc->crypto_offset[level] += len;
|
||||
|
||||
ngx_sprintf(frame->info, "crypto, generated by SSL len=%ui level=%d", len, level);
|
||||
|
||||
ngx_quic_queue_frame(qc, frame);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue