netutil

package
v2.2.0-rc.0 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2015 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BasicAuth added in v2.1.0

func BasicAuth(r *http.Request) (username, password string, ok bool)

BasicAuth returns the username and password provided in the request's Authorization header, if the request uses HTTP Basic Authentication. See RFC 2617, Section 2. Based on the BasicAuth method from the Golang standard lib. TODO: use the standard lib BasicAuth method when we move to Go 1.4.

func DropPort added in v2.1.0

func DropPort(port int) error

DropPort drops all tcp packets that are received from the given port and sent to the given port.

func RecoverPort added in v2.1.0

func RecoverPort(port int) error

RecoverPort stops dropping tcp packets at given port.

func URLStringsEqual

func URLStringsEqual(a []string, b []string) bool

Types

This section is empty.

Jump to

Keyboard shortcuts

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