Community discussions

MikroTik App
 
_saik0
Member Candidate
Member Candidate
Topic Author
Posts: 129
Joined: Sun Aug 26, 2007 11:18 pm

Dynamic IPSEC Phase1/Phase2 proposal

Sat Dec 26, 2015 12:16 am

Is it possible to define default Phase1/Phase2 proposals for dynamic policies, e.g. ipsec enabled within GRE and L2TP config?
I want to use sha1/aes256cbc for my GRE tunnels but sha1/aes128 is the default.

For Phase2 apparently only the "Default" proposal can be altered to get the desired behavior, but i couldn't find a way for Phase1?
 
_saik0
Member Candidate
Member Candidate
Topic Author
Posts: 129
Joined: Sun Aug 26, 2007 11:18 pm

Re: Dynamic IPSEC Phase1/Phase2 proposal

Tue Dec 29, 2015 2:28 pm

bump
 
User avatar
mrz
MikroTik Support
MikroTik Support
Posts: 7052
Joined: Wed Feb 07, 2007 12:45 pm
Location: Latvia
Contact:

Re: Dynamic IPSEC Phase1/Phase2 proposal

Tue Dec 29, 2015 2:36 pm

Phase1 is ipsec peer configuration. You can add ipsec peer with specific parameters you need.
As for phase2 you can specify proposal in policy template, each time when template is matched configured proposal will be used.
 
_saik0
Member Candidate
Member Candidate
Topic Author
Posts: 129
Joined: Sun Aug 26, 2007 11:18 pm

Re: Dynamic IPSEC Phase1/Phase2 proposal

Sun Jan 31, 2016 4:55 am

Phase1 is exactly the issue here.
Namely GRE interface with ipsec secret enabled creates a dynamic ipsec peer.
That dynamic ipsec peer uses sha1-3des/aes128 for phase1 and that cannot be changed.
There should be an option inside GRE interface to define phase1/phase2 (group actually).
 
pe1chl
Forum Guru
Forum Guru
Posts: 10215
Joined: Mon Jun 08, 2015 12:09 pm

Re: Dynamic IPSEC Phase1/Phase2 proposal

Sun Jan 31, 2016 2:37 pm

When you want to do that, just remove the IPsec secret from the GRE / L2TP tunnel config and setup a transport
config in the IP -> IPsec confguration. Then you can configure it just like you want.
 
_saik0
Member Candidate
Member Candidate
Topic Author
Posts: 129
Joined: Sun Aug 26, 2007 11:18 pm

Re: Dynamic IPSEC Phase1/Phase2 proposal

Sun Jan 31, 2016 3:05 pm

That was never an issue.
Of course i could do it by hand but since both of my locations are on dynamic IP, i have to rely heavily on scripting in order to achieve the same thing.
When one of the addresses changes I need to edit GRE interface, ipsec peer and finally ipsec policy on both locations.

It's doable no problem, I rely on such setup since ROS 5.xx where l2tp/gre interface didn't have ipsec secret option directly.
Since there is already an automated way of configuring ipsec secret through gre/l2tp interface, adding an option to adjust phase1/2 for dynamic peer/policy would make my life so much easier.
 
pe1chl
Forum Guru
Forum Guru
Posts: 10215
Joined: Mon Jun 08, 2015 12:09 pm

Re: Dynamic IPSEC Phase1/Phase2 proposal

Sun Jan 31, 2016 3:42 pm

... but adding all those options to the "simple IPsec" config would make it just as complicated as the standard
IPsec config, and so the advantage would be lost.

For example, I require (and requested) a selection of AH instead of ESP, so that would be another item.

It is probably best to keep simple config simple and for your case you can write a small script to change the
IP address in all required places in one go.

Who is online

Users browsing this forum: Google [Bot], Stibila and 62 guests