comparison src/event/quic/ngx_event_quic.h @ 8755:b4e6b7049984 quic

QUIC: normalize header inclusion. Stop including QUIC headers with no user-serviceable parts inside. This allows to provide a much cleaner QUIC interface. To cope with that, ngx_quic_derive_key() is now explicitly exported for v3 and quic modules. Additionally, this completely hides the ngx_quic_keys_t internal type.
author Sergey Kandaurov <pluknet@nginx.com>
date Tue, 13 Apr 2021 12:38:34 +0300
parents 915c2f7092ed
children baf9551b4a5b
comparison
equal deleted inserted replaced
8754:915c2f7092ed 8755:b4e6b7049984
83 ngx_quic_frames_stream_t *fs; 83 ngx_quic_frames_stream_t *fs;
84 ngx_uint_t cancelable; /* unsigned cancelable:1; */ 84 ngx_uint_t cancelable; /* unsigned cancelable:1; */
85 }; 85 };
86 86
87 87
88 typedef struct ngx_quic_keys_s ngx_quic_keys_t;
89
90
91 void ngx_quic_run(ngx_connection_t *c, ngx_quic_conf_t *conf); 88 void ngx_quic_run(ngx_connection_t *c, ngx_quic_conf_t *conf);
92 ngx_connection_t *ngx_quic_open_stream(ngx_connection_t *c, ngx_uint_t bidi); 89 ngx_connection_t *ngx_quic_open_stream(ngx_connection_t *c, ngx_uint_t bidi);
93 void ngx_quic_finalize_connection(ngx_connection_t *c, ngx_uint_t err, 90 void ngx_quic_finalize_connection(ngx_connection_t *c, ngx_uint_t err,
94 const char *reason); 91 const char *reason);
95 void ngx_quic_shutdown_connection(ngx_connection_t *c, ngx_uint_t err, 92 void ngx_quic_shutdown_connection(ngx_connection_t *c, ngx_uint_t err,
96 const char *reason); 93 const char *reason);
97 ngx_int_t ngx_quic_reset_stream(ngx_connection_t *c, ngx_uint_t err); 94 ngx_int_t ngx_quic_reset_stream(ngx_connection_t *c, ngx_uint_t err);
98 uint32_t ngx_quic_version(ngx_connection_t *c); 95 uint32_t ngx_quic_version(ngx_connection_t *c);
99 ngx_int_t ngx_quic_get_packet_dcid(ngx_log_t *log, u_char *data, size_t len, 96 ngx_int_t ngx_quic_get_packet_dcid(ngx_log_t *log, u_char *data, size_t len,
100 ngx_str_t *dcid); 97 ngx_str_t *dcid);
98 ngx_int_t ngx_quic_derive_key(ngx_log_t *log, const char *label,
99 ngx_str_t *secret, ngx_str_t *salt, u_char *out, size_t len);
101 100
102 #endif /* _NGX_EVENT_QUIC_H_INCLUDED_ */ 101 #endif /* _NGX_EVENT_QUIC_H_INCLUDED_ */