25.02.2013 Views

TCP/IP Tutorial and Technical Overview - IBM Redbooks

TCP/IP Tutorial and Technical Overview - IBM Redbooks

TCP/IP Tutorial and Technical Overview - IBM Redbooks

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

When the NAT service assigns <strong>IP</strong> addresses on a dem<strong>and</strong> basis, it needs to<br />

know when to return the external <strong>IP</strong> address to the pool of available <strong>IP</strong><br />

addresses. There is no connection setup or tear-down at the <strong>IP</strong> level, so there is<br />

nothing in the <strong>IP</strong> protocol itself that the NAT service can use to determine when<br />

an association between a internal <strong>IP</strong> address <strong>and</strong> a NAT external <strong>IP</strong> address is<br />

no longer needed. Because <strong>TCP</strong> is a connection-oriented protocol, it is possible<br />

to obtain the connection status information from <strong>TCP</strong> header (whether<br />

connection is ended or not), while UDP does not include such information.<br />

Therefore, configure a timeout value that instructs NAT how long to keep an<br />

association in an idle state before returning the external <strong>IP</strong> address to the free<br />

NAT pool. Generally, the default value for this parameter is 15 minutes.<br />

Network administrators also need to instruct NAT whether all the internal hosts<br />

are allowed to use NAT or not. This can be done by using corresponding<br />

configuration comm<strong>and</strong>s. If hosts in the external network need to initiate<br />

connections to hosts in the internal network, NAT needs to be configured in<br />

advance as to which external NAT address matches which internal <strong>IP</strong> address.<br />

Thus, a static mapping should be defined to allow connections from outside<br />

networks to a specific host in the internal network. Note that the external NAT<br />

addresses as statically mapped to internal <strong>IP</strong> addresses should not overlap with<br />

the addresses specified as belonging to the pool of external addresses that the<br />

NAT service can use on a dem<strong>and</strong> basis.<br />

The external name server can, for example, have an entry for a mail gateway<br />

that runs on a computer in the internal network. The external name server<br />

resolves the public host name of the internal mail gateway to the statically<br />

mapped <strong>IP</strong> address (the external address), <strong>and</strong> the remote mail server sends a<br />

connection request to this <strong>IP</strong> address. When that request comes to the NAT<br />

service on the external interface, the NAT service looks into its mapping rules to<br />

see if it has a static mapping between the specified external public <strong>IP</strong> address<br />

<strong>and</strong> a internal <strong>IP</strong> address. If so, it translates the <strong>IP</strong> address <strong>and</strong> forwards the <strong>IP</strong><br />

packet into the internal network to the mail gateway.<br />

Network Address Port Translation (NAPT)<br />

The difference between Basic NAT <strong>and</strong> NAPT is that Basic NAT is limited to only<br />

translating <strong>IP</strong> addresses, while NAPT is extended to include <strong>IP</strong> address <strong>and</strong><br />

transport identifier (such as <strong>TCP</strong>/UDP port or ICMP query ID).<br />

Chapter 3. Internetworking protocols 93

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!