但小弟不才還是遇到了困難
使用tun無法連線
tap卻是可以連線
Direct clients to redirect Internet traffic有勾選
---------log----------
Sun Apr 15 13:43:23 2012 OpenVPN 2.0.9 Win32-MinGW [SSL] [LZO] built on Oct 1 2006
Sun Apr 15 13:43:23 2012 IMPORTANT: OpenVPN's default port number is now 1194, based on an official port number assignment by IANA. OpenVPN 2.0-beta16 and earlier used 5000 as the default port.
Sun Apr 15 13:43:23 2012 WARNING: No server certificate verification method has been enabled. See http://openvpn.net/howto.html#mitm for more info.
Sun Apr 15 13:43:23 2012 LZO compression initialized
Sun Apr 15 13:43:23 2012 Control Channel MTU parms [ L:1544 D:140 EF:40 EB:0 ET:0 EL:0 ]
Sun Apr 15 13:43:23 2012 Data Channel MTU parms [ L:1544 D:1450 EF:44 EB:135 ET:0 EL:0 AF:3/1 ]
Sun Apr 15 13:43:23 2012 Local Options hash (VER=V4): '69109d17'
Sun Apr 15 13:43:23 2012 Expected Remote Options hash (VER=V4): 'c0103fa8'
Sun Apr 15 13:43:23 2012 Attempting to establish TCP connection with xxx.xxx.xxx.xxx:443
Sun Apr 15 13:43:23 2012 TCP connection established with xxx.xxx.xxx.xxx:443
Sun Apr 15 13:43:23 2012 TCPv4_CLIENT link local: [undef]
Sun Apr 15 13:43:23 2012 TCPv4_CLIENT link remote: xxx.xxx.xxx.xxx:443
Sun Apr 15 13:43:23 2012 TLS: Initial packet from xxx.xxx.xxx.xxx:443, sid=4ce6e031 94e95c7c
Sun Apr 15 13:43:23 2012 VERIFY OK: depth=1, /C=tw/ST=tw/L=SanFrancisco/O=OpenVPN/emailAddress=mail@host.domain
Sun Apr 15 13:43:23 2012 VERIFY OK: depth=0, /C=tw/ST=tw/O=OpenVPN/OU=ss/CN=home/emailAddress=mail@host.domain
Sun Apr 15 13:43:24 2012 Data Channel Encrypt: Cipher 'BF-CBC' initialized with 128 bit key
Sun Apr 15 13:43:24 2012 Data Channel Encrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
Sun Apr 15 13:43:24 2012 Data Channel Decrypt: Cipher 'BF-CBC' initialized with 128 bit key
Sun Apr 15 13:43:24 2012 Data Channel Decrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
Sun Apr 15 13:43:24 2012 Control Channel: TLSv1, cipher TLSv1/SSLv3 EDH-RSA-DES-CBC3-SHA, 1024 bit RSA
Sun Apr 15 13:43:24 2012 [home] Peer Connection Initiated with xxx.xxx.xxx.xxx:443
Sun Apr 15 13:43:25 2012 SENT CONTROL [home]: 'PUSH_REQUEST' (status=1)
Sun Apr 15 13:43:25 2012 PUSH: Received control message: 'PUSH_REPLY,route-gateway 192.168.1.100,redirect-gateway def1,route-gateway dhcp,ping 15,ping-restart 60'
Sun Apr 15 13:43:25 2012 OPTIONS IMPORT: timers and/or timeouts modified
Sun Apr 15 13:43:25 2012 OPTIONS IMPORT: route options modified
Sun Apr 15 13:43:28 2012 RESOLVE: Cannot resolve host address: dhcp: [NO_DATA] The requested name is valid but does not have an IP address.
Sun Apr 15 13:43:28 2012 OpenVPN ROUTE: failed to parse/resolve default gateway: dhcp
Sun Apr 15 13:43:28 2012 TAP-WIN32 device [區域連線 3] opened: \\.\Global\{0546478C-4CA3-4FFD-B210-BFACF5819883}.tap
Sun Apr 15 13:43:28 2012 TAP-Win32 Driver Version 8.4
Sun Apr 15 13:43:28 2012 TAP-Win32 MTU=1500
Sun Apr 15 13:43:28 2012 ERROR: --dev tun also requires --ifconfig
Sun Apr 15 13:43:28 2012 Exiting
---------log----------
-----client.ovpn--------
client
proto tcp
dev tun
remote xxx.xxx.xxx.xxx 443
resolv-retry infinite
nobind
persist-key
persist-tun
ca ca.crt
cert client4.crt
key client4.key
comp-lzo
verb 3
-----client.ovpn--------

b8950411 wrote:
使用tun無法連線
tap卻是可以連線
Direct clients to redirect Internet traffic有勾選
...(恕刪)
看了您的 client.ovpn 內容,應該是沒有錯.
1.請注意,VPN Server 和 VPN Client 兩者間的設定需相同.
2.以PC當 VPN Client 時,'redirect Internet traffic' 請不要勾選,
3.需要翻牆時,直接在 client.ovpn 檔尾加上一條 redirect-gateway 即可.
請教一下各位高手 小弟目前人再內地 因需要翻牆 所以買了 一台N16放台灣家中 照著各位的方法來設定
我使用了openVPN還有PPTP的方法 都可以成功連線到router 但是無法獲得 網際網路的存取 (LAN貌似可以因為透過內建的ping tool 可以ping的到)
可以請各位大大來幫忙解答一下嗎?
以下是我的 config
router firmware版本: Tomato Firmware v1.28.7497 MIPSR2-Toastman-RT K26 USB VPN
openvpn client version: 2.2.1
pptp
server setting:
LAN IP 沒有overlap

network and sharing center 裡面看到

default gateway 顯示為: 0.0.0.0

感覺起來是有只侷限在 LAN 而不能上 internet
================================================================================
OpenVPN
server:


port forwarding

client:
dev tun
resolv-retry infinite
nobind
proto udp
remote xxx.xxx.xxx.xxx 1194
persist-key
persist-tun
ca ca.crt
cert client.crt
key client.key
comp-lzo
dhcp-option DNS 8.8.8.8
route 0.0.0.0 0.0.0.0 10.0.0.1
route-gateway 192.168.1.1
redirect-gateway
openVPN連線後
default gateway 顯示空白

network and sharing center 裡面看到
unidentified network, no internet access

openvpn log裡面有看到 error:
Mon Apr 16 00:59:38 2012 C:\WINDOWS\system32\route.exe ADD 0.0.0.0 MASK 128.0.0.0 192.168.1.1
Mon Apr 16 00:59:38 2012 Warning: route gateway is not reachable on any active network adapters: 192.168.1.1
Mon Apr 16 00:59:38 2012 Route addition via IPAPI failed [adaptive]
Mon Apr 16 00:59:38 2012 Route addition fallback to route.exe
在Tomato中 看到的status 不管是OpenVPN或是PPTP的方法 均為有連線成功 但是卻都是沒有 internet access. 我懷疑是 防火牆的問題 可否請各位高人指點?
shimi wrote:
openvpn log裡面有看到 error:
方案1. 這個看看有沒有幫助:
http://techlog.geir.tv/2009/07/openvpn-warning-route-gateway-is-not.html
方案2.
route 0.0.0.0 0.0.0.0 10.0.0.1
route-gateway 192.168.1.1
這兩行拿掉試試.
內文搜尋

X