×

METHOD BASED ON THE COMBINATION OF THE UPnP AND STUN FOR NAT TRAVERSAL

  • US 20110264739A1
  • Filed: 05/03/2009
  • Published: 10/27/2011
  • Est. Priority Date: 04/11/2008
  • Status: Active Grant
First Claim
Patent Images

1. A method based on the combination of UPnP and STUN for NAT traversal, is characterized of including the steps as follow:

  • (1) the peer joining into the P2P streaming media system broadcast-searches the message for UPnP device in the internal net by the SSDP protocol;

    void Search(char* name, const char* type), wherein, according to the requirement of UPnP standard, the parameter name is “

    WANIPConnection” and

    the parameter type is “

    service”

    meaning searching UPnP service;

    (2) if searching UPnP service succeeds, sending the Port-Adding message to the NAT gateway control URL by the SOAP protocol;

    void InvokeCommand(char* name, char* args), wherein the parameter name is control command “

    AddPortMapping”

    to UPnP device, and args is the several other parameters required by UPnP standard,so that after adding port mapping the inner peer can connect with the outer peer for data communication, and NAT traversal is realized; and

    (3) if searching fails, the peer initiates STUN model to perform NAT traversal for the second time;

    void GetMapAddr(int&

    extIP, int&

    extPort, NatType&

    natType), wherein the parameters extIP and extPort are the outer IP and Port obtained by STUN, and the parameter natType is the type of NAT determined during traversing.

View all claims
  • 2 Assignments
Timeline View
Assignment View
    ×
    ×