Welcome, Guest. Please login or register.
Did you miss your activation email?
Friday 19 April 2024, 11:30:38 am

Login with username, password and session length

Visit the Official Endian Reference Manual  HERE
14247 Posts in 4376 Topics by 6491 Members
Latest Member: roy
Search:     Advanced search
+  EFW Support
|-+  Support
| |-+  VPN Support
| | |-+  Connecting via OpenVPN (Tap) // Windows 8 // Routing problem
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Go Down Print
Author Topic: Connecting via OpenVPN (Tap) // Windows 8 // Routing problem  (Read 13338 times)
PeterRoth
Jr. Member
*
Offline Offline

Posts: 2


« on: Thursday 09 January 2014, 08:27:14 pm »

I had problems to reach the green network after connecting to the OpenVPN Server,
because the routings pushed by the server don't work.
So i had to find a workaround by letting the user execute a batch sctipt after the connection has been established.
Is there any posiblity to change the routing informations pushed by the OpenVPN Server?

What i've done:

Routing tabel prior to connecting:

Code:
C:\Windows\system32>route print -4
===========================================================================
Schnittstellenliste
 20...00 ff d0 54 45 eb ......TAP-Win32 Adapter V9
 12...d4 3d 7e 95 c1 de ......Controller der Familie Realtek PCIe GBE
 16...00 50 56 c0 00 01 ......VMware Virtual Ethernet Adapter for VMnet1
 18...00 50 56 c0 00 08 ......VMware Virtual Ethernet Adapter for VMnet8
 24...08 00 27 00 40 0b ......VirtualBox Host-Only Ethernet Adapter
  1...........................Software Loopback Interface 1
 14...00 00 00 00 00 00 00 e0 Teredo Tunneling Pseudo-Interface
 15...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #2
 17...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #3
 19...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #4
 21...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #5
===========================================================================

IPv4-Routentabelle
===========================================================================
Aktive Routen:
     Netzwerkziel    Netzwerkmaske          Gateway    Schnittstelle Metrik
          0.0.0.0          0.0.0.0  192.168.254.254  192.168.254.241    276
        127.0.0.0        255.0.0.0   Auf Verbindung         127.0.0.1    306
        127.0.0.1  255.255.255.255   Auf Verbindung         127.0.0.1    306
  127.255.255.255  255.255.255.255   Auf Verbindung         127.0.0.1    306
     192.168.56.0    255.255.255.0   Auf Verbindung    192.168.56.101    276
   192.168.56.101  255.255.255.255   Auf Verbindung    192.168.56.101    276
   192.168.56.255  255.255.255.255   Auf Verbindung    192.168.56.101    276
    192.168.117.0    255.255.255.0   Auf Verbindung     192.168.117.1    276
    192.168.117.1  255.255.255.255   Auf Verbindung     192.168.117.1    276
  192.168.117.255  255.255.255.255   Auf Verbindung     192.168.117.1    276
    192.168.137.0    255.255.255.0   Auf Verbindung     192.168.137.1    276
    192.168.137.1  255.255.255.255   Auf Verbindung     192.168.137.1    276
  192.168.137.255  255.255.255.255   Auf Verbindung     192.168.137.1    276
    192.168.254.0    255.255.255.0   Auf Verbindung   192.168.254.241    276
  192.168.254.241  255.255.255.255   Auf Verbindung   192.168.254.241    276
  192.168.254.255  255.255.255.255   Auf Verbindung   192.168.254.241    276
        224.0.0.0        240.0.0.0   Auf Verbindung         127.0.0.1    306
        224.0.0.0        240.0.0.0   Auf Verbindung     192.168.137.1    276
        224.0.0.0        240.0.0.0   Auf Verbindung     192.168.117.1    276
        224.0.0.0        240.0.0.0   Auf Verbindung   192.168.254.241    276
        224.0.0.0        240.0.0.0   Auf Verbindung    192.168.56.101    276
  255.255.255.255  255.255.255.255   Auf Verbindung         127.0.0.1    306
  255.255.255.255  255.255.255.255   Auf Verbindung     192.168.137.1    276
  255.255.255.255  255.255.255.255   Auf Verbindung     192.168.117.1    276
  255.255.255.255  255.255.255.255   Auf Verbindung   192.168.254.241    276
  255.255.255.255  255.255.255.255   Auf Verbindung    192.168.56.101    276
===========================================================================
Ständige Routen:
  Netzwerkadresse          Netzmaske  Gatewayadresse  Metrik
          0.0.0.0          0.0.0.0  192.168.254.254  Standard
