utils

package
v1.19.2 Latest Latest
Warning

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

Go to latest
Published: Mar 23, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrCast = errors.New("unable to cast")

Functions

func CastToSlice

func CastToSlice[T any](tokenGroups any) ([]T, error)

func LookupGroup added in v1.16.0

func LookupGroup(groupName string) (int, error)

func StringConcat added in v1.6.0

func StringConcat(strs ...string) string

func TransformCommonName added in v1.12.0

func TransformCommonName(mode config.OpenVPNCommonNameMode, commonName string) string

Types

type UserAgentTransport added in v1.13.0

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

func NewUserAgentTransport added in v1.13.0

func NewUserAgentTransport(rt http.RoundTripper) *UserAgentTransport

func (*UserAgentTransport) RoundTrip added in v1.13.0

func (adt *UserAgentTransport) RoundTrip(req *http.Request) (*http.Response, error)

Jump to

Keyboard shortcuts

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