Module v2
Expand description
Version 2 of the HAProxy protocol (binary version).
Structs§
- Builder
- Implementation of the builder pattern for PROXY protocol v2 headers.
Supports both valid and invalid headers via the
write_payload
andwrite_payloads
functions. - Header
- A proxy protocol version 2 header.
- IPv4
- The source and destination IPv4 addresses and TCP ports of a header.
- IPv6
- The source and destination IPv6 addresses and TCP ports of a header.
- Type
Length Value - A Type-Length-Value payload.
- Type
Length Values - An
Iterator
ofTypeLengthValue
s stored in a byte slice. - Unix
- The source and destination addresses of UNIX sockets.
- Writer
Write
interface for the builder’s internal buffer. Can be used to turn header parts into bytes.
Enums§
- Address
Family - The supported
AddressFamily
for a PROXY protocol header. - Addresses
- The source and destination address information for a given
AddressFamily
. - Command
- The supported
Command
s for a PROXY protocol header. - Parse
Error - An error in parsing a binary PROXY protocol header.
- Protocol
- The supported
Protocol
s for a PROXY protocol header. - Type
- Supported types for
TypeLengthValue
payloads. - Version
- The supported
Version
s for binary headers.
Constants§
- PROTOCOL_
PREFIX - The prefix of the PROXY protocol header.
Traits§
- Write
ToHeader - Defines how to write a type as part of a binary PROXY protocol header.