Thank you very much Odkrys
Your solution is working great
Do you think Merlin could include your script in the next firmware release?
IKEv2 settings in the vpn ipsec parameters should be possible.
I asked Merlin but no answer so far.
With my connection Ikev2 is four times faster than openvpn with less latency.
It is by far the best vpn for rt-ac86u and with Windows 10 Ikev2 native client it works great.
Does this still work?
I am getting the following error: Policy match error
when I try to connect to it.
Any solution? Thanks!
ipsec stroke loglevel cfg 2
eap_identity=%any
ike=aes128-sha1-modp1024,aes128-sha1-modp1536,aes128-sha1-modp2048,aes128-sha256-ecp256,aes128-sha256-modp1024,aes128-sha256-modp1536,aes128-sha256-modp2048,aes256-aes128-sha256-sha1-modp2048-modp4096-modp1024,aes256-sha1-modp1024,aes256-sha256-modp1024,aes256-sha256-modp1536,aes256-sha256-modp2048,aes256-sha256-modp4096!
esp=aes128-aes256-sha1-sha256-modp2048-modp4096-modp1024,aes128-sha1,aes128-sha1-modp1024,aes128-sha1-modp1536,aes128-sha1-modp2048,aes128-sha256,aes128-sha256-ecp256,aes128-sha256-modp1024,aes128-sha256-modp1536,aes128-sha256-modp2048!
EOF
Does this still work?
I am getting the following error: Policy match error
when I try to connect to it.
Any solution? Thanks!
will show what proposal received from client.Code:ipsec stroke loglevel cfg 2
Add ike and esp cipher options like this.
Code:eap_identity=%any ike=aes128-sha1-modp1024,aes128-sha1-modp1536,aes128-sha1-modp2048,aes128-sha256-ecp256,aes128-sha256-modp1024,aes128-sha256-modp1536,aes128-sha256-modp2048,aes256-aes128-sha256-sha1-modp2048-modp4096-modp1024,aes256-sha1-modp1024,aes256-sha256-modp1024,aes256-sha256-modp1536,aes256-sha256-modp2048,aes256-sha256-modp4096! esp=aes128-aes256-sha1-sha256-modp2048-modp4096-modp1024,aes128-sha1,aes128-sha1-modp1024,aes128-sha1-modp1536,aes128-sha1-modp2048,aes128-sha256,aes128-sha256-ecp256,aes128-sha256-modp1024,aes128-sha256-modp1536,aes128-sha256-modp2048! EOF
Nov 15 10:13:38 15[CFG] proposing traffic selectors for us:
Nov 15 10:13:38 15[CFG] 0.0.0.0/0
Nov 15 10:13:38 15[CFG] proposing traffic selectors for other:
Nov 15 10:13:38 15[CFG] dynamic
Nov 15 10:13:42 13[CFG] proposing traffic selectors for us:
Nov 15 10:13:42 13[CFG] 0.0.0.0/0
Nov 15 10:13:42 13[CFG] proposing traffic selectors for other:
Nov 15 10:13:42 13[CFG] dynamic
Nov 15 10:13:46 08[CFG] proposing traffic selectors for us:
Nov 15 10:13:46 08[CFG] 0.0.0.0/0
Nov 15 10:13:46 08[CFG] proposing traffic selectors for other:
Nov 15 10:13:46 08[CFG] dynamic
Nov 15 10:13:50 11[CFG] proposing traffic selectors for us:
Nov 15 10:13:50 11[CFG] 0.0.0.0/0
Nov 15 10:13:50 11[CFG] proposing traffic selectors for other:
Nov 15 10:13:50 11[CFG] dynamic
Nov 15 10:13:54 06[CFG] proposing traffic selectors for us:
Nov 15 10:13:54 06[CFG] 0.0.0.0/0
Nov 15 10:13:54 06[CFG] proposing traffic selectors for other:
Nov 15 10:13:54 06[CFG] dynamic
Nov 15 10:13:58 09[CFG] proposing traffic selectors for us:
Nov 15 10:13:58 09[CFG] 0.0.0.0/0
Nov 15 10:13:58 09[CFG] proposing traffic selectors for other:
Nov 15 10:13:58 09[CFG] dynamic
Nov 15 10:14:02 15[CFG] proposing traffic selectors for us:
Nov 15 10:14:02 15[CFG] 0.0.0.0/0
Nov 15 10:14:02 15[CFG] proposing traffic selectors for other:
Nov 15 10:14:02 15[CFG] dynamic
Nov 15 10:14:06 07[CFG] proposing traffic selectors for us:
Nov 15 10:14:06 07[CFG] 0.0.0.0/0
Nov 15 10:14:06 07[CFG] proposing traffic selectors for other:
Nov 15 10:14:06 07[CFG] dynamic
Nov 15 10:14:11 14[CFG] proposing traffic selectors for us:
Nov 15 10:14:11 14[CFG] 0.0.0.0/0
Nov 15 10:14:11 14[CFG] proposing traffic selectors for other:
Nov 15 10:14:11 14[CFG] dynamic
Nov 15 10:14:14 05[CFG] proposing traffic selectors for us:
Nov 15 10:14:14 05[CFG] 0.0.0.0/0
Nov 15 10:14:14 05[CFG] proposing traffic selectors for other:
Nov 15 10:14:14 05[CFG] dynamic
Nov 15 10:14:18 06[CFG] proposing traffic selectors for us:
Nov 15 10:14:18 06[CFG] 0.0.0.0/0
Nov 15 10:14:18 06[CFG] proposing traffic selectors for other:
Nov 15 10:14:18 06[CFG] dynamic
Nov 15 10:14:23 10[CFG] proposing traffic selectors for us:
Nov 15 10:14:23 10[CFG] 0.0.0.0/0
Nov 15 10:14:23 10[CFG] proposing traffic selectors for other:
Nov 15 10:14:23 10[CFG] dynamic
Nov 15 10:14:26 15[CFG] proposing traffic selectors for us:
Nov 15 10:14:26 15[CFG] 0.0.0.0/0
Nov 15 10:14:26 15[CFG] proposing traffic selectors for other:
Nov 15 10:14:26 15[CFG] dynamic
Nov 15 10:14:30 13[CFG] proposing traffic selectors for us:
Nov 15 10:14:30 13[CFG] 0.0.0.0/0
Nov 15 10:14:30 13[CFG] proposing traffic selectors for other:
Nov 15 10:14:30 13[CFG] dynamic
Nov 15 10:14:34 08[CFG] proposing traffic selectors for us:
Nov 15 10:14:34 08[CFG] 0.0.0.0/0
Nov 15 10:14:34 08[CFG] proposing traffic selectors for other:
Nov 15 10:14:34 08[CFG] dynamic
Nov 15 10:14:38 05[CFG] proposing traffic selectors for us:
Nov 15 10:14:38 05[CFG] 0.0.0.0/0
Nov 15 10:14:38 05[CFG] proposing traffic selectors for other:
Nov 15 10:14:38 05[CFG] dynamic
Nov 15 10:14:42 12[CFG] proposing traffic selectors for us:
Nov 15 10:14:42 12[CFG] 0.0.0.0/0
Nov 15 10:14:42 12[CFG] proposing traffic selectors for other:
Nov 15 10:14:42 12[CFG] dynamic
Nov 15 10:14:46 09[CFG] proposing traffic selectors for us:
Nov 15 10:14:46 09[CFG] 0.0.0.0/0
Nov 15 10:14:46 09[CFG] proposing traffic selectors for other:
Nov 15 10:14:46 09[CFG] dynamic
Hello
Ipsec IKEv2 vpn works great on my RT-AC86U with 384.7 firmware.
Which firmware version do you have?
Try reconnection after executing the command.I am not sure where to enter those cipher options.
Thank you!Try reconnection after executing the command.
in ikev2 scripts
I made simple script to make ASUS IKEv1 XAUTH/PSK server to IKEv1 XAUTH/PSK + IKEv2 EAP server.
Both profiles can run parallel.
You should to get Let's encrypt certificate for you ddns.
Without letsencrypt, you need to generate self-signed certificate and install CA to trusted root CA of each devices. I don't like this progress.
IKEv2 server share the same username and password with IKEv1.
https://drive.google.com/open?id=1mXvR03eTpYJ7b18tt1-OVr_aWVbhHH7K
Code:chmod a+rx /jffs/scripts/ikev2 echo "" >> /jffs/scripts/services-start echo "sh /jffs/scripts/ikev2" >> /jffs/scripts/services-start
Turn IPSec on and run the script or reboot.
Code:sh /jffs/scripts/ikev2
FYI, windows ikev2 vpn gui is buggy, so I recommend to use powershell after that edit it in gui.
https://hide.me/en/vpnsetup/windows10/ikev2/
There is no IPSec support on ac68u.Hi Odkrys,
I recently installed the Merlin WRT 384.8.2 on my RT-AC68u and I'd like to setup Ipsec/l2tp VPN server on it. Seems you got it worked successfully and I'd ask a little bit help from you setup it on my router if you wouldn't mind.
I checked the scripts and as I understood script relies on Ipsec binaries on the router but when I search on my router ipsec xl2tp2 or xauth etc I couldn't find anything about these. Are those needs to be installed via optware or entware? can you please provide me some guidance of how to get the missing components installed on the router so I can apply the scripts you created?
Thank you!
I see. that's a bummer. Thank you for help. much appreciated.There is no IPSec support on ac68u.
#!/bin/sh
CONFIG=$1
source /usr/sbin/helper.sh
pc_append "" $CONFIG
pc_append "ca letsencrypt" $CONFIG
pc_append " cacert=/jffs/.le/$(nvram get ddns_hostname_x)/chain.pem" $CONFIG
pc_append " auto=add" $CONFIG
pc_append "" $CONFIG
pc_append "conn IKEv2-EAP" $CONFIG
pc_append " keyexchange=ikev2" $CONFIG
pc_append " left=$(nvram get wan0_ipaddr)" $CONFIG
pc_append " leftid=@$(nvram get ddns_hostname_x)" $CONFIG
pc_append " leftsubnet=0.0.0.0/0" $CONFIG
pc_append " leftfirewall=yes" $CONFIG
pc_append " lefthostaccess=yes" $CONFIG
pc_append " leftauth=pubkey" $CONFIG
pc_append " leftcert=/jffs/.le/$(nvram get ddns_hostname_x)/cert.pem" $CONFIG
pc_append " right=%any" $CONFIG
pc_append " rightdns=$(nvram get lan_ipaddr)" $CONFIG
pc_append " rightsourceip=10.10.11.0/24" $CONFIG
pc_append " rightauth=eap-mschapv2" $CONFIG
pc_append " eap_identity=%any" $CONFIG
pc_append " dpdtimeout=30s" $CONFIG
pc_append " dpdaction=clear" $CONFIG
pc_append " dpddelay=10s" $CONFIG
pc_append " auto=add" $CONFIG
#!/bin/sh
CONFIG=$1
source /usr/sbin/helper.sh
pc_append ": RSA /jffs/.le/$(nvram get ddns_hostname_x)/domain.key" /etc/ipsec.secrets
@Sh0cker54
Merlin firmware supports ipsec.postconf and strongswan.postconf since 384.9
So no need additional script to build IKEv2 server for windows 10 clients.
nano /jffs/scripts/ipsec.postconf
Code:#!/bin/sh CONFIG=$1 source /usr/sbin/helper.sh pc_append "" $CONFIG pc_append "ca letsencrypt" $CONFIG pc_append " cacert=/jffs/.le/$(nvram get ddns_hostname_x)/chain.pem" $CONFIG pc_append " auto=add" $CONFIG pc_append "" $CONFIG pc_append "conn IKEv2-EAP" $CONFIG pc_append " keyexchange=ikev2" $CONFIG pc_append " left=$(nvram get wan0_ipaddr)" $CONFIG pc_append " leftid=@$(nvram get ddns_hostname_x)" $CONFIG pc_append " leftsubnet=0.0.0.0/0" $CONFIG pc_append " leftfirewall=yes" $CONFIG pc_append " leftauth=pubkey" $CONFIG pc_append " leftcert=/jffs/.le/$(nvram get ddns_hostname_x)/cert.pem" $CONFIG pc_append " right=%any" $CONFIG pc_append " rightdns=$(nvram get lan_ipaddr)" $CONFIG pc_append " rightsourceip=10.10.11.0/24" $CONFIG pc_append " rightauth=eap-mschapv2" $CONFIG pc_append " eap_identity=%any" $CONFIG pc_append " dpdtimeout=30s" $CONFIG pc_append " dpdaction=clear" $CONFIG pc_append " dpddelay=10s" $CONFIG pc_append " auto=add" $CONFIG
nano /jffs/scripts/strongswan.postconf
Code:#!/bin/sh CONFIG=$CONFIG source /usr/sbin/helper.sh pc_append ": RSA /jffs/.le/$(nvram get ddns_hostname_x)/domain.key" /etc/ipsec.secrets
chmod +x /jffs/scripts/ipsec.postconf /jffs/scripts/strongswan.postconf
We don't need old script anymore.Thank you for this. Just to clarify, if we have already implemented the original instructions, we should undo those before putting these scripts into place?
No way to test iOS sorry.It was working until 384.10 version was released. My VPN clients are iOS devices (iPhones and iPads).
Welcome To SNBForums
SNBForums is a community for anyone who wants to learn about or discuss the latest in wireless routers, network storage and the ins and outs of building and maintaining a small network.
If you'd like to post a question, simply register and have at it!
While you're at it, please check out SmallNetBuilder for product reviews and our famous Router Charts, Ranker and plenty more!