All Classes Namespaces Files Functions Pages
Layer4.Tcp.Tunnel Class Reference

Creates a TCP port forwarding configuration between a local host and a remote server. More...

Methods

 Description.Get
 Returns a textual description of the object.
 
 Local.Port.Set
 Configures the local port number of the port mapping configuration. More...
 
 Parent.Get
 Returns the parent object.
 
 Remote.Address.Set
 Configures the IP of the remote endpoint. More...
 
 Remote.Port.Set
 Configures the remote port to which data will be forwarded. More...
 
 Start
 Activates the port mapping configuration. More...
 
 Stop
 Stops the port mapping configuration. More...
 

Class overview

Creates a TCP port forwarding configuration between a local host and a remote server.

Traffic is forwarded between localhost and the remote endpoint.

Since
API 2.7.0

Definition at line 10519 of file api.tcl.

Method documentation

Layer4.Tcp.Tunnel::Local.Port.Set

Configures the local port number of the port mapping configuration.

Example
1 $tcpTunnel Local.Port.Set 12345

Definition at line 10534 of file api.tcl.

Layer4.Tcp.Tunnel::Remote.Address.Set

Configures the IP of the remote endpoint.

Example
1 $tcpTunnel Remote.Address.Set "192.168.1.10"

Definition at line 10549 of file api.tcl.

Layer4.Tcp.Tunnel::Remote.Port.Set

Configures the remote port to which data will be forwarded.

Example
1 $tcpTunnel Remote.Port.Set 80

Definition at line 10559 of file api.tcl.

Layer4.Tcp.Tunnel::Start

Activates the port mapping configuration.

Once the port mapping is activated it becomes possible to access the remote endpoint through external applications like curl, wget, ssh or the a web browser.

For example: curl –insecure https://localhost:123435 wget –no-check-certificate https://localhost:12345 Of course, you can also use Tcl's networking packages like http.

Example
1 $tcpTunnel Start

Definition at line 10575 of file api.tcl.

Layer4.Tcp.Tunnel::Stop

Stops the port mapping configuration.

Example
1 $tcpTunnel Stop

Definition at line 10585 of file api.tcl.