You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: baggage/HTTP_HEADER_FORMAT.md
+11-7Lines changed: 11 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,6 +12,10 @@ Header name: `baggage`
12
12
In order to increase interoperability across multiple protocols and encourage successful integration,
13
13
implementations SHOULD keep the header name lowercase.
14
14
15
+
## Header Encoding
16
+
17
+
This header is a [[UTF-8]] encoded [[UNICODE]] string, however it uses only code points from the Basic Latin Unicode Block which are encoded identically in both Unicode and [[ASCII]].
18
+
15
19
## Header Content
16
20
17
21
This section uses the Augmented Backus-Naur Form (ABNF) notation of [[!RFC5234]].
@@ -50,17 +54,17 @@ Leading and trailing whitespaces (`OWS`) are allowed and are not considered to b
50
54
51
55
#### value
52
56
53
-
A value contains a string whose character encoding MUST be UTF-8 [[Encoding]].
54
-
Any characters outside of the `baggage-octet` range of characters MUST be percent-encoded.
55
-
The percent character MUST be percent-encoded.
56
-
Characters which are not required to be percent-encoded MAY be percent-encoded.
57
+
A string which contains a value identified by the `key`.
58
+
Any code points outside of the `baggage-octet` range MUST be percent-encoded.
59
+
The percent code point (`U+0025`) MUST be percent-encoded.
60
+
Code points which are not required to be percent-encoded MAY be percent-encoded.
57
61
Percent-encoding is defined in [[RFC3986]], Section 2.1: https://datatracker.ietf.org/doc/html/rfc3986#section-2.1.
58
62
59
-
When decoding the value, percent-encoded octet sequences that do not match the UTF-8 encoding scheme MUST be replaced with the replacement character (U+FFFD).
63
+
When decoding the value, percent-encoded octet sequences that do not match the UTF-8 encoding scheme MUST be replaced with the replacement code point (`U+FFFD`).
60
64
61
65
Leading and trailing whitespaces (`OWS`) are allowed and are not considered to be a part of the value.
62
66
63
-
Note, `value` MAY contain any number of the equal sign (`=`) characters. Parsers
67
+
Note, `value` MAY contain any number of the equal sign (`U+003D`) code points. Parsers
64
68
MUST NOT assume that the equal sign is only used to separate `key` and `value`.
Here is one more example where values with characters outside of the `baggage-octet` range of characters are percent-encoded. Consider the entry: `userId="Amélie"`, `serverNode="DF 28"`, `isProduction=false`:
117
+
Here is one more example where values with characters outside of the `baggage-octet` range are percent-encoded. Consider the entry: `userId="Amélie"`, `serverNode="DF 28"`, `isProduction=false`:
0 commit comments