Community discussions

MikroTik App
 
KristVB
just joined
Topic Author
Posts: 4
Joined: Mon Jun 06, 2016 7:40 am

Open VPN client

Mon Jun 06, 2016 8:39 am

Hi all,

I try to get Open VPN client working on a Mikrotik Router. So far without success.

Connecting to the VPN using the openvpn on linux works.
I have the following information:
- Host Name and password.
- Host uses tcp, no LZO.
- I have the CA certificate used to sign the host certificate.

I uploaded the CA certificate, and created an ovpn-client interface. This is what it looks like:

[admin@MikroTik] /interface ovpn-client> print
Flags: X - disabled, R - running
0 name="ovpn-out1" mac-address=02:BE:C7:59:65:06 max-mtu=1500 connect-to=ovpn.example.com port=443 mode=ip user="me" password="1234"
profile=default certificate=newca.crt_0 auth=sha1 cipher=aes256 add-default-route=no

This however does not work: I keep getting "TLS Failed" errors.
What does this error indicate in this case?
 
tic85linux
just joined
Posts: 1
Joined: Tue Jun 07, 2016 11:31 pm

Re: Open VPN client

Wed Jun 08, 2016 12:07 am

Please I also need answer to this question !!!
 
dnadih
just joined
Posts: 2
Joined: Wed Jun 08, 2016 6:58 am

Re: Open VPN client

Wed Jun 08, 2016 7:04 am

OpenVPN server is running on linux host? Are you sure that you are not running ovpn service on udp port?
RouterOS ovpn works only on tcp protocol.
 
User avatar
emils
Forum Veteran
Forum Veteran
Posts: 906
Joined: Thu Dec 11, 2014 8:53 am

Re: Open VPN client

Wed Jun 08, 2016 1:10 pm

Upgrade to the latest Release Candidate version, it should solve the issue.
 
KristVB
just joined
Topic Author
Posts: 4
Joined: Mon Jun 06, 2016 7:40 am

Re: Open VPN client

Thu Aug 25, 2016 5:56 pm

I am now on 6.36.2

I am again trying to get ovpn working, and again unsuccessful.

[admin@officerouter] /interface ovpn-client> print
Flags: X - disabled, R - running
0 ;;; VPN
name="rhbrq" mac-address=02:3F:5A:E4:39:AC max-mtu=1360 connect-to=1.2.3.4 port=443
mode=ip user="me" password="123456" profile=default-encryption
certificate=newca.crt_0 auth=md5 cipher=aes256 add-default-route=no


All I get in the log now is:

16:54:45 ovpn,info rhbrq: initializing...
16:54:45 ovpn,info rhbrq: connecting...
16:55:05 ovpn,info rhbrq: terminating... - could not connect

No info as to what could be the reason why the connection fails...

I managed to get the opvn working from my laptop (with fedora), so the server works, and I have the correct credentials etc...
There is a NAT router (my internet egress router) between the mikrotik and the internet. But that should not be a problem.

So how do I proceed here? How do I find out more about what is keeping this from working?

(Edit turned out that I had a firewall problem as well. Fixed that now the error is:)
17:26:38 ovpn,info rhbrq: connecting...
17:26:38 ovpn,info rhbrq: terminating... - TLS failed
17:26:38 ovpn,info rhbrq: disconnected

... So same problem as before
 
User avatar
emils
Forum Veteran
Forum Veteran
Posts: 906
Joined: Thu Dec 11, 2014 8:53 am

Re: Open VPN client

Fri Aug 26, 2016 10:31 am

TLS failed usually points to an issue with certificates. Make sure the client has correct certificates.
 
KristVB
just joined
Topic Author
Posts: 4
Joined: Mon Jun 06, 2016 7:40 am

Re: Open VPN client

Fri Aug 26, 2016 10:34 am

I am pretty sure the certificate is correct. I am using the same certificate witrh openvpn on a fedora 24 laptop, and there it works.
 
pacman88
newbie
Posts: 31
Joined: Mon Aug 22, 2016 7:08 pm

Re: Open VPN client

Fri Aug 26, 2016 11:58 am

Hi

if i read your question correctly you are not using client certificates but added the ca used to sign your server cert as client cert. that probably is the issue. try to remove the client cert param from you client config.

there seems to be a serious problem with openvpn client on mikrotik - the client connects to the server without checking the server cert at all....

i was about to open a post for that already... maybe someone from mikrotik could give a statement about that?

best regards
alex

Who is online

Users browsing this forum: divB and 66 guests