utils

package
v0.1.20241022051413 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidCompression = errors.New("websocket: invalid compression negotiation")
View Source
var ErrMalformedURL = errors.New("malformed ws or wss URL")

Functions

func BufioWriterBuffer

func BufioWriterBuffer(originalWriter io.Writer, bw *bufio.Writer) []byte

bufioWriterBuffer grabs the buffer from a bufio.Writer.

func CloneTLSConfig

func CloneTLSConfig(cfg *tls.Config) *tls.Config

func ComputeAcceptKey

func ComputeAcceptKey(challengeKey string) string

func DoHandshake

func DoHandshake(ctx context.Context, tlsConn *tls.Conn, cfg *tls.Config) error

func HostPortNoPort

func HostPortNoPort(u *url.URL) (hostPort, hostNoPort string)

func TokenListContainsValue

func TokenListContainsValue(header http.Header, name string, value string) bool

func ValidCookieDomain

func ValidCookieDomain(v 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