20170331-ssh-w 运行在狗洞翻墙
2017-04-01 00:00
351 查看
lite版本使用方法
• 下载对应您系统的dtunnel客户端(win/linux/mac/arm),程序需要在狗洞两端运行,服务的一方叫远端,连接的一方叫近端• 远端:./dtunnel -service xxx:1234 -auth abcd -dnscache 10 . service:监听地址, -auth:验证密码,可以为空, -dnscache:dns缓存,分钟数(开启后加速效果显著)
• 近端:./dtunnel -service xxx:1234 -local :8888 -auth abcd -encrypt -action ip:port. -service:服务器地址,-local:本地服务地址,-encrypt:是否加密,-action:控制远端行为,socks5表示开启代理服务,ip:port代表端口映射,-auth:密码,可留空,和服务端一致
下载网站:http://dog-tunnel.tk/#sec6
下载包: dtunnel_linux_x86_1.30_lite.tgz
解压: tar xvf dtunnel_linux_x86_1.30_lite.tgz
给执行权限: chmod +x dtunnel_lite
server: vim /etc/ssh/sshd_config
125 PermitTunnel yes
service sshd restart
./dtunnel_lite -service localhost:1234 -dnscache 10 -auth 123456
client: ./dtunnel_lite -service 192.168.30.21:1234 -local :8888 -action localhost:22 -auth 123456 - encrypt
ssh -Nf -w 2:3 root@localhost -p 8888
ifconfig tun2 192.168.200.1 192.168.200.2 netmask 255.255.255.0
ifconfig tun2 up
server: ifconfig tun3 192.168.200.2 192.168.200.1 netmask 255.255.255.0
sysctl -a |grep ip_for 查看是否开启转发
如果没有开启:
vim /etc/sysctl.conf
7 net.ipv4.ip_forward = 1
生效:sysctl -p
最后配置防火墙和路由规则
相关文章推荐
- RHEL4- ssh服务(十二)ssh防范之DenyHosts的运行
- SSH下如何知道网站是以什么用户身份运行的
- 如何使用ssh来运行linux的GUI程序
- 如何在SSH断开后让远程服务器程序继续运行
- ssh 远程运行程序java -jar ,超时断开后程序也终止
- ssh的运行原理
- 在PHP中运行Linux命令并启动SSH服务的例子
- ssh后台运行 linux重定向及nohup不输出的方法
- centos 6 运行docker 后ssh 连不进容器问题
- 使用 SSH 远程连接运行图形界面程序(ubuntu)
- ssh 关闭后仍保持当前运行的进程
- Linux下SSH远程连接断开后让程序继续运行解决办法
- 查看linux的ssh服务信息及运行状态
- 如何实现SSH断开后 进程仍然在后台运行
- 整合SSH过程中遇到错误之运行项目action取不到自动装配的bean
- python ssh 运行带后面&的程序
- Linux关闭终端(或者关闭SSH等)后运行的程序自动停止
- 解决Linux关闭终端(关闭SSH等)后运行的程序自动停止
- Cygwin下运行ssh-host-config