Reference11r1:Concept ICE
Applies To
This information applies to
- all innovaphone devices from V11
Overview
ICE is a protocol for finding and selecting a working network path between two media endpoints. The basic idea is that each endpoint discovers all its addresses that could be used to receive media. Those candidates are sent to the other endpoint. Then all combinations of local and remote candidates are tested. The best working combination is used for the actual media stream. If there is no working combination, the call can be disconnected.
ICE is designed to solve the following problems:
- NAT traversal
- If an endpoint is behind NAT, ICE creates a NAT mapping using STUN. Even if both sides are behind NAT, ICE can successfully establish a connection.
- Avoid no media / one-way media
- Only network paths are chosen for media that work in both directions. So there is no risk of one-way media. If there is no appropriate path, the call can be disconnected automatically.
- IPv4 and IPv6
- ICE also selects the IP version that is supported by both endpoints. This is good news for migrating from IPv4 to IPv6 because there is no extra configuration change to be done if more and more endpoints support IPv6.
Protocol flow
Gathering
When a call is started the local endpoint needs to discover all the IP addresses and ports it can use for receiving media. This process is called gathering. It is done for all components of the call (RTP, RTCP, T.38). Endpoints that are behind NAT create NAT mappings using requests to a STUN server that are sent from the same port that will be used for the media stream.
innovaphone endpoints return the following candidates for each network interface, if given:
- HOST candidates (addresses of local network interfaces)
- IPv4
- IPv6 SiteLocal
- IPv6 Global
- SRVFLX candidates (NAT mappings)
- IPv4
Transmission of the candidates
The local candidates are sent to the other endpoint using the signalling protocol as part of the offer or answer. If an endpoint has got both the local and remote candidates it starts the connectivity checks.
Connectivity checks
Each endpoint pairs up the local and remote candidates with the same IP version. Then it starts checking all the candidate pairs by sending special STUN requests to the remote party. If it receives the corresponding STUN response it knows that the network path works.
Nomination
ICE defines roles for the two endpoints of a connection: controlling and controlled. The controlling endpoint nominates one of the working candidate pairs that should be used for media. This is done by another STUN request that contains a special attribute.
Media establishment
After nominating a working candidate pair the media stream is started. If no working path was discovered after a timeout the call is terminated.
Configuration
Activation
From v11 ICE is the default call establishment mechanism, so it does not have to be activated. However if needed it can be deactivated using an interop config option.
config add H323 /ice-disabled config add SIP /ice-disabled config add SIPS /ice-disabled config add TSIP /ice-disabled config add TSIPS /ice-disabled
STUN
The STUN server is used for gathering server reflexive candidates. The server configuration is a string in one of the following formats:
- a single DNS name and an optional port (e.g.
stun.example.com:1234
). - a comma separated list of one or two IP addresses and optional ports (e.g.
172.16.13.1:1234,172.16.13.2
).
The STUN server string can be configured at the following places:
- For many boxes using the DHCP Server (on page IP4/ETHx/DHCP-Server)
- For an individual box (on page IP4/General/STUN)
- For an individual registration (as part of the configuration of the registration)
If it is configured in more than one place, the more specific one is used. For example the configuration at the registration overwrites the DHCP config.
Tracing
Activation
Traces for debugging ICE can be activated at the signalling module. The trace flags are also available on the debug.xml page.
config add H323 /ice-trace on config add SIP /ice-trace on config add SIPS /ice-trace on config add TSIP /ice-trace on config add TSIPS /ice-trace on