Question on NAT

advertisement

Question on NAT

10.10.10.1

Port: 6678

Server WEB

Port: 80

190.10.45.3

10.10.10.2

Port: 6678

10.10.10.254

10.10.10.3

Port: 7348 a) b)

The private network in the figure is connected to the Internet througha traditional NAPT. The router has a single public address: (131.175.21.130).

Can three private host be simultaneoulsy connected to the same web server on the Internet?

If so, write down IP address and port addresses in the packets generated by the private hosts and directed to the web server (before and after the

NAPT router). Write down the NAT table of the router.

Question on NAT

10.10.10.1

Port: 6678

Server WEB

Port: 80

190.10.45.3

10.10.10.2

Port: 6678

10.10.10.254

10.10.10.3

Port: 7348 a) Can three private host be simultaneoulsy connected to the same web server on the Internet?

Yes, beacause NAPT can multiplex multile private IP addresses onto the same public IP address by translating also the ports.

Question on NAT

10.10.10.1

Port: 6678

Server WEB

Porta: 80

190.10.45.3

10.10.10.2

Port: 6678

10.10.10.254

10.10.10.3

Port: 7348

NAT Table

10.10.10.1, 6678 131.175.21.130, 6678

10.10.10.2, 6678 131.175.21.130, 7000

10.10.10.3, 7348 131.175.21.130, 7348

Question on NAT

IP src: 10.10.10.1

IP des: 190.10.45.3

Port src: 6678

Port des: 80

IP src: 131.175.21.130

IP des: 190.10.45.3

Port src: 6678

Port des: 80

Server WEB

Port: 80

10.10.10.1

Port: 6678

10.10.10.254

190.10.45.3

NAT Table

10.10.10.1, 6678 131.175.21.130, 6678

10.10.10.2, 6678 131.175.21.130, 7000

10.10.10.3, 7348 131.175.21.130, 7348

Question on NAT

IP src: 10.10.10.2

IP des: 190.10.45.3

Porta src: 6678

Port des: 80

IP src: 131.175.21.130

IP des: 190.10.45.3

Porta src: 7000

Port des: 80

Server WEB

Port: 80

10.10.10.2

Port: 6678

10.10.10.254

190.10.45.3

NAT Table

10.10.10.1, 6678 131.175.21.130, 6678

10.10.10.2, 6678 131.175.21.130, 7000

10.10.10.3, 7348 131.175.21.130, 7348

Question on NAT

IP src: 10.10.10.3

IP des: 190.10.45.3

Porta src: 7348

Porta des: 80

IP src: 131.175.21.130

IP des: 190.10.45.3

Porta src: 7348

Porta des: 80

Server WEB

Porta: 80

10.10.10.3

Port: 6678

10.10.10.254

190.10.45.3

NAT Table

10.10.10.1, 6678 131.175.21.130, 6678

10.10.10.2, 6678 131.175.21.130, 7000

10.10.10.3, 7348 131.175.21.130, 7348

Question on Tunneling a)

Intranet A and Intranet B are connected through a VPN.

The host 10.10.10.3 sends an IP packet to host 10.10.11.1.

Write the source and destination address of the IP packet travelling in the Internet.

136.66.71.254

R1

10.10.10.2

10.10.10.3

SubNet

10.10.10.0/24

Intranet A

Internet

SubNet

10.10.11.0/24

Intranet B

133.32.15.254

R2

10.10.11.2

10.10.11.1

Question on Tunneling

IP_src:136.66.71.254

IP_src:10.10.10.3

IP_des: 10.10.11.1

Payload

IP_des: 133.32.15.254

IP_src:10.10.10.3

IP_des: 10.10.11.1

Payload

136.66.71.254

R1

10.10.10.2

10.10.10.3

SubNet

10.10.10.0/24

Intranet A

Internet

IP_src:10.10.10.3

IP_des: 10.10.11.1

Payload

SubNet

10.10.11.0/24

Intranet B

133.32.15.254

R2

10.10.11.2

10.10.11.1

Question HTTP a)

An HTTP client sends the following message:

Client :

GET http://www.polimi.it/index.html HTTP/1.0

User-agent: Mozilla/4.0

Accept: text/html, image/gif, image/jpeg

If-modified-since: 27 Jun 2001 08:10:00

Write down two feasible responses of the

HTTP server (only status line b) Assuming that the message is sent through a

Proxy, specify the behavior of the Proxy itself

Question HTTP

Client :

GET http://www.polimi.it/index.html HTTP/1.0

User-agent: Mozilla/4.0

Accept: text/html, image/gif, image/jpeg

If-modified-since: 27 Jun 2001 08:10:00

Server Responses:

Server :

HTTP/1.1 200 OK

Server :

HTTP/1.1 304 Not Modified

Question HTTP

Client :

GET http://www.polimi.it/index.html HTTP/1.0

User-agent: Mozilla/4.0

Accept: text/html, image/gif, image/jpeg

If-modified-since: 27 Jun 2001 08:10:00

The Proxy crosscheck if the resource is available in the local cache.

If not:

Forwards the message to the server

If so, crosschecks the date associated to the resource:

If it’s older than the one specified in the message

If-modified-since, it it forwarsd the message to the server.

Otherwise??

Download