networking

package
v1.15.1 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultPort = 7695
	DefaultHost = "127.0.0.1"
)

Variables

View Source
var AllowedLoopbackHostnames = map[string]bool{
	"localhost": true,
	"127.0.0.1": true,
	"::1":       true,
	"":          true,
}

Functions

func DetermineFreePort

func DetermineFreePort() int

func IsPortInUse

func IsPortInUse(u *url.URL) bool

func IsValidLoopbackRequest added in v1.13.2

func IsValidLoopbackRequest(r *http.Request) bool

func LoopbackURL

func LoopbackURL() (*url.URL, error)

func RandomLoopbackListener added in v1.13.2

func RandomLoopbackListener() (*url.URL, net.Listener, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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