shell

package
v0.0.0-...-028f1de Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2024 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Ok                   = "Ok"
	Init_channel_failed  = "Init_channel_failed"
	Open_channel_failed  = "Open_channel_failed"
	Session_id_duplicate = "Session_id_duplicate"
	Process_data_error   = "Process_data_error"
	Open_pty_failed      = "Open_pty_failed"
	Timeout              = "Timeout"
	Notified             = "Notified"
	Unknown_error        = "Unknown_error"
)

Variables

This section is empty.

Functions

func StartPty

func StartPty(plugin *ShellPlugin) (err error)

Types

type ShellPlugin

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

func NewShellPlugin

func NewShellPlugin(id string, cmdContent string, username string, passwordName string, flowLimit int) *ShellPlugin

func (*ShellPlugin) Execute

func (p *ShellPlugin) Execute(dataChannel channel.ISessionChannel, cancelFlag util.CancelFlag) (errorCode string, pluginErr error)

func (*ShellPlugin) InputStreamMessageHandler

func (p *ShellPlugin) InputStreamMessageHandler(streamDataMessage message.Message) error

func (*ShellPlugin) SetSize

func (p *ShellPlugin) SetSize(ws_col, ws_row uint32) (err error)

type SizeData

type SizeData struct {
	Cols uint32 `json:"cols"`
	Rows uint32 `json:"rows"`
}

Jump to

Keyboard shortcuts

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