Documentation ¶
Overview ¶
Package websocket parses WebSocket frames out of TCP payload.
Index ¶
Constants ¶
View Source
const ( FlagFin = 0x80 OpBinary = 0x02 )
WebSocket flags and opcodes.
Variables ¶
This section is empty.
Functions ¶
func AnonymizeXForwardedFor ¶
func AnonymizeXForwardedFor(p []byte)
AnonymizeXForwardedFor recognizes an UPGRADE request and anonymizes IP address enclosed in X-Forwarded-For header. Initial 24 bits of IPv4 address and 48 bits of IPv6 address are kept; later bits are set to zeros.
Types ¶
Click to show internal directories.
Click to hide internal directories.