<div class="content"><p>The <b>IP_NAT_SESSION_MAPPING</b> structure holds
information for a single NAT mapping and is part of <b>IP_NAT_ENUMERATE_SESSION_MAPPINGS</b> (section
<a href="36d57fdc-36e2-4da7-b6ab-5ba99481b2b6" data-linktype="relative-path">2.2.1.2.183)</a>. </p><dl>
<dd>
<div><pre> typedef struct _IP_NAT_SESSION_MAPPING {
   UCHAR Protocol;
   ULONG PrivateAddress;
   USHORT PrivatePort;
   ULONG PublicAddress;
   USHORT PublicPort;
   ULONG RemoteAddress;
   USHORT RemotePort;
   IP_NAT_DIRECTION Direction;
   ULONG IdleTime;
 } IP_NAT_SESSION_MAPPING,
  *PIP_NAT_SESSION_MAPPING;
</pre></div>
</dd></dl><p><b>Protocol: </b>This MUST be one of the following.</p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>NAT_PROTOCOL_ICMP</p>
  <p>0x01</p>
  </td>
  <td>
  <p>ICMP Protocol</p>
  </td>
 </tr><tr>
  <td>
  <p>NAT_PROTOCOL_IGMP</p>
  <p>0x02</p>
  </td>
  <td>
  <p>IGMP Protocol</p>
  </td>
 </tr><tr>
  <td>
  <p>NAT_PROTOCOL_TCP</p>
  <p>0x06</p>
  </td>
  <td>
  <p>TCP Protocol</p>
  </td>
 </tr><tr>
  <td>
  <p>NAT_PROTOCOL_UDP</p>
  <p>0x11</p>
  </td>
  <td>
  <p>UDP Protocol</p>
  </td>
 </tr><tr>
  <td>
  <p>NAT_PROTOCOL_IP6IN4</p>
  <p>0x29</p>
  </td>
  <td>
  <p>IPv6 in IPv4</p>
  </td>
 </tr><tr>
  <td>
  <p>NAT_PROTOCOL_PPTP</p>
  <p>0x2F</p>
  </td>
  <td>
  <p>PPTP Protocol</p>
  </td>
 </tr><tr>
  <td>
  <p>NAT_PROTOCOL_IPSEC_ESP</p>
  <p>0x32</p>
  </td>
  <td>
  <p>IPSec ESP</p>
  </td>
 </tr><tr>
  <td>
  <p>NAT_PROTOCOL_IPSEC_AH</p>
  <p>0x33</p>
  </td>
  <td>
  <p>IPSec AH</p>
  </td>
 </tr><tr>
  <td>
  <p>NAT_PROTOCOL_PGM</p>
  <p>0x71</p>
  </td>
  <td>
  <p>PGM</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>PrivateAddress: </b>The private address of the NAT
entry.</p><p><b>PrivatePort: </b>The private port of the NAT
entry.</p><p><b>PublicAddress: </b>The public address of the NAT
entry.</p><p><b>PublicPort: </b>The public port of the NAT entry</p><p><b>RemoteAddress: </b>The remote address of the NAT
entry.</p><p><b>RemotePort: </b>The remote port of the NAT entry.</p><p><b>Direction: </b>This MUST be IP_NAT_DIRECTION.</p><p><b>IdleTime: </b>The time, in seconds, since the last
packet matching this entry was sent or received.</p></div>