Skip to main content

MAX_EXPECTED_SNI

Constant MAX_EXPECTED_SNI 

Source
pub const MAX_EXPECTED_SNI: usize = 253;
Expand description

The longest host name a server_name extension can carry, in bytes.

A fully qualified DNS name is at most 255 bytes on the wire, of which two are the root label’s length byte and the trailing zero, leaving 253 for the presentation form. A configured name longer than that could never be matched, because no client could have asked for it.