module

HTTP2::HTTPSemantics

Shared RFC 9113 field validation used by request construction and response parsing.

Constants

CONNECTION_FIELDS = ["connection", "proxy-connection", "keep-alive", "transfer-encoding", "upgrade"]

Instance methods

field_syntax_error(name : String, value : String, *, pseudo : Bool) : String | Nil
Source
parse_request_content_length(headers : Headers) : Int64 | Nil
Source
parse_response_section(fields : Enumerable(DecodedHeaderField), stream_id : UInt32) : ResponseSection
Source
regular_field_error(name : String, value : String, *, request : Bool, trailer : Bool) : String | Nil
Source
token_byte?(byte : UInt8) : Bool

Whether byte is a valid RFC 9110 tchar — shared by field-name validation here and by Client#validate_method!'s request-method check.

Source
validate_trailers(fields : Enumerable(DecodedHeaderField), stream_id : UInt32) : Headers
Source

Nested types