(非OpenVPN問題):請問在何種路由下,443可以telnet直接聯外,但VPN Client走443或80卻都出不去?



贊助商連結


rEDRing
2010-10-09, 02:48 AM
1.< 簡述網路環境 >
這個Site上網應該是導到專用的ADSL對外
並不是透過統一管理的proxy上www
使用IE可以直接到網路銀行,用晶片卡轉帳
也可以用PCMAN走443上知名bbs
看起來80 8080 443 這些PORT都沒有關閉


2.< OpenVpn的Server與Clinet經過測試,確認沒問題 >
同樣這一台電腦,若是接上3.5G網卡來直接對外
無論是TUN或TAP模式,VPN Client就可以成功透過3.5G建立連線。


3.< 問題是在這NAT環境底下,想與外部的OpenVPN Server建立連線 >
OpenVPN Current Status總是停在Connecting(黃燈) ?
無論是使用TUN 或 TAP 模式 ; UDP 或 TCP
使用TLS 或 Static KEY認證 ;
走443 或80 port ;
都無法成功連線!


4.< TAP-Adapter 無法取得IP的異常? >
經觀察,連線無法成功的的狀態下
Clinet的TAP-Adapter無法自Server取得正確的IP
都會time out後取到無效的169.254.*.*
即使以Ifconfig指派IP給它,仍然無法成功建立連線
Default Gateway . . . . . . . . . : (空白無IP)

而成功連線的情況下,Client卻都能自動從Vpn Server取得IP,Default Gateway


5.< 想請問,該如何判斷這邊的NAT環境是否完全沒有機會建立VPN連線? >
為什麼可上443的BBS卻無法成功利用443建立VPN連線?
還是有其他的設定可以來繞?


6.< 感謝各位,附上LOG >


Server端



Oct 9 03:12:19 SK9 daemon.notice openvpn[19187]: UDPv4 link local (bound): [undef]:443
Oct 9 03:12:19 SK9 daemon.notice openvpn[19187]: UDPv4 link remote: [undef]
Oct 9 03:13:19 SK9 daemon.notice openvpn[19187]: Inactivity timeout (--ping-restart), restarting
Oct 9 03:13:19 SK9 daemon.notice openvpn[19187]: TCP/UDP: Closing socket
Oct 9 03:13:19 SK9 daemon.notice openvpn[19187]: Closing TUN/TAP interface
Oct 9 03:13:19 SK9 daemon.notice openvpn[19187]: SIGUSR1[soft,ping-restart] received, process restarting
Oct 9 03:13:19 SK9 daemon.notice openvpn[19187]: Restart pause, 2 second(s)
Oct 9 03:13:21 SK9 daemon.warn openvpn[19187]: NOTE: OpenVPN 2.1 requires '--script-security 2' or higher to call user-defined scripts or executables
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: Static Encrypt: Cipher 'BF-CBC' initialized with 128 bit key
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: Static Encrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: Static Decrypt: Cipher 'BF-CBC' initialized with 128 bit key
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: Static Decrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: LZO compression initialized
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: TUN/TAP device tap21 opened
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: TUN/TAP TX queue length set to 100
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: Data Channel MTU parms [ L:1577 D:1450 EF:45 EB:135 ET:32 EL:0 AF:3/1 ]
Oct 9 03:13:21 SK9 daemon.notice openvpn[19187]: Socket Buffers: R=[112640->131072] S=[112640->131072]


Client


Sat Oct 09 03:04:52 2010 OpenVPN 2.1.3 i686-pc-mingw32 [SSL] [LZO2] [PKCS11] built on Aug 20 2010
Sat Oct 09 03:04:52 2010 NOTE: OpenVPN 2.1 requires '--script-security 2' or higher to call user-defined scripts or executables
Sat Oct 09 03:04:52 2010 LZO compression initialized
Sat Oct 09 03:04:52 2010 TAP-WIN32 device [區域連線 3] opened: \\.\Global\{719B06C7-2818-4258-8A84-148F9CDA2876}.tap
Sat Oct 09 03:04:52 2010 Successful ARP Flush on interface [786436] {719B06C7-2818-4258-8A84-148F9CDA2876}
Sat Oct 09 03:04:52 2010 UDPv4 link local (bound): [undef]:443
Sat Oct 09 03:04:52 2010 UDPv4 link remote: 123.456.789.123:443

贊助商連結


FYI
2010-10-09, 05:50 PM
請於兩端安裝Wireshark 並比較成功與失敗兩者封包的差異, 以便研判是Client 或Server 送出的封包被阻擋或遺失
請降低MTU 再試

rEDRing
2010-10-10, 01:54 AM
請於兩端安裝Wireshark 並比較成功與失敗兩者封包的差異, 以便研判是Client 或Server 送出的封包被阻擋或遺失
請降低MTU 再試


感謝回覆,等測試後回來回報~
:lovely:

rEDRing
2010-10-14, 04:30 PM
目前使用softether 1.0可以走443

但似乎連線不是很穩,約1~2小時會斷,要等約5-6分鐘才能再連上?
softether 1.0內建Timer ? 還是傳輸量計數器 ? XD
不知道是否有其他比較穩定的版本?


家中PC原本連到北美170ms,測了幾天目前從外部連回家中到北美約19Xms
softether反應速度上還可以,大概延遲多30ms


而VPN的部分,因為目前Server是整合在Tomato裡的,
監控封包,晚點在PC上架個OPENVpn Server來測試