Registry / networking / jpillora-ipfilter

jpillora-ipfilter

JSON →
library1.4.0gogounverified

Package ipfilter provides IP filtering utilities for Go.

go get github.com/jpillora/ipfilter
INSTALL
IMPORT
SIG · JPILLORA-IPFILTER
J
jpillora-ipfilter
networkinggov1.4.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

ipfilter
github.com/jpillora/ipfilter

Creates an IP filter and checks if an IP is allowed.

package main import ( "fmt" "github.com/jpillora/ipfilter" ) func main() { filter := ipfilter.New(ipfilter.Options{ AllowedIPs: []string{"192.168.0.0/16"}, }) fmt.Println(filter.Allowed("192.168.1.1")) }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
1.4.0latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
8 hits · last 30 days
node
8
Resources
jpillora-ipfilter — go get jpillora-ipfilter · libregistry