varnish-cache/include/tbl/h2_settings.h
0
/*-
1
 * Copyright (c) 2016 Varnish Software AS
2
 * All rights reserved.
3
 *
4
 * Author: Poul-Henning Kamp <phk@phk.freebsd.dk>
5
 *
6
 * SPDX-License-Identifier: BSD-2-Clause
7
 *
8
 * Redistribution and use in source and binary forms, with or without
9
 * modification, are permitted provided that the following conditions
10
 * are met:
11
 * 1. Redistributions of source code must retain the above copyright
12
 *    notice, this list of conditions and the following disclaimer.
13
 * 2. Redistributions in binary form must reproduce the above copyright
14
 *    notice, this list of conditions and the following disclaimer in the
15
 *    documentation and/or other materials provided with the distribution.
16
 *
17
 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20
 * ARE DISCLAIMED.  IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE
21
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27
 * SUCH DAMAGE.
28
 *
29
 * RFC7540 section 11.3
30
 *
31
 * Upper
32
 * lower
33
 * tag
34
 * default
35
 * min
36
 * max
37
 * range_error
38
 */
39
40
/*lint -save -e525 -e539 */
41
42 0
H2_SETTING(                                     // rfc7540,l,2097,2103
43
        HEADER_TABLE_SIZE,
44
        header_table_size,
45
        0x1,
46
        4096,                                   // rfc7540,l,4224,4224
47
        0,
48
        0xffffffff,
49
        0
50
)
51
52
#ifndef H2_SETTINGS_PARAM_ONLY
53 0
H2_SETTING(                                     // rfc7540,l,2105,2114
54
        ENABLE_PUSH,
55
        enable_push,
56
        0x2,
57
        1,                                      // rfc7540,l,4225,4225
58
        0,
59
        1,
60
        H2CE_PROTOCOL_ERROR
61
)
62
#endif
63
64 52
H2_SETTING(                                     // rfc7540,l,2116,2121
65
        MAX_CONCURRENT_STREAMS,
66
        max_concurrent_streams,
67
        0x3,
68
        0xffffffff,                             // rfc7540,l,4226,4226
69
        0,
70
        0xffffffff,
71
        0
72
)
73
74 104
H2_SETTING(                                     // rfc7540,l,2139,2148
75
        INITIAL_WINDOW_SIZE,
76
        initial_window_size,
77
        0x4,
78
        65535,                                  // rfc7540,l,4227,4227
79
        0,
80
        0x7fffffff,
81
        H2CE_FLOW_CONTROL_ERROR
82
)
83
84 26
H2_SETTING(                                     // rfc7540,l,2150,2157
85
        MAX_FRAME_SIZE,
86
        max_frame_size,
87
        0x5,
88
        16384,                                  // rfc7540,l,4228,4228
89
        16384,
90
        0x00ffffff,
91
        H2CE_PROTOCOL_ERROR
92
)
93
94 0
H2_SETTING(                                     // rfc7540,l,2159,2167
95
        MAX_HEADER_LIST_SIZE,
96
        max_header_list_size,
97
        0x6,
98
        0x7fffffff,                             // rfc7540,l,4229,4229
99
        0,
100
        0xffffffff,
101
        0
102
)
103
#undef H2_SETTING
104
105
/*lint -restore */