===========================================================================

Connection Log:

Code:
Thu Jan 09 09:49:11 2014 OpenVPN 2.2.2 Win32-MSVC++ [SSL] [LZO2] [PKCS11] built on Dec 15 2011
Thu Jan 09 09:49:20 2014 WARNING: No server certificate verification method has been enabled.  See h*ttp://openvpn.net/howto.html#mitm for more info.
Thu Jan 09 09:49:20 2014 NOTE: OpenVPN 2.1 requires '--script-security 2' or higher to call user-defined scripts or executables
Thu Jan 09 09:49:20 2014 LZO compression initialized
Thu Jan 09 09:49:20 2014 Control Channel MTU parms [ L:1574 D:138 EF:38 EB:0 ET:0 EL:0 ]
Thu Jan 09 09:49:20 2014 Socket Buffers: R=[65536->65536] S=[65536->65536]
Thu Jan 09 09:49:20 2014 Data Channel MTU parms [ L:1574 D:1450 EF:42 EB:135 ET:32 EL:0 AF:3/1 ]
Thu Jan 09 09:49:20 2014 Local Options hash (VER=V4): 'd79ca330'
Thu Jan 09 09:49:20 2014 Expected Remote Options hash (VER=V4): 'f7df56b8'
Thu Jan 09 09:49:20 2014 UDPv4 link local: [undef]
Thu Jan 09 09:49:20 2014 UDPv4 link remote: 192.168.254.253:1194
Thu Jan 09 09:49:20 2014 TLS: Initial packet from 192.168.254.253:1194, sid=e0a9bd63 1544ae38
Thu Jan 09 09:49:20 2014 WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
Thu Jan 09 09:49:20 2014 VERIFY OK: depth=1, /C=IT/O=efw/CN=efw_CA
Thu Jan 09 09:49:20 2014 VERIFY OK: depth=0, /C=IT/O=efw/CN=127.0.0.1
Thu Jan 09 09:49:21 2014 Data Channel Encrypt: Cipher 'BF-CBC' initialized with 128 bit key
Thu Jan 09 09:49:21 2014 Data Channel Encrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
Thu Jan 09 09:49:21 2014 Data Channel Decrypt: Cipher 'BF-CBC' initialized with 128 bit key
Thu Jan 09 09:49:21 2014 Data Channel Decrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
Thu Jan 09 09:49:21 2014 Control Channel: TLSv1, cipher TLSv1/SSLv3 DHE-RSA-AES256-SHA, 1024 bit RSA
Thu Jan 09 09:49:21 2014 [127.0.0.1] Peer Connection Initiated with 192.168.254.253:1194
Thu Jan 09 09:49:23 2014 SENT CONTROL [127.0.0.1]: 'PUSH_REQUEST' (status=1)
Thu Jan 09 09:49:23 2014 PUSH: Received control message: 'PUSH_REPLY,route-gateway 192.168.100.253,route-gateway 192.168.100.253,ping 8,ping-restart 30,ifconfig 192.168.100.10 255.255.255.0'
Thu Jan 09 09:49:23 2014 OPTIONS IMPORT: timers and/or timeouts modified
Thu Jan 09 09:49:23 2014 OPTIONS IMPORT: --ifconfig/up options modified
Thu Jan 09 09:49:23 2014 OPTIONS IMPORT: route-related options modified
Thu Jan 09 09:49:23 2014 TAP-WIN32 device [tap] opened: \\.\Global\{D05445EB-8CF1-4811-B6DC-D59F3F7B83FA}.tap
Thu Jan 09 09:49:23 2014 TAP-Win32 Driver Version 9.9
Thu Jan 09 09:49:23 2014 TAP-Win32 MTU=1500
Thu Jan 09 09:49:23 2014 Notified TAP-Win32 driver to set a DHCP IP/netmask of 192.168.100.10/255.255.255.0 on interface {D05445EB-8CF1-4811-B6DC-D59F3F7B83FA} [DHCP-serv: 192.168.100.0, lease-time: 31536000]
Thu Jan 09 09:49:23 2014 Successful ARP Flush on interface [20] {D05445EB-8CF1-4811-B6DC-D59F3F7B83FA}
Thu Jan 09 09:49:31 2014 TEST ROUTES: 0/0 succeeded len=-1 ret=1 a=0 u/d=up
Thu Jan 09 09:49:31 2014 Initialization Sequence Completed

