Questions tagged [nat]

In computer networking, network address translation (NAT) is the process of modifying network address information in datagram (IP) packet headers while in transit across a traffic routing device for the purpose of remapping one IP address space into another.

Most often today, NAT is used in conjunction with network masquerading (or IP masquerading) which is a technique that hides an entire IP address space, usually consisting of private network IP addresses (RFC 1918), behind a single IP address in another, often public address space. This mechanism is implemented in a routing device that uses stateful translation tables to map the "hidden" addresses into a single IP address and readdresses the outgoing Internet Protocol (IP) packets on exit so that they appear to originate from the router. In the reverse communications path, responses are mapped back to the originating IP address using the rules ("state") stored in the translation tables. The translation table rules established in this fashion are flushed after a short period unless new traffic refreshes their state.

As described, the method enables communication through the router only when the conversation originates in the masqueraded network, since this establishes the translation tables. For example, a web browser in the masqueraded network can browse a website outside, but a web browser outside could not browse a web site in the masqueraded network. However, most NAT devices today allow the network administrator to configure translation table entries for permanent use. This feature is often referred to as "static NAT" or port forwarding and allows traffic originating in the "outside" network to reach designated hosts in the masqueraded network.

Because of the popularity of this technique (see below), the term NAT has become virtually synonymous with the method of IP masquerading.

Network address translation has serious drawbacks on the quality of Internet connectivity and requires careful attention to the details of its implementation. As a result, many methods have been devised to alleviate the issues encountered. See the article on NAT traversal.

2002 questions
5
votes
4 answers

Why is vsftpd (behind firewall) returning its internal ip address for the pasv address?

I'm using vsftpd on a Debian server behind another Debian firewall. The natting is correct and I can connect to the ftp server from the outside. However, when the client issues the PASV command, the ftp server returns its internal IP…
Lifz
  • 203
  • 1
  • 2
  • 8
5
votes
1 answer

Carrier Grade NAT concepts: IP bans

I'd like to deploy a Wireless WAN using IPV6 for at least the wireless bits given that 6 offers higher through-put. I'm exploring the concept of CGN and what strikes me immediately is the liability. Suppose you use a single IP address for 14…
Guitarax
  • 67
  • 2
5
votes
2 answers

pfSense + NAT and nginx - real IP not shown in logs

My current setup includes a pfSense firewall which port forwards public WAN traffic to a NAT internal IP. Example: 104.12.134.12:80 (WAN IP) port forwards all traffic to 192.168.1.104:80 This is working as expected, traffic is forwarded on…
steadweb
  • 161
  • 1
  • 7
5
votes
1 answer

pf (Mac OS X) rule to redirect all traffic to a specific ip/port

I'm trying to recreate this iptables setup (from https://github.com/darkk/redsocks) with pf: iptables -t nat -A REDSOCKS -p tcp -d 10.0.0.0/8 -j REDIRECT --to-ports 12345 iptables -t nat -A OUTPUT -p tcp -j REDSOCKS I want to redirect all…
bkolobara
  • 53
  • 1
  • 4
5
votes
1 answer

Forwarding a port on the loopback interface to a remote IP/port

I have two Docker containers that I'm trying to network together in a specific way. Container A is running a Redis server on port 6379. Container B is running an interactive shell and needs to access Redis. Using Docker's linking feature, a user…
Jimmy
  • 193
  • 2
  • 6
5
votes
1 answer

How to make connections answer from the same gateway they entered in RouterOS?

I have a MikroTik RouterOS 6.23 device, and my network is as follows: Router | |-- bridge1_LAN (wlan1 + ether1) (192.168.0.210) -- LAN (192.168.0.0/24) | Here is where computers are. Those include some servers and some users. | Users…
Yajo
  • 292
  • 2
  • 3
  • 8
5
votes
3 answers

Internet access from private VPC subnet?

My brain is a little bit fried trying to figure this out but I can't seem to get private subnets to connect to the internet to grab updates for example. Basically all I want is web access for these servers. I have tried solutions found in other…
jmreicha
  • 790
  • 1
  • 16
  • 29
5
votes
2 answers

Where to find symmetric NAT?

Currently i'm working on some NAT traversal code (that allows to computers each behind it's own NAT to communicate with each other). But, surprisingly, i can't find any symmetric NAT's! (it's the most hard case). Anyone knows where can i find one,…
grigoryvp
  • 3,655
  • 11
  • 39
  • 59
5
votes
3 answers

How many valid NAT mappings can a common NAT support?

How many NAT mapping rules (that is, mappings between internal, private IP:PORT, and externally mapped IP:PORT) can a common NAT box support? Is there a limit in such number (that is, how many rules can be 'active' at the same time) ?
Valerio Schiavoni
  • 173
  • 1
  • 1
  • 5
5
votes
1 answer

How do you NAT Hairpin in IOS 8.3+

As I asked here and duplicated here it appears NAT Hairpinning is the answer I'm looking for to allow internal servers to loopback through the ASA to access external IP's (without using DNS Doctoring). However, the instructions presented in those…
Novox
  • 474
  • 1
  • 9
  • 27
5
votes
2 answers

FTP - 500 I won't open a connection to xx.xx.xx.xx

I'm running a server on AWS and I'm connecting out to a partner's FTP site (not much idea what they are running). My server has an elastic IP. In the results below xx.xx.xx.xx is the internal IP (same as I get from IPConfig). yy.yy.yy.yy is the…
Cade Roux
  • 375
  • 2
  • 5
  • 18
5
votes
1 answer

Route traffic directly between nodes in a cluster

I apologize if this is a really dumb question. Objective Ensure that traffic that is meant to go between nodes in a cluster does not (inefficiently) go outside the cluster and then come back in, but goes directly between nodes. Background We are…
Chris Dutrow
  • 734
  • 8
  • 20
5
votes
0 answers

NAT64 configuration with tayga on Debian 6

I'm trying to implement NAT64 with tayga on my server and came to a point where I'm not sure how to proceed. My server is connected via one IPv4 address and one /64 IPv6 address block to the internet. It servers all kind of stuff. For reasons I'm…
5
votes
1 answer

Running multiple services on different servers with IPv6 and a FQDN

One of the things NAT has permitted us to do in the past decade is split physical services onto different servers whilst hiding behind a single interface. For example, I have example.com behind a NAT on 192.0.2.10. I port-forward :80 and :443 to my…
Mark Henderson
  • 68,823
  • 31
  • 180
  • 259
5
votes
3 answers

Virtualbox, slow upload speed using nat

Im running Virtualbox on a Ubuntu 12.04 server (host) and I'm running a Windows 7 as guest os. Im using the (virtual) Intel PRO/1000 MT network card. I get good network performance for download using both nat and bridged network settings but upload…
user1622094
  • 53
  • 1
  • 3