endpoint

package
v3.5.1 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Interpret

func Interpret(ep string) (address string, serverName string)

Interpret endpoint parses an endpoint of the form (http|https)://<host>*|(unix|unixs)://<path>) and returns low-level address (supported by 'net') to connect to, and a server name used for x509 certificate matching.

Types

type CredsRequirement

type CredsRequirement int
const (
	// CREDS_REQUIRE - Credentials/certificate required for thi type of connection.
	CREDS_REQUIRE CredsRequirement = iota
	// CREDS_DROP - Credentials/certificate not needed and should get ignored.
	CREDS_DROP
	// CREDS_OPTIONAL - Credentials/certificate might be used if supplied
	CREDS_OPTIONAL
)

func RequiresCredentials

func RequiresCredentials(ep string) CredsRequirement

RequiresCredentials returns whether given endpoint requires credentials/certificates for connection.

Jump to

Keyboard shortcuts

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