Documentation ¶
Index ¶
- Constants
- func Disconnect(ws *websocket.Conn, code int, msg string)
- type Configuration
- type Instruction
- type Manager
- type Session
- type Tunnel
- func (t *Tunnel) Close() error
- func (t *Tunnel) Handshake(config *Configuration) (err error)
- func (t *Tunnel) Read() (p []byte, err error)
- func (t *Tunnel) ReadInstruction() (instruction *Instruction, err error)
- func (t *Tunnel) WriteAndFlush(p []byte) (int, error)
- func (t *Tunnel) WriteInstructionAndFlush(instruction *Instruction) error
Constants ¶
View Source
const ( EnableRecording = "enable-recording" RecordingPath = "recording-path" CreateRecordingPath = "create-recording-path" FontName = "font-name" FontSize = "font-size" ColorScheme = "color-scheme" Backspace = "backspace" TerminalType = "terminal-type" PreConnectionId = "preconnection-id" PreConnectionBlob = "preconnection-blob" EnableDrive = "enable-drive" DriveName = "drive-name" DrivePath = "drive-path" EnableWallpaper = "enable-wallpaper" EnableTheming = "enable-theming" EnableFontSmoothing = "enable-font-smoothing" EnableFullWindowDrag = "enable-full-window-drag" EnableDesktopComposition = "enable-desktop-composition" EnableMenuAnimations = "enable-menu-animations" DisableBitmapCaching = "disable-bitmap-caching" DisableOffscreenCaching = "disable-offscreen-caching" // DisableGlyphCaching Deprecated DisableGlyphCaching = "disable-glyph-caching" ForceLossless = "force-lossless" Domain = "domain" RemoteApp = "remote-app" RemoteAppDir = "remote-app-dir" RemoteAppArgs = "remote-app-args" ColorDepth = "color-depth" Cursor = "cursor" SwapRedBlue = "swap-red-blue" DestHost = "dest-host" DestPort = "dest-port" ReadOnly = "read-only" UsernameRegex = "username-regex" PasswordRegex = "password-regex" LoginSuccessRegex = "login-success-regex" LoginFailureRegex = "login-failure-regex" Namespace = "namespace" Pod = "pod" Container = "container" UesSSL = "use-ssl" ClientCert = "client-cert" ClientKey = "client-key" CaCert = "ca-cert" IgnoreCert = "ignore-cert" )
View Source
const Delimiter = ';'
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Configuration ¶
type Configuration struct { // ConnectionID is used to reconnect to an existing session, otherwise leave blank for a new session. ConnectionID string // Protocol is the protocol of the connection from guacd to the remote (rdp, ssh, etc). Protocol string // Parameters are used to configure protocol specific options like sla for rdp or terminal color schemes. Parameters map[string]string }
Config is the data sent to guacd to configure the session during the handshake.
func (*Configuration) GetParameter ¶
func (c *Configuration) GetParameter(name string) string
func (*Configuration) LoadConfig ¶
func (opt *Configuration) LoadConfig() map[string]string
func (*Configuration) SetParameter ¶
func (c *Configuration) SetParameter(name, value string)
func (*Configuration) SetReadOnlyMode ¶
func (c *Configuration) SetReadOnlyMode()
func (*Configuration) UnSetParameter ¶
func (c *Configuration) UnSetParameter(name string)
type Instruction ¶
func NewInstruction ¶
func NewInstruction(opcode string, args ...string) *Instruction
func (*Instruction) Parse ¶
func (i *Instruction) Parse(content string) *Instruction
func (*Instruction) String ¶
func (i *Instruction) String() string
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
var GlobalSessionManager *Manager
func NewManager ¶
func NewManager() *Manager
func NewObserver ¶
type Session ¶
type Session struct { Id string Protocol string Mode string WebSocket *websocket.Conn GuacdTunnel *Tunnel Observer *Manager Uptime int64 Hostname string // contains filtered or unexported fields }
func (*Session) WriteString ¶
type Tunnel ¶
func (*Tunnel) Handshake ¶
func (t *Tunnel) Handshake(config *Configuration) (err error)
func (*Tunnel) ReadInstruction ¶
func (t *Tunnel) ReadInstruction() (instruction *Instruction, err error)
func (*Tunnel) WriteInstructionAndFlush ¶
func (t *Tunnel) WriteInstructionAndFlush(instruction *Instruction) error
Click to show internal directories.
Click to hide internal directories.