remote

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: May 14, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BasicAuthCredentials

type BasicAuthCredentials struct {
	Username, Password string
}

type ConnectTokenJSON

type ConnectTokenJSON struct {
	Addr string

	RootCertificatePEM string

	ClientCertificatePEM        string
	ClientCertificatePrivateKey string
}

func NewConnectToken

func NewConnectToken(
	addr string,
	RootCertificate *x509.Certificate,
	clientCertificate *tls.Certificate,
) (ConnectTokenJSON, error)

func (ConnectTokenJSON) EncodeBase64

func (t ConnectTokenJSON) EncodeBase64() (string, error)

func (*ConnectTokenJSON) ToConnection

func (t *ConnectTokenJSON) ToConnection() (*Connection, error)

type Connection

type Connection struct {
	Address string
	Secrets ConnectionSecrets

	BasicAuthCredentials *BasicAuthCredentials

	Insecure bool
}

func (*Connection) ClientTLSConfig

func (c *Connection) ClientTLSConfig() *tls.Config

func (*Connection) MarshalJSON

func (c *Connection) MarshalJSON() ([]byte, error)

func (*Connection) UnmarshalJSON

func (c *Connection) UnmarshalJSON(bytes []byte) error

type ConnectionSecrets

type ConnectionSecrets struct {
	ServerRootCertificate *x509.Certificate
	ClientCertificate     *tls.Certificate
}

Directories

Path Synopsis
client

Jump to

Keyboard shortcuts

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