sshchannel

package
v0.3.7 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2022 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Channel

type Channel interface {
	StartSocks5Proxy(privateKey, sshAddress, socks5Address string) error
	ForwardRemoteToLocal(privateKey, sshAddress, remoteEndpoint, localEndpoint string) error
	RunScript(privateKey, sshAddress, script string) (string, error)
}

Channel network channel

func Ins

func Ins() Channel

Ins get singleton instance

type Cli

type Cli struct{}

Cli the singleton type

func (*Cli) ForwardRemoteToLocal

func (c *Cli) ForwardRemoteToLocal(privateKey, sshAddress, remoteEndpoint, localEndpoint string) error

ForwardRemoteToLocal forward remote request to local

func (*Cli) RunScript

func (c *Cli) RunScript(privateKey, sshAddress, script string) (result string, err error)

RunScript run the script on remote host.

func (*Cli) StartSocks5Proxy

func (c *Cli) StartSocks5Proxy(privateKey, sshAddress, socks5Address string) (err error)

StartSocks5Proxy start socks5 proxy

type SocksLogger

type SocksLogger struct{}

func (SocksLogger) Println

func (s SocksLogger) Println(v ...any)

Jump to

Keyboard shortcuts

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