Package archipelagentvirtualmachinevnc :: Module websockify :: Class WebSocketProxy
[hide private]
[frames] | no frames]

Class WebSocketProxy

source code

        object --+            
                 |            
threading._Verbose --+        
                     |        
      threading.Thread --+    
                         |    
 websocket.WebSocketServer --+
                             |
                            WebSocketProxy

Proxy traffic to and from a WebSockets client to a normal TCP socket server target. All traffic to/from the client is base64 encoded/decoded to allow binary data to be sent/received to/from the target.

Nested Classes [hide private]

Inherited from websocket.WebSocketServer: EClose

Instance Methods [hide private]
 
__init__(self, *args, **kwargs)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
run_wrap_cmd(self) source code
 
started(self)
Called after Websockets server startup (i.e.
source code
 
poll(self)
Run periodically while waiting for connections.
source code
 
new_client(self)
Called after a new WebSocket connection has been established.
source code
 
get_target(self, target_cfg, path)
Parses the path, extracts a token, and looks for a valid target for that token in the configuration file(s).
source code
 
do_proxy(self, target)
Proxy client WebSocket to normal target socket.
source code

Inherited from websocket.WebSocketServer: do_SIGINT, do_handshake, fallback_SIGCHLD, msg, recv_frames, run, send_close, send_frames, start_server, stop, top_new_client, traffic, vmsg

Inherited from threading.Thread: __repr__, daemon, getName, ident, isAlive, isDaemon, is_alive, join, name, setDaemon, setName, start

Inherited from threading.Thread (private): _set_daemon, _set_ident

Inherited from threading._Verbose (private): _note

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __str__, __subclasshook__

Static Methods [hide private]

Inherited from websocket.WebSocketServer: decode_hixie, decode_hybi, encode_hixie, encode_hybi, gen_md5, socket, unmask

Class Variables [hide private]
  buffer_size = 65536
  traffic_legend = ...

Inherited from websocket.WebSocketServer: GUID, policy_response, server_handshake_hixie, server_handshake_hybi

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, *args, **kwargs)
(Constructor)

source code 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Overrides: object.__init__
(inherited documentation)

started(self)

source code 

Called after Websockets server startup (i.e. after daemonize)

Overrides: websocket.WebSocketServer.started

poll(self)

source code 

Run periodically while waiting for connections.

Overrides: websocket.WebSocketServer.poll
(inherited documentation)

new_client(self)

source code 

Called after a new WebSocket connection has been established.

Overrides: websocket.WebSocketServer.new_client

get_target(self, target_cfg, path)

source code 

Parses the path, extracts a token, and looks for a valid target for that token in the configuration file(s). Sets target_host and target_port if successful


Class Variable Details [hide private]

traffic_legend

Value:
"""
Traffic Legend:
    }  - Client receive
    }. - Client receive partial
    {  - Target receive

    >  - Target send
    >. - Target send partial
...