netguard

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Check

func Check(g Guard, ipStr string) bool

func DialContext

func DialContext(g Guard, ctx context.Context, network string, addr string) (net.Conn, error)

func HTTPClient

func HTTPClient(g Guard) *http.Client

func HTTPTransport

func HTTPTransport(g Guard) *http.Transport

Types

type Guard

type Guard struct {
	// contains filtered or unexported fields
}

func NewAllow

func NewAllow(cidrs []string) (Guard, error)

func NewBlock

func NewBlock(cidrs []string) (Guard, error)

func NewSSRFGuard

func NewSSRFGuard() Guard

Jump to

Keyboard shortcuts

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