cli

package
v0.0.0-...-d0d3e00 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewHandlerCLI

func NewHandlerCLI(
	hostname string,
	port int,
	out io.Writer,

	newSSHClient func(
		hostname string,
		port int,
		username string,
		authMethod gossh.AuthMethod,
		knownHosts string,
	) (*ssh.SSHClient, error),
) pkg.CobraHandler

func PreRunESecretSet

func PreRunESecretSet(cmd *cobra.Command, args []string) error

Types

type Decryptor

type Decryptor func(cypherText string, privateKey *rsa.PrivateKey) (string, error)

type GetResponseParser

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

func NewGetResponseParser

func NewGetResponseParser(
	w io.Writer,
	privateKey *rsa.PrivateKey,
	decrypt Decryptor,
) GetResponseParser

func (GetResponseParser) Write

func (grp GetResponseParser) Write(p []byte) (int, error)

type InjectResponseParser

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

func NewInjectResponseParser

func NewInjectResponseParser(
	w io.Writer,
	privateKey *rsa.PrivateKey,
	decrypt Decryptor,
) InjectResponseParser

func (InjectResponseParser) Write

func (irp InjectResponseParser) Write(p []byte) (int, error)

type ListResponseParser

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

func NewListResponseParser

func NewListResponseParser(
	w io.Writer,
	privateKey *rsa.PrivateKey,
	decrypt Decryptor,
) ListResponseParser

func (ListResponseParser) Write

func (lrp ListResponseParser) Write(p []byte) (int, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