NAT Tutorial

From MikroTik Wiki
Revision as of 20:00, 23 June 2008 by Djneoplan (talk | contribs) (New page: ==MIKROTIK NAT== '''This is a short howto explaining how to set up a full-NAT on a Mikrotik RouterOS. ''' This setup lets you hide your private ip from the public network. This means th...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

MIKROTIK NAT

This is a short howto explaining how to set up a full-NAT on a Mikrotik RouterOS.

This setup lets you hide your private ip from the public network. This means that in your private network you can have whatever private ip you want which is translated to the public network ip given to you by your network provider. This tutorial can be used by clients who want to connect to a network without changing the ip addressing of his LAN.

Example

On the following example we have a wireless interface which connects to a wireless network and an ethernet interface for the local network.

Suppose you are 192.168.1.2/24 (Private) 
Your RouterBoard's Ethernet card is 192.168.1.1/24 (Private) 
Your RouterBoard's Wireless card is 10.140.1.30/26 (Public) 
The Access Point You connect to is 10.140.1.1/26 (Public) 

Nat with 1 pc.jpg


Firstly we set the ip addresses Mikrotik nat howto01.jpg Mikrotik nat howto02.jpg

Secondly we fix the static routes so that we can access the network Mikrotik nat howto03.jpg Mikrotik nat howto04.jpg

We start building the NAT as followed Mikrotik nat howto05.jpg Mikrotik nat howto06.jpg

DST-NAT Mikrotik nat howto07.jpg Mikrotik nat howto08.jpg

SRC-NAT Mikrotik nat howto09.jpg Mikrotik nat howto10.jpg

NAT Completed! Mikrotik nat howto11.jpg