Documentation
¶
Overview ¶
Package ip provides IP-based authorization middleware.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HandlerFunc ¶
func HandlerFunc(cfg authz.NetworkACLConfig, next http.Handler) (http.HandlerFunc, error)
HandlerFunc creates an IP-based authorization-wrapped HTTP handler function.
Types ¶
type Handler ¶ added in v0.37.0
type Handler struct {
Authoriser authz.Authoriser
}
Handler implements IP-based authorization for HTTP servers.
func NewHandler ¶ added in v0.37.0
func NewHandler(cfg authz.NetworkACLConfig) (*Handler, error)
NewHandler creates a new IP-based authorization handler.
func (*Handler) AuthRequest ¶ added in v0.37.0
AuthRequest checks if an HTTP request is authorized based on the remote IP address.
Click to show internal directories.
Click to hide internal directories.