主权项 |
1. A device comprising:
an input port for receiving network packets that are being communicated via a computer network; a memory; a processor in communication with the input port and the memory, the processor being configured to:
receive, via the input port, an outbound signaling packet sent from an inside user agent (“UA”);
wherein the outbound signaling packet comprises a header and a payload;wherein the header includes an outbound source Internet Protocol address-port pair (“IP-port”) that identifies the inside UA;wherein the payload includes a call-identification (“ID”) and an inside IP-port that also identifies the inside UA but differs from the outbound source IP-port;store, in the memory, an inside-source entry comprising the call-ID, the inside IP-port, an inside contact IP-port, and the outbound source IP-port, the outbound source IP-port representing a pinhole;translate the outbound source IP-port in the header into an internal proxy IP-port;translate the inside IP-port in the payload into the inside contact IP-port;transmit, via the output port, the outbound signaling packet;receive, via the input port, an inbound signaling packet sent to the inside UA;
wherein the inbound signaling packet includes a header and a payload;wherein the header of the inbound signaling packet comprises an inbound destination IP-port;wherein the payload of the inbound signaling packet comprises a call-ID and an outside IP-port;store, in the memory, an outside-source entry comprising the call-ID of the inbound signaling packet, the outside IP-port, and an outside contact IP-port;translate the outside IP-port in the payload of the inbound signal into the outside contact IP-port;translate the inbound destination IP-port in the header of the inbound signal into the inside IP-port of the inside-source entry if the inbound destination IP-port matches the inside contact IP-port of the inside-source entry;overwrite the inbound destination IP-port with the pinhole if the pinhole was stored in the inside-source entry;transmit, via an output port, the inbound signaling packet;receive, via the input port, an outbound media packet sent from the inside UA, wherein the outbound media packet includes an outbound media source IP-port and an outbound media destination IP-port, and wherein the outbound media packet comprises a real-time transport protocol (“RTP”) data;overwrite the pinhole of the inside-source entry with the outbound media source IP-port if the outbound media destination IP-port matches the outside contact IP-port of the outside-source entry and if the call-ID of the outside-source entry matches the call-ID of the inside-source entry;translate the outbound media destination IP-port into the outside IP-port of the outside-source entry; andtransmit, via the output port, the outbound media packet; and the output port in communication with the processor for transmitting packets via the computer network.
|