In WSGI headers are represented in the environ as 'HTTP_XXX' values. For example the value Cookie:
header is stored at the HTTP_COOKIE
key of the environ.
How are multiple request headers with the same header name represented?
A recipient MAY combine multiple header fields with the same field name into one field-name: field-value pair, without changing the semantics of the message, by appending each subsequent field value to the combined field value in order, separated by a comma.
The HTTP Headers can have one or more values depending on the header field definitions. A multi-valued header will have comma separated values.
Multiple cookies are combined into a single header, separated by semicolons.
Multiple headers are allowed by the HTTP spec, but only for certain kinds of headers, and it is always permissible to combine those headers into one (though using commas, not semicolons)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With