Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BaseURL ¶
BaseURL returns an estimate of the URL that the client used to access the service. Headers like X-Forwarded-Host are taken into account if the connection is from a trusted proxy.
func Middleware ¶
Middleware processes headers set by a trusted reverse proxy in front of the server. Client IPs are checked against the provided list of networks, and the "real" IP passed by the trusted proxy replaces req.RemoteAddr.
func PeerCertificates ¶
func PeerCertificates(req *http.Request) ([]*x509.Certificate, error)
PeerCertificates returns the unverified set of certificates provided by the client, using the Ssl-Client-Cert header if the connection is from a trusted proxy.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.