Community discussions

MikroTik App
 
DrStalker
just joined
Topic Author
Posts: 12
Joined: Tue Feb 17, 2009 5:45 am

Troubleshooting an IPSEC VPN

Wed Jun 02, 2010 7:40 am

I'm trying to troubleshoot a Mikrotik RB493AH-> Mikrotik RB493AH VPN where one subnet is not being sent over the VPN tunnel. (there is one subnet behind the 125.X.X.X endpoint and three behind the 203.Y.Y.Y endpoint)

I'm pretty sure the root cause is in the mangle/nat rules, but I'm having trouble getting the information needed to confirm this and isolate where it is failing.


On a Cisco ASA device I can run a command to see what SAs are in place, watch the number of encapsulated/decapsulated packets change, etc:
[color=#0000FF]scon-edge# show crypto ipsec sa peer 203.X.X.X
peer address: 203.X.X.X
    Crypto map tag: outside_map0, seq num: 1, local addr: iinet_adsl

      access-list outside_cryptomap_1 extended permit ip 10.1.0.0 255.255.0.0 10.50.0.0 255.255.0.0
      local ident (addr/mask/prot/port): (10.1.0.0/255.255.0.0/0/0)
      remote ident (addr/mask/prot/port): (10.50.0.0/255.255.0.0/0/0)
      current_peer: syscon_endpoint

      #pkts encaps: 4592807, #pkts encrypt: 4596250, #pkts digest: 4596250
      #pkts decaps: 4276868, #pkts decrypt: 4276868, #pkts verify: 4276868
      [...][/color]
On a Mikrotik router the closest I can find is
[color=#0000FF]
[doug@PANDA] /ip ipsec remote-peers> /ip ipsec remote-peers print
 0 local-address=203.Y.Y.Y remote-address=125.X.X.X state=established side=responder established=2h25m12s


[doug@PANDA] /ip ipsec> /ip ipsec installed-sa print
Flags: A - AH, E - ESP, P - pfs
 0 E  spi=0xE2648F3 src-address=203.206.233.73 dst-address=125.X.X.X auth-algorithm=sha1 enc-algorithm=aes replay=4 state=mature
      auth-key="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" enc-key="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" addtime=jun/02/2010 04:55:36
      add-lifetime=24m/30m usetime=jun/02/2010 04:55:47 use-lifetime=0s/0s current-bytes=128903 lifebytes=0/0

 1 E  spi=0xF7919D2 src-address=125.254.47.74 dst-address=203.Y.Y.Y auth-algorithm=sha1 enc-algorithm=aes replay=4 state=mature
      auth-key="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" enc-key="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" addtime=jun/02/2010 04:55:36
      add-lifetime=24m/30m usetime=jun/02/2010 04:55:46 use-lifetime=0s/0s current-bytes=129817 lifebytes=0/0[/color]
Which tells me a connection exists between the endpoints, but gives no insight into what SAs have been established.

How can I get more information on what the RouterOS systems are doing with the IPSEC VPN?
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: Troubleshooting an IPSEC VPN

Wed Jun 02, 2010 4:29 pm

To configure the equivalent to NAT exemption on RouterOS simply add rules with an action of 'accept' for the traffic in your NAT configuration before the actual NAT takes place.

The available troubleshooting output on RouterOS for IPsec isn't as exhaustive as on an ASA.
 
DrStalker
just joined
Topic Author
Posts: 12
Joined: Tue Feb 17, 2009 5:45 am

Re: Troubleshooting an IPSEC VPN

Thu Jun 03, 2010 9:23 am

To configure the equivalent to NAT exemption on RouterOS simply add rules with an action of 'accept' for the traffic in your NAT configuration before the actual NAT takes place.
I have an address list called NAT_Bypass and just add a rule to the NAT that the destination must not be in that list; works nicely.
The available troubleshooting output on RouterOS for IPsec isn't as exhaustive as on an ASA.
Damn, I was hoping I'd missed something. I find RouterOS is so much better than Cisco gear in most ways, except for VPN work and monitoring what is going on.

Who is online

Users browsing this forum: Bing [Bot], normis and 173 guests