[教學] SSH tunneling with copSSH and plink
Before reading this document, you may need know what is tunneling.
Please wiki "Tunneling protocol" first^^
Server Side:
use copSSH
Official Site:
http://www.itefix.no/copssh/
Download Path:
http://jaist.dl.sourceforge.net/sourceforge/sereds/Copssh_1.4.5_Installer.zip
Descript:
It's a SSH server ported from GNU/LINUX source project.
In GNU/Linux, it's run as "sshd" (Deamon Process).
In Windows, it use Cygwin to wrapper the sshd.
service execute: C:\Program Files\copSSH\bin\cygrunsrv.exe
service name: copSSHD
service friend name: Openssh SSHD
Step 1. Just install it.
Step 2. Choose an existed Windows user as login user.
(01. Activate a user)
By default, it would use /bin/bash for user shell.
For security, you may use redirect to /bin/false.
(only with plink.exe)
ps. SSH user password is just the same as
Windows login password.
Step 3. Try to modify "sshd_config" in your "install path"\etc of copSSH
You may customize your server setting here.
Wanna to keep the connection of SSH without timeout?
modify the file like below:
ClientAliveInterval 30
ClientAliveCountMax 10
TCPKeepAlive yes
If you do modify it, you need to restart the service
or just reboot.
Client Side:
use PuTTY or pieTTY or Plink.
You can download Plink here:
http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
It so easy to use Plink:
Here is my example:
"plink.exe qsort@111.222.333.444 -p 22 -D 80 -L 2211:ptt.cc:21 -N"
"qsort": user name
"111.222.333.444": ip of SSH server
"-p 22": Use port 22
"-D 80": Create a Dynamic forwarding tunnel(SOCK5)
on your local port 80
"-L 2211:ptt.cc:21" Create an static forwarding tunnel.
local port 2211 <=> ptt.cc:21
In that way, you can connect 127.0.0.1:2211 to
reach ptt. ^^
What's the tip to choice a tunnel method?
If your softwares support SOCK5:
please use Dynamic forwarding method.
ex:
Firefox, IE, MSN
If your softwares NOT support SOCK5:
please use static forwding method.
ex:
telnet(BBS), Remote Desktop, OutlookExpress.
ps.徵個人寫中文的GOOGLE DOC吧。
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 218.168.155.242
※ 編輯: qsort 來自: 218.168.155.242 (06/20 22:17)
※ 編輯: qsort 來自: 218.168.155.242 (06/20 22:20)
推
06/20 23:21, , 1F
06/20 23:21, 1F
推
06/21 01:19, , 2F
06/21 01:19, 2F
推
06/21 07:08, , 3F
06/21 07:08, 3F
→
06/21 10:08, , 4F
06/21 10:08, 4F
推
06/22 18:51, , 5F
06/22 18:51, 5F
※ 編輯: qsort 來自: 218.168.161.195 (06/24 01:06)
推
07/07 05:50, , 6F
07/07 05:50, 6F
EZsoft 近期熱門文章
PTT數位生活區 即時熱門文章