Routing table after connecting:

Code:
C:\Windows\system32>route print -4 192.168.100.*
===========================================================================
Schnittstellenliste
 20...00 ff d0 54 45 eb ......TAP-Win32 Adapter V9
 12...d4 3d 7e 95 c1 de ......Controller der Familie Realtek PCIe GBE
 16...00 50 56 c0 00 01 ......VMware Virtual Ethernet Adapter for VMnet1
 18...00 50 56 c0 00 08 ......VMware Virtual Ethernet Adapter for VMnet8
 24...08 00 27 00 40 0b ......VirtualBox Host-Only Ethernet Adapter
  1...........................Software Loopback Interface 1
 14...00 00 00 00 00 00 00 e0 Teredo Tunneling Pseudo-Interface
 15...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #2
 17...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #3
 19...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #4
 21...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #5
 45...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #7
===========================================================================

IPv4-Routentabelle
===========================================================================
Aktive Routen:
     Netzwerkziel    Netzwerkmaske          Gateway    Schnittstelle Metrik
    192.168.100.0    255.255.255.0   Auf Verbindung    192.168.100.10    286
   192.168.100.10  255.255.255.255   Auf Verbindung    192.168.100.10    286
  192.168.100.253  255.255.255.255   Auf Verbindung    192.168.100.10     31
  192.168.100.255  255.255.255.255   Auf Verbindung    192.168.100.10    286
===========================================================================
Ständige Routen:
  Keine

Pinging

Code:
C:\Windows\system32>ping 192.168.100.10

Ping wird ausgeführt für 192.168.100.10 mit 32 Bytes Daten:
Antwort von 192.168.100.10: Bytes=32 Zeit<1ms TTL=128
Antwort von 192.168.100.10: Bytes=32 Zeit<1ms TTL=128
Antwort von 192.168.100.10: Bytes=32 Zeit<1ms TTL=128
Antwort von 192.168.100.10: Bytes=32 Zeit<1ms TTL=128

Ping-Statistik für 192.168.100.10:
    Pakete: Gesendet = 4, Empfangen = 4, Verloren = 0
    (0% Verlust),
Ca. Zeitangaben in Millisek.:
    Minimum = 0ms, Maximum = 0ms, Mittelwert = 0ms

C:\Windows\system32>ping 192.168.100.253

Ping wird ausgeführt für 192.168.100.253 mit 32 Bytes Daten:
Antwort von 192.168.100.253: Bytes=32 Zeit=1ms TTL=64
Antwort von 192.168.100.253: Bytes=32 Zeit<1ms TTL=64
Antwort von 192.168.100.253: Bytes=32 Zeit<1ms TTL=64
Antwort von 192.168.100.253: Bytes=32 Zeit<1ms TTL=64

Ping-Statistik für 192.168.100.253:
    Pakete: Gesendet = 4, Empfangen = 4, Verloren = 0
    (0% Verlust),
Ca. Zeitangaben in Millisek.:
    Minimum = 0ms, Maximum = 1ms, Mittelwert = 0ms

C:\Windows\system32>ping 192.168.100.210

Ping wird ausgeführt für 192.168.100.210 mit 32 Bytes Daten:
Antwort von 192.168.100.10: Zielhost nicht erreichbar.
Zeitüberschreitung der Anforderung.
Zeitüberschreitung der Anforderung.
Zeitüberschreitung der Anforderung.

Ping-Statistik für 192.168.100.210:
    Pakete: Gesendet = 4, Empfangen = 1, Verloren = 3
    (75% Verlust),

So it seems the system is doing a false routing.

When i do the following it works:

Code:
C:\Windows\system32>route delete 192.168.100.0
 OK!

C:\Windows\system32>route delete 192.168.100.10
 OK!

C:\Windows\system32>route delete 192.168.100.253
 OK!
 
 C:\Windows\system32>route add 192.168.100.0 mask 255.255.255.0 192.168.100.253 if 20 metric 1
 OK!

C:\Windows\system32>route add 192.168.100.253 mask 255.255.255.255 192.168.100.10
 OK!

New routing table:
Code:
C:\Windows\system32>route print -4 192.168.100.*
===========================================================================
Schnittstellenliste
 20...00 ff d0 54 45 eb ......TAP-Win32 Adapter V9
 12...d4 3d 7e 95 c1 de ......Controller der Familie Realtek PCIe GBE
 16...00 50 56 c0 00 01 ......VMware Virtual Ethernet Adapter for VMnet1
 18...00 50 56 c0 00 08 ......VMware Virtual Ethernet Adapter for VMnet8
 24...08 00 27 00 40 0b ......VirtualBox Host-Only Ethernet Adapter
  1...........................Software Loopback Interface 1
 14...00 00 00 00 00 00 00 e0 Teredo Tunneling Pseudo-Interface
 15...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #2
 17...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #3
 19...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #4
 21...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #5
 45...00 00 00 00 00 00 00 e0 Microsoft-ISATAP-Adapter #7
===========================================================================

IPv4-Routentabelle
===========================================================================
Aktive Routen:
     Netzwerkziel    Netzwerkmaske          Gateway    Schnittstelle Metrik
    192.168.100.0    255.255.255.0  192.168.100.253   192.168.100.10     31
  192.168.100.253  255.255.255.255   Auf Verbindung    192.168.100.10     31
===========================================================================
Ständige Routen:
  Keine

Pinging:

Code:
C:\Windows\system32>ping 192.168.100.253

Ping wird ausgeführt für 192.168.100.253 mit 32 Bytes Daten:
Antwort von 192.168.100.253: Bytes=32 Zeit=1ms TTL=64
Antwort von 192.168.100.253: Bytes=32 Zeit<1ms TTL=64
Antwort von 192.168.100.253: Bytes=32 Zeit<1ms TTL=64
Antwort von 192.168.100.253: Bytes=32 Zeit<1ms TTL=64

Ping-Statistik für 192.168.100.253:
    Pakete: Gesendet = 4, Empfangen = 4, Verloren = 0
    (0% Verlust),
Ca. Zeitangaben in Millisek.:
    Minimum = 0ms, Maximum = 1ms, Mittelwert = 0ms

C:\Windows\system32>ping 192.168.100.210

Ping wird ausgeführt für 192.168.100.210 mit 32 Bytes Daten:
Antwort von 192.168.100.210: Bytes=32 Zeit<1ms TTL=128
Antwort von 192.168.100.210: Bytes=32 Zeit<1ms TTL=128
Antwort von 192.168.100.210: Bytes=32 Zeit<1ms TTL=128
Antwort von 192.168.100.210: Bytes=32 Zeit<1ms TTL=128

Ping-Statistik für 192.168.100.210:
    Pakete: Gesendet = 4, Empfangen = 4, Verloren = 0
    (0% Verlust),
Ca. Zeitangaben in Millisek.:
    Minimum = 0ms, Maximum = 0ms, Mittelwert = 0ms

So i created a batch script to run after the connection is estblished.

So my question:

Is there any posiblity to change the routing informations pushed by the OpenVPN Server?


Setup:

WS1 (Machine trying to connect (Roadwarrior)) OS: Windows 8


Code:
Windows-IP-Konfiguration

   Hostname  . . . . . . . . . . . . : WS001
   Primäres DNS-Suffix . . . . . . . :
   Knotentyp . . . . . . . . . . . . : Hybrid
   IP-Routing aktiviert  . . . . . . : Nein
   WINS-Proxy aktiviert  . . . . . . : Nein

Ethernet-Adapter tap:

   Medienstatus. . . . . . . . . . . : Medium getrennt
   Verbindungsspezifisches DNS-Suffix:
   Beschreibung. . . . . . . . . . . : TAP-Win32 Adapter V9
   Physische Adresse . . . . . . . . : 00-FF-D0-54-45-EB
   DHCP aktiviert. . . . . . . . . . : Ja
   Autokonfiguration aktiviert . . . : Ja

Ethernet-Adapter Ethernet:

   Verbindungsspezifisches DNS-Suffix:
   Beschreibung. . . . . . . . . . . : Controller der Familie Realtek PCIe GBE
   Physische Adresse . . . . . . . . : D4-3D-7E-95-C1-DE
   DHCP aktiviert. . . . . . . . . . : Nein
   Autokonfiguration aktiviert . . . : Ja
   Verbindungslokale IPv6-Adresse  . : fe80::607b:e133:cf81:ce1f%12(Bevorzugt)
   IPv4-Adresse  . . . . . . . . . . : 192.168.254.241(Bevorzugt)
   Subnetzmaske  . . . . . . . . . . : 255.255.255.0
   Standardgateway . . . . . . . . . : 192.168.254.254
   DHCPv6-IAID . . . . . . . . . . . : 265567614
   DHCPv6-Client-DUID. . . . . . . . : 00-01-00-01-19-9D-BA-EA-D4-3D-7E-95-C1-DE

   DNS-Server  . . . . . . . . . . . : 192.168.254.254
                                       62.26.26.62
   NetBIOS über TCP/IP . . . . . . . : Aktiviert


EFW:

Red Interface192.168.254.253
Green Interface192.168.100.253


WS2 (Machine to reach (Windows XP)

IP: 192.168.100.210

Code:

Windows-IP-Konfiguration

        Hostname. . . . . . . . . . . . . : vws001
        Primäres DNS-Suffix . . . . . . . :
        Knotentyp . . . . . . . . . . . . : Unbekannt
        IP-Routing aktiviert. . . . . . . : Nein
        WINS-Proxy aktiviert. . . . . . . : Nein
        DNS-Suffixsuchliste . . . . . . . : localdomain

Ethernetadapter LAN-Verbindung:

        Verbindungsspezifisches DNS-Suffix: localdomain
        Beschreibung. . . . . . . . . . . : Ethernetadapter der AMD-PCNET-Famili
e
        Physikalische Adresse . . . . . . : 08-00-27-5C-AB-64
        DHCP aktiviert. . . . . . . . . . : Ja
        Autokonfiguration aktiviert . . . : Ja
        IP-Adresse. . . . . . . . . . . . : 192.168.100.210
        Subnetzmaske. . . . . . . . . . . : 255.255.255.0
        Standardgateway . . . . . . . . . : 192.168.100.253
        DHCP-Server . . . . . . . . . . . : 192.168.100.253
        DNS-Server. . . . . . . . . . . . : 192.168.100.254
                                            62.26.26.62
        Lease erhalten. . . . . . . . . . : Donnerstag, 9. Januar 2014 08:24:08
        Lease läuft ab. . . . . . . . . . : Donnerstag, 9. Januar



I disabled the firewall on both machines

Settings on EFW:

OpenVPN server:

Server configuration:

OpenVPN Server enabled(checked)
Bridged(checked)
Bridged to GREEN
Dyn ip pool start adress:192.168.100.150
Dyn ip pool end adress:192.186.100.160

Accounts

Usernametest
Passwordtestpass
Verify passwordtestpass
Direct all traffic through the VPN Server(unchecked)
Push only global options to this client:(checked)
Network behind client:(empty)
Push only these networks:(empty)
Static ip address:192.168.100.10
Push these nameservers:(unchecked)
Push domain:(unchecked)

Advanced

Port:1194
Protocol:UDP
Block DHCP responses coming from tunnel:(unchecked)
Don't block Traffice between clients:(checked)
Allow multiple connections from one account:(unchecked)
Push these networks:(unchecked)
Push these nameservers:(unchecked)
Push domains:(unchecked)

Authentication type: PSK

Firewall:

Source NAT:

SourceALL (Open VPN User)
Destination Green
Service<ANY>
NAT to192.168.100.253

VPN Firewall (enabled):

SourceALL (Open VPN User)
Destination Green + OPENVPN
Service<ANY>
PolicyAllow

Logged
Lopot
Jr. Member
*
Offline Offline

Posts: 4


« Reply #1 on: Wednesday 05 March 2014, 04:14:42 am »

You should let the XP comp reply thru Endian GW (and alow conection)

Or Add NAT (but in that case you had to have separate network segment usable for NAT)

Source Network Address Translation-->Source NAT

1   192.168.100.10   (This is VPN network, or use your IP x.x.x.10

GREEN
Interface 1
<ANY>   192.168.100.X   (This Is Endian Local IP, didnt read what is your)

WPN Firewall can be turn OFF


So Two RULES

ADD GATEWAY TO MACHINE YOU WANT PING

OR

USE NET NAT --- The shown by AllOpenVpn User for mi didnt work either....
Logged
PeterRoth
Jr. Member
*
Offline Offline

Posts: 2


« Reply #2 on: Thursday 06 March 2014, 08:55:17 pm »

Thanks for your reply.

I allready set a SNAT Rule

Source NAT:

Source   ALL (Open VPN User)
Destination    Green
Service   <ANY>
NAT to   192.168.100.253

Should include yous.

And i don*t want to route alltraffic through the gateway, as this might slow down internet access for the local users.
Logged
Pages: [1] Go Up Print 
« previous next »
Jump to:  

Page created in 0.063 seconds with 18 queries.
Powered by SMF 1.1 RC2 | SMF © 2001-2005, Lewis Media Design by 7dana.com