gowebsockifynovnc

package
v0.0.0-...-fc21188 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2020 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type WsnovncManager

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

func FileServer

func FileServer(root http.FileSystem) *WsnovncManager

FileServer returns a handler that serves HTTP requests with the contents of the file system rooted at root.

To use the operating system's file system implementation, use http.Dir:

http.Handle("/", http.FileServer(http.Dir("/tmp")))

As a special case, the returned file server redirects any request ending in "/index.html" to the same path, without the final "index.html".

func (*WsnovncManager) Connection

func (mg *WsnovncManager) Connection(token string, conn net.Conn, wsconn *websocket.Conn)

func (*WsnovncManager) Disconnection

func (mg *WsnovncManager) Disconnection(token string)

func (*WsnovncManager) Dispatch

func (mg *WsnovncManager) Dispatch(req *pb.VncReqResp) (*pb.VncReqResp, error)

func (*WsnovncManager) ServeHTTP

func (f *WsnovncManager) ServeHTTP(w http.ResponseWriter, r *http.Request)

func (*WsnovncManager) Token

func (mg *WsnovncManager) Token(id string) string

func (*WsnovncManager) ValidateVNC

func (mg *WsnovncManager) ValidateVNC(token string) (net.Conn, *websocket.Conn, string)

Jump to

Keyboard shortcuts

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