什么是Httptunnel 作為一個實際的例子,我們下面來介紹一個在"非公開領域"使用的的通道軟件,httptunnel。在httptunnel主頁(請參閱參考資料)上有這么一端話, httptunnel creates a bidirectional virtual data connection tunnelled in HTTP requests. The HTTP requests can be sent via an HTTP proxy if so desired. This can be useful for users behind restrictive firewalls. If WWW access is allowed through a HTTP proxy, it's possible to use httptunnel and, say, telnet or PPP to connect to a computer outside the firewall.
Ok,server以及client端都啟動了,我們可以開始我們的"通道"試驗了,在client.yiming.com上執行一下如下命令看看: Client.yiming.com#telnet localhost 1234 Trying 0.0.0.0... Connected to 0. Escape character is '^]'. SunOS 5.7 This is yiming's private box! Any question,contact me with [email protected] login:
看到B機的登錄提示符了,輸入賬號密碼看看是否工作正常? Login:yiming PassWord: (omit here;) ) sever.yiming.com# ls bak check go httpd lost+found mrtg run soft wg
OK! 工作正常,和正常的telnet沒有什么差別。
仔細觀察整個過程,會發現在最開始的地方顯示的是Trying 0.0.0.0...,Connected to 0.而不是Trying server.yiming.com…,Connect to server.yiming.com,這就很直觀的可以看出來client端是轉發1234數據包到本機80端口的。(然后再轉發到遠端)而不是直接連接遠端的B機。