comparison src/http/v3/ngx_http_v3_encode.c @ 8072:985f9351dd87 quic

HTTP/3: do not set the never-indexed literal bit by default. The "Literal Header Field Never Indexed" header field representation is not used in HTTP/2, and it makes little sense to make a distinction in HTTP/3.
author Roman Arutyunyan <arut@nginx.com>
date Mon, 31 Aug 2020 18:42:26 +0300
parents 6e1798a4a0d2
children 0ac25efb2da3
comparison
equal deleted inserted replaced
8071:62b58f0a4711 8072:985f9351dd87
143 return ngx_http_v3_encode_prefix_int(NULL, index, 4) 143 return ngx_http_v3_encode_prefix_int(NULL, index, 4)
144 + ngx_http_v3_encode_prefix_int(NULL, len, 7) 144 + ngx_http_v3_encode_prefix_int(NULL, len, 7)
145 + len; 145 + len;
146 } 146 }
147 147
148 *p = dynamic ? 0x60 : 0x70; 148 *p = dynamic ? 0x40 : 0x50;
149 p = (u_char *) ngx_http_v3_encode_prefix_int(p, index, 4); 149 p = (u_char *) ngx_http_v3_encode_prefix_int(p, index, 4);
150 150
151 *p = 0; 151 *p = 0;
152 p = (u_char *) ngx_http_v3_encode_prefix_int(p, len, 7); 152 p = (u_char *) ngx_http_v3_encode_prefix_int(p, len, 7);
153 153
169 + name->len 169 + name->len
170 + ngx_http_v3_encode_prefix_int(NULL, value->len, 7) 170 + ngx_http_v3_encode_prefix_int(NULL, value->len, 7)
171 + value->len; 171 + value->len;
172 } 172 }
173 173
174 *p = 0x30; 174 *p = 0x20;
175 p = (u_char *) ngx_http_v3_encode_prefix_int(p, name->len, 3); 175 p = (u_char *) ngx_http_v3_encode_prefix_int(p, name->len, 3);
176 176
177 ngx_strlow(p, name->data, name->len); 177 ngx_strlow(p, name->data, name->len);
178 p += name->len; 178 p += name->len;
179 179
211 return ngx_http_v3_encode_prefix_int(NULL, index, 3) 211 return ngx_http_v3_encode_prefix_int(NULL, index, 3)
212 + ngx_http_v3_encode_prefix_int(NULL, len, 7) 212 + ngx_http_v3_encode_prefix_int(NULL, len, 7)
213 + len; 213 + len;
214 } 214 }
215 215
216 *p = 0x08; 216 *p = 0;
217 p = (u_char *) ngx_http_v3_encode_prefix_int(p, index, 3); 217 p = (u_char *) ngx_http_v3_encode_prefix_int(p, index, 3);
218 218
219 *p = 0; 219 *p = 0;
220 p = (u_char *) ngx_http_v3_encode_prefix_int(p, len, 7); 220 p = (u_char *) ngx_http_v3_encode_prefix_int(p, len, 7);
221 221