ip

package
v0.14.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 22, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddressForRequest

func AddressForRequest(r *http.Request) string

AddressForRequest returns the real IP address of the request

func FromRequest added in v0.14.4

func FromRequest(r *http.Request) string

FromRequest retrieves remote user IP from http.Request that went through our middleware

func IsPrivateSubnet

func IsPrivateSubnet(ipAddress net.IP) bool

IsPrivateSubnet checks if this ip is in a private subnet

func Middleware added in v0.14.4

func Middleware(next http.Handler) http.Handler

Middleware will attach remote user IP to every request

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL