Axxess static IP on Mikrotik Router

blunt

Expert Member
Joined
May 1, 2006
Messages
4,162
Reaction score
814
Location
Cape Town
hi all,

wonder if anyone can help me set this up on my mikrotik router.

Axxess are clueless about the Mikrotik, so no help from support there.

It's an L2TP client connection using your dsl user+password with a shared secret of "h3lp" (published on their website, i'm not divulging any secrets here before people comment).

Now I can set up a L2TP client via WebFig on my Mikrotik but I have no idea where to put in the "shared secret".

Anyone know where I can do this / how to set it up?
 
I also phoned them today, The only way to add an Secret is to route l2tp over IPSec, and Axxess does not support it
 
The shared secret of "h3lp" doesn't make sense it's not standard in a l2tp only setup.
 
From my testing the mikrotiks (RB750GL with routeros 6.1) don't support setting up an l2tp tunnel without ipsec in this particular case. (it chokes with the chap auth)
There's a billion bipac router that works effortlessly, I'll get the model number later. 740GX I think it was.
 
Last edited:
This is what options I have on my pfSense box:

Screenshot%20from%202013-08-19%2022%3A09%3A35.png


No shared key without using some sort of encryption.
 
Hi,

I have no idee why axxess wants to do it this way?

Why can they not just assign our static ips over the pppoe connection when we connect?

I also use Mikrotiks everywhere.

That setup of theirs are not standard, think they need to relook it a bit.
 
Why can they not just assign our static ips over the pppoe connection when we connect
Telkom controls the PPPoE and they refuse to allow that. The ISPs have been begging them for this for years. So instead we end up with these awful hacks.
 
Well this is really crap. From what I see this is L2TP/IPSec not L2TP. How can it not work on a MikroTik router..
 
Hi Guys,

Just an update from our side. Our team is working hard at finding a solution for this. Will keep you updated.

hi all,

wonder if anyone can help me set this up on my mikrotik router.

Axxess are clueless about the Mikrotik, so no help from support there.

It's an L2TP client connection using your dsl user+password with a shared secret of "h3lp" (published on their website, i'm not divulging any secrets here before people comment).

Now I can set up a L2TP client via WebFig on my Mikrotik but I have no idea where to put in the "shared secret".

Anyone know where I can do this / how to set it up?
 
Hey,

I can help you with the LT2P with ipsec on Mikrotik, as I have set this up myself in my personal capacity, except to my own VPS not to Afrihost's servers, so some of it may differ but let let's go.

It took me 2 weeks to figure this out. Also, take note, I have done this on Router OS 6.1, although I am currently on 6.2, don't ask me to help with previous versions, though it may work.

You will need to set up 3 different things on your mikrotik RB75x router.
1.) The L2TP connection
2.) The IPSEC tunnel
3.) A scheduled script, that checks if your dynamic public ip on your PPPoE session has changed, and if so, updates the IPSEC tunnel endpoint ip.

Timeout: Busy making screenshots ect. rest incoming soon.

1.) The L2TP connection
This is the easy part. In my example, replace 37.139.20.42 with the ip address Axxess/Afrihost gave you.

Create the L2TP connection. In the first tab, give it a name:
1-l2tp-tab1.png


