PAT (Port Address Translation)

A packet contains a:

  1. Data Payload (Layer 2)
  2. L3 Header (Layer 3)
    • Contains source address and destination address
  3. L4 Header (Layer 4)
    • Contains source port and destination port

NAT (Network Address Translation) only modify L3 header whereas PAT (Port Address Translation) modifies both L3 and L4 headers.

Pasted image 20240721202959.png

For example in here whent he packet cross the router, we modify both L3 and L4 headers.