This section describes the PCP mechanism.
Figure 1 shows the PCP connection negotiation process.
A PCP negotiation can be carried out in either the peer or map mode. Different PCP requests are involved in different modes. After receiving a PCP request from the CPE, the FW generates a PCP mapping entry based on the specified PCP negotiation mode.
Peer mode
After receiving a request in a peer mode from the CPE, the FW parses the request, assigns the public IP address and port number from the NAT address pool to the user, and generates the following PCP mapping entry:
Type: PEER, Protocol: UDP, Zone: ---, Vpn: public 192.168.0.10:17192[1.1.1.3:9000] -> 2.2.2.10:1280 TTL: 1800, Left: 1800, Pool: 30, Section: 1 Mapping Nonce: 0x353137383539353136000000
The PCP mapping entry includes a source address, source port number, destination address, destination port number, and protocol, and is a 5-tuple entry. In the peer mode, private network users can access the Internet, but Internet users cannot proactively communicate with private network users. Therefore, the peer mode is not applicable to P2P services.
In the peer mode, the PCP client can send a new PCP request to keep the PCP mapping entry alive after its TTL expires.
Map mode
After receiving a request in map mode from the CPE, the FW parses the request, assigns the public IP address and port number from the NAT address pool to the access user, and generates the following PCP mapping entries:
Type: MAP IN, Protocol: TCP, Zone: ---, Vpn: public ANY -> 1.1.1.3:2048[192.168.0.10:5791] TTL: 120, Left: 120, Pool: 10000, Section: 0 Mapping Nonce: 0x000000000000000032142158, Filter(s): 0 Type: MAP OUT, Protocol: TCP, Zone: ---, Vpn: public 192.168.0.10:5791[1.1.1.3:2048] -> ANY TTL: 120, Left: 120, Pool: 10000, Section: 0 Mapping Nonce: 0x000000000000000032142158, Filter(s): 0
The MAP IN and MAP OUT entries include the source address, source port number, and protocol fields and are 3-tuple entries, similar to server-map entries generated by 3-tuple NAT. The Internet user can proactively communicate with the private network user based on the MAP IN entry. Therefore, the map mode is applicable to P2P service scenarios.
After a PCP mapping entry in map mode is generated, if you want to keep the entry alive after its TTL times out, the PCP client can send a PCP request to renew the TTL of the PCP mapping entry.
In addition, the CGN or FW supports the ANNOUNCE response mode, in which the restarted CGN or FW notifies the CPE of rapidly restoring PCP mappings.
PCP is applied in a NAT444 scenario for P2P service transmission among users. Figure 2 shows the application of PCP in P2P services.
The PC of the private network user must support the Universal Plug and Play (UPnP) protocol. You are advised to use UPnP-capable P2P software.
The process for applying PCP in P2P services is as follows: