NIOHTTPRequestHeadersValidator

A ChannelHandler to validate that outbound request headers are spec-compliant.

HTTPHeaderValidator.swift:25
final class NIOHTTPRequestHeadersValidator

The HTTP RFCs constrain the bytes that are validly present within a HTTP/1.1 header block. NIOHTTPRequestHeadersValidator polices this constraint and ensures that only valid header blocks are emitted on the network. If a header block is invalid, then NIOHTTPRequestHeadersValidator will send a invalidHeaderToken.

NIOHTTPRequestHeadersValidator will also valid that the HTTP trailers are within specification, if they are present.