Documentation
¶
Overview ¶
Package xffecho adapts xff.TrustedProxies for use with the Echo web framework's X-Forwarded-For IP extraction.
Usage ¶
tp, err := fastlyxff.New("fastly.json")
if err != nil {
return err
}
trustOpts := xffecho.TrustOptions(tp)
e.IPExtractor = echo.ExtractIPFromXFFHeader(trustOpts...)
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func TrustOptions ¶
func TrustOptions(tp *xff.TrustedProxies) []echo.TrustOption
TrustOptions converts a xff.TrustedProxies into Echo trust options for use with echo.ExtractIPFromXFFHeader.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.