In the second tab, add in the ip address 37.139.20.42 and your VPN username/password which is the same as your pppoe username/password allegedly. In my case it is test/********
1-l2tp-tab2.png


2.) The IPSEC tunnel
Now we start with the difficult stuff, and you guys may have to make changes here. Keep in mind the Mikrotik RB75x doesn't have a very good CPU, so you will probably end up doing max 5-6Mbit/sec over this tunnel, at least in my experience.

In Winbox, in the menu IP -> Ipsec.

1st go to the Proposal TAB. There should already be a "default" proposal. Mine looks like this:
This is the best settings I could find to not abuse my RB cpu too much. Depending on what Axxess/Afrihost force on you, you may need aes-192/256 for encryption algorithm.
2-ipset-proposal.png


Next, go to the "peers" tab.
Important here is, you need the following:
- ip address 37.139.20.42 (again replace with the axxess/afrihost server)
- your shared secret
- main l2tp exchange mode
- send initial contact
- nat traversal (even though we dont need it)
- generate policy
- rest can be different, may need to be different
2-ipset-peer.png


Last part of ipsec tunnel making it work initially, is in the policy tab.
Create a new policy.
- src address is the current ip you have on your pppoe- connection (dynamic) mine is 196.210.201.36
- dst address is again 37.139.20.42 / whatever axxess/afrihost gave you
- dst port 1701 (l2tp port)
- protocol is udp
2-ipset-policy-tab1.png


2nd tab here:
- action encrypt
- level require
- ipsec protocol esp (you may need the other one, but esp is what works for me)
- again the public pppoe ip 196.x and the lns server ip 37.x
2-ipset-policy-tab2.png


At this point, your VPN should come up and work. But you still need this for when your dynamic ip changes:

3.) A scheduled script, that checks if your dynamic public ip on your PPPoE session has changed, and if so, updates the IPSEC tunnel endpoint ip.

You need to create a scheduler to update the dynamic ip (when it changes).
3-ipsec-schedulre.png


Here is my script, make sure to update your pppoe connection name away from pppoe-openweb-test otherwise it won't work.

Code:
# ------------------- header -------------------
# Script by Tomas Kirnak, version 1.0.1
# If you use this script, or edit and
# re-use it, please keep the header intact.
#
# For more information and details about
# this script please visit the wiki page at
# http://wiki.mikrotik.com/wiki/IPSec_Policy_Dynamic
# ------------------- header -------------------
{
:global oWANip

# Configure the WAN interface name here
:local WANip [/ip address get [find interface="pppoe-openwebtest"] address]

:set WANip [:pick "$WANip" 0 ([:len $WANip] - 3)]

if ($WANip != $oWANip) do={
  :log warning "WAN IP changed, fixing IPSec"

  # I assume you only have a single ipsec policy
  /ip ipsec policy disable 0
  /ip ipsec peer disable 0
  
  /ip ipsec policy set 0 tunnel=yes
  /ip ipsec policy set 0 src-address="$WANip/32"
  /ip ipsec policy set 0 sa-src-address=$WANip
  /ip ipsec policy set 0 tunnel=no
  
  /ip ipsec peer enable 0
  /ip ipsec policy enable 0

 
  :set oWANip $WANip
}
}
 
Last edited:
Hey,

I can help you with the LT2P with ipsec on Mikrotik, as I have set this up myself in my personal capacity, except to my own VPS not to Afrihost's servers, so some of it may differ but let let's go.

It took me 2 weeks to figure this out. Also, take note, I have done this on Router OS 6.1, although I am currently on 6.2, don't ask me to help with previous versions, though it may work.

You will need to set up 3 different things on your mikrotik RB75x router.
1.) The L2TP connection
2.) The IPSEC tunnel
3.) A scheduled script, that checks if your dynamic public ip on your PPPoE session has changed, and if so, updates the IPSEC tunnel endpoint ip.

Timeout: Busy making screenshots ect. rest incoming soon.

Great thanks will give it a go when you have posted the rest.
 
Ok post updated.

ps. how to make the static ips work, is up to you, I only get you to get your l2tp/ipsec to work for now. Unless ofcoarse someone donate me a static ip l2tp/ipsec vpn to figure that part out, but I am sure with this the Afrihost/Axxess guys will finally be able to figure it out.
 
Ok post updated.

ps. how to make the static ips work, is up to you, I only get you to get your l2tp/ipsec to work for now. Unless ofcoarse someone donate me a static ip l2tp/ipsec vpn to figure that part out, but I am sure with this the Afrihost/Axxess guys will finally be able to figure it out.

Awesome, unfortunately I am not at home during office hours so I can't test just yet.

@The Axxess Lady -- please send this off to your techies to test out..
 
Did this remotely with Winbox, doesnt seem to be working - though things like the algorithms/encryption axxess would need to confirm.
 
Ah that is too bad, but it should give you a framework to work from. It really depends on how their LNS's are configured.

For example my LNS on the VPS is a very simplistic one, that even allows Apple Iphones ect to connect to it:
Code:
root@ares:~# cat /etc/ipsec.conf
version 2.0
config setup
        nat_traversal=yes
        virtual_private=%v4:10.0.0.0/8,%v4:192.168.0.0/16,%v4:172.16.0.0/12
        oe=off
        protostack=netkey

conn L2TP-PSK-NAT
        rightsubnet=vhost:%priv
        also=L2TP-PSK-noNAT

conn L2TP-PSK-noNAT
        authby=secret
        pfs=no
        auto=add
        #keyingtries=3
        rekey=no
        ikelifetime=8h
        keylife=1h
        type=transport
        left=37.139.20.42
        leftprotoport=17/1701
        right=%any
        rightprotoport=17/%any

Super simplistic as you can see. Like you are guessing, the algorithms/encryption, tunnel type ect is all important. Also, in my example I force mshap2 auth on the l2tp tunnel, they might use something simpler like pap or chap, who knows. I haven't seen their FAQ/document/whatever on how to connect and I am not a axxess/afrhost customer other than the free 1gbyte test adsl account which I don't use.

Maybe you just need to look at your logs, does your ipsec tunnel fail, or the l2tp tunnel only. Either you don't get into phase1 or phase2 of the ipsec tunnel, or you do and the l2tp tunnel doesnt authenticate. Thats pretty much the last tips I can give you.
 
Sounds like ipsec is still the problem.

What about ipsec in the logs?

Also in ip->ipsec->remote peers, does the LNS ip ever show up there? If sow what is the status of it?

Logs will tell more though. Im just asking random questions in the dark here. Perhaps Axxess will need to take it further with testing, I really can't help more unfortunately.
 
Top
Sign up to the MyBroadband newsletter
X