IPSec Mobile VPN client cannot go to OPT1 network

  • Hi All

    Our IPSec Mobile VPN clients can access our LAN without problem but not OPT1 network. We added a Phase 2 entry for OPT1 just like what we did for LAN. See below. Is there anything we are missing? Do we need to add some firewall rule to allow IPSec mobile VPN to OPT1?

    Thank you very much anticipation.

    Mode: tunnel
    Local Subnet: LAN
    P2 Protocol: ESP
    P2 Transforms: AES(auto),3DES
    P2 Auth Methods: SHA1, SHA256

    Mode: tunnel
    Local Subnet: OPT1
    P2 Protocol: ESP
    P2 Transforms: AES(auto),3DES
    P2 Auth Methods: SHA1, SHA256

  • @cheemg
    Can be done so
    all traffic will go through the tunnel

    1. Phase 2- local network / 0 (instead of two phases 2 there will be only one)
    2. Rules for the IPSec interface
      pass from IPSEC mobile client lan to LAN network
      pass from IPSEC mobile client lan to OPT1 network

    All other traffic will be blocked


    To test your option
    In my example Lan Net, / 24 - OPT1 net

    1. CLI- ipsec statusall (When the client is connected)

    2. Check the routing table on the client

    3. Check the firewall rules

  • Thank you Konstanti for the very helpful reply.
    We already had the firewall rule to allow traffic from the IPSec mobile client LAN to OPT1 network in both the LAN and OPT1 rules. We never had to allow from IPSec mobile client LAN to LAN network but the client can access LAN anyway.
    We tried using in P2 instead of having two P2's but it is still not working.
    Checked route print on the client machine and there is no route for the OPT1 network! There is a route only for the LAN network (and that's why client can access LAN).
    Do you know what could have caused the no route to OPT1 network?

    Also, we setup the same IPSec mobile VPN to access our other office networks (connected using site-to-site IPSec) and the IPSec Mobile client can access to all our offices (route print shows routes to all the office LAN's). The only problem we have is the client cannot access OPT1.

    Thank you once again

    Active Routes:
    Network Destination Netmask Gateway Interface Metric         On-link    291
 On-link 291

    (Strange! why is it and not ? In PFSense Mobile, the setting is / 24 )         On-link     36         On-link    291

    IPSec firewall rule:

    OPT1 firewall rule:

    LAN firewall rule:

    Some of the ipsec statusall results: is the IPsec mobile VPN LAN. is the office LAN is the office OPT1 (DMZ), = other office LAN and DMZ, = other office LAN and DMZ

    con-mobile{472}: AES_CBC_256/HMAC_SHA1_96, 69499 bytes_i (470 pkts, 23s ago), 56880 bytes_o (312 pkts, 22s ago), rekeying in 18 minutes
    con-mobile{472}:|/0 ===|/0

    con-mobile{472}: INSTALLED, TUNNEL, reqid 41, ESP in UDP SPIs: c2e3abf0_i 9774a938_o
    con-mobile{472}: AES_CBC_256/HMAC_SHA1_96, 92046 bytes_i (630 pkts, 18s ago), 78864 bytes_o (436 pkts, 13s ago), rekeying in 10 minutes
    con-mobile{472}:|/0 ===|/0

    con4000{224}:  AES_CBC_256/HMAC_SHA2_256_128/MODP_2048, 0 bytes_i (0 pkts, 1s ago), 0 bytes_o, rekeying disabled
     con4000{224}:|/0|/0|/0 ===|/0|/0

    con4000{226}: AES_CBC_256/HMAC_SHA2_256_128/MODP_2048, 629723604 bytes_i (2369982 pkts, 1s ago), 4208056872 bytes_o (3650146 pkts, 1s ago), rekeying disabled
    con4000{226}:|/0|/0|/0 ===|/0|/0

    con5000{163}: AES_CBC_256/HMAC_SHA2_256_128, 320 bytes_i (2 pkts, 12s ago), 0 bytes_o, rekeying disabled
    con5000{163}:|/0|/0|/0 ===|/0|/0

    con2000{188}: AES_GCM_16_128, 2734076964 bytes_i (11199757 pkts, 0s ago), 24669898024 bytes_o (17879882 pkts, 0s ago), rekeying disabled
    con2000{188}:|/0|/0|/0 ===|/0|/0

    ipconfig on client
    Connection-specific DNS Suffix . :
    IPv4 Address. . . . . . . . . . . :
    Subnet Mask . . . . . . . . . . . :
    Default Gateway . . . . . . . . . :

  • @cheemg

    Found the problem. We forgot we had to manually add routes on the client to make IPSec Mobile VPN work (not really sure the reason*). So we have to add the route for the OPT1 network

    Add-VpnConnection -Name "fxpa_allvpn" -ServerAddress xxx.yyy.com -TunnelType "Ikev2"
    Set-VPNConnection -Name "fxpa_allvpn" -SplitTunneling $True -AuthenticationMethod "Eap" -EncryptionLevel "Required"
    Add-VpnConnectionRoute -ConnectionName "fxpa_allvpn" -DestinationPrefix "" -PassThru
    Add-VpnConnectionRoute -ConnectionName "fxpa_allvpn" -DestinationPrefix "" -PassThru
    Add-VpnConnectionRoute -ConnectionName "fxpa_allvpn" -DestinationPrefix "" -PassThru
    Add-VpnConnectionRoute -ConnectionName "fxpa_allvpn" -DestinationPrefix "" -PassThru

    *[https://wiki.strongswan.org/projects/strongswan/wiki/ForwardingAndSplitTunneling](link url)

    *The Windows 7 client will always allow access to the host's LAN. So to access, for instance, a local printer nothing special
    has to be done. Since the client always proposes as remote TS, the gateway is free to narrow it to a subset. But to
    make split-tunneling actually work on the client the Use default gateway on remote network option in the Advanced TCP/IP settings of
    the VPN connection has to be disabled. Also, because a classful route is installed the virtual IP address has to belong to the
    remote subnet, otherwise, the Disable class based route addition option has to be enabled and routes have to be installed

    Windows 10 has split tunneling enabled by default, but with the same limitations seen since Windows 7, i.e. the virtual IP has to be
    from the remote subnet, or routes have to be added manually, for instance, via Add-VpnConnectionRoute PowerShell command.
    To tunnel all traffic via VPN instead, split tunneling has to be disabled explicitly, either by enabling the Use default gateway on remote network
    setting described above or by using the following PowerShell command: Set-VpnConnection "<Connection Name>" -SplitTunneling 0*

  • LAYER 8 Netgate

    Yup. Windows 10 requires manual manipulation of the client routes in powershell.

    It's an extremely helpful feature. 🙄

Log in to reply