DEV Community

VAS Experts
VAS Experts

Posted on

Wi-Fi Calling where there is no cellular signal: what the phone, ePDG and IMS do on the call path

Picture a farmhouse with working home broadband and no cellular signal. The phone shows no bars, yet a Wi-Fi call can still go through. What does the phone actually do on that path, and which parts of the operator's core have to be running?

Apple's iPhone guide tells users to turn to Wi-Fi Calling when there is a Wi-Fi connection in an area with little or no cellular coverage. Researchers note that many operators use VoWiFi to complement cellular coverage where no radio signal is available, for example in rural territories or shielded buildings. For an engineer, the useful question is what that path consists of, node by node.

Does Wi-Fi Calling need a cellular signal?

No cellular radio signal is needed, but the operator's core network is. Without a signal the phone loses radio access. The 3GPP AAA server still gets the authentication vectors from the HSS or HLR if it does not already have them. The PDN gateway still reaches the packet data network, which can be an operator's own network that provides IMS services. The phone reaches this core over Wi-Fi.

The 3GPP architecture defines how non-3GPP accesses, Wi-Fi among them, get IP connectivity to the Evolved Packet Core. When the terminal supports 3GPP access, the credentials used with EAP-AKA reside on the UICC (the SIM). After the challenge succeeds, the operator's 3GPP AAA server checks in the user's subscription that the user is authorized for non-3GPP access.

In a non-roaming case the home operator decides how a Wi-Fi network is used, as trusted or as untrusted. GSMA IR.51 is the profile for IMS voice, video and SMS over untrusted Wi-Fi. It covers WLAN access to the EPC via the untrusted S2b interface and does not cover trusted access over S2a.

Each step of the call path has an owner. The whole path for untrusted Wi-Fi without roaming (S2b) fits in one table.

Step Who acts What happens
1 Phone, Wi-Fi network The phone gets a local IP address from the Wi-Fi network
2 Phone, ePDG The phone selects an ePDG and starts an IPsec tunnel to it; the tunnel runs over SWu
3 Phone, ePDG, 3GPP AAA server The phone and the AAA server authenticate each other, and the ePDG relays their messages
4 ePDG, AAA server, PDN gateway The PDN gateway is selected using subscriber data the HSS gives to the AAA server, and the ePDG then reaches it over S2b
5 Phone, IMS The phone can ask for P-CSCF addresses in IKEv2, then registers in IMS
6 Phone, IMS SIP signalling and media can travel inside the IPsec tunnel

How does the phone find the ePDG?

Before it can pick an ePDG, the phone has to know which country it is in. The architecture leaves the method to the implementation, and if the phone cannot determine the country, it stops ePDG selection. The access signalling specification notes that with a 3GPP radio network in coverage the phone can compare the PLMN's MCC with its IMSI, and that out of 3GPP coverage it can use other techniques, including user-provided location.

A phone in its home country that has no home ePDG identifier configured builds the ePDG name from the home network’s PLMN ID (the MCC and MNC of its IMSI). The name follows the pattern from the 3GPP numbering specification:

epdg.epc.mnc<MNC>.mcc<MCC>.pub.3gppnetwork.org
Enter fullscreen mode Exit fullscreen mode

MNC and MCC are each coded with three digits, so a two-digit MNC gets a leading zero in the name.

The phone resolves this name with standard DNS and picks an ePDG address of the same IP version as its local address. GSMA IR.51 notes that the DNS queries go to the DNS server provided on the Wi-Fi internet connection.

Failures matter too. If the phone in its home country cannot select an ePDG in the home network, it stops ePDG selection. A phone can tell that a Wi-Fi network restricts access to the core if it gets no IKEv2 response to its IKE_SA_INIT request. Apple lists connecting to a different Wi-Fi network among the things to try when Wi-Fi Calling is not working.

How does the phone prove who it is over untrusted Wi-Fi?

Our blog post on TWAG and ePDG says untrusted access suits any network, including a subscriber's home router or Wi-Fi in a coffee shop, and that the operator has no control over such a network. In the standard, whether a Wi-Fi network is trusted is the operator's decision. The post adds that on untrusted Wi-Fi the phone protects the traffic itself: it builds an IPsec tunnel to the ePDG, and the ePDG hands the session to the core over S2b.

The tunnel starts with an IKE_SA_INIT request that sets up the IKEv2 security association. The following IKE_AUTH request carries the APN for a non-emergency session in the IDr payload. The phone is authenticated with EAP-AKA inside IKEv2. EAP-AKA' is required for trusted-access authentication, while tunnel setup with the ePDG allows only EAP-AKA.

Step by step, the exchange runs like this:

  1. The ePDG extracts the EAP messages the phone sends over IKEv2 and passes them to the 3GPP AAA server over SWm. SWm reuses the DER and DEA commands of the Diameter EAP application.
  2. The AAA server fetches the authentication vectors from the HSS or HLR if it does not already have them.
  3. The ePDG answers the phone's IKE_AUTH request with its identity and, if requested, a certificate. It also carries the AAA server's EAP-Request/AKA-Challenge. The certificate-based signature is how the ePDG authenticates itself to the phone.
  4. The phone checks the authentication parameters and answers in a new IKE_AUTH request with the EAP-Response/AKA-Challenge. The ePDG forwards it to the AAA server.
  5. After success the AAA server sends EAP-Success and the MSK to the ePDG, which relays EAP-Success to the phone. The phone derives its own copy of the MSK, and both sides use it to compute the AUTH parameters that authenticate the IKE_SA_INIT messages.

The phone can also change networks later. Its IKE_AUTH request may carry an indication that it supports MOBIKE. If such a phone changes its local IP address, it updates the IKE and IPsec security associations and sends an INFORMATIONAL request with UPDATE_SA_ADDRESSES to the ePDG. The architecture describes handover between two untrusted Wi-Fi accesses on the same ePDG the same way: the tunnel is modified, not torn down and re-created.

What does the ePDG do between the tunnel and the core?

The ePDG sits between the IPsec tunnel and the AAA and packet side. It terminates the IKEv2 signalling and relays it as AAA messages. Tunnel authentication and authorization data travel over SWm, the reference point to the 3GPP AAA server.

The choice of the gateway comes next. The ePDG checks that the APN the phone asked for is allowed by subscription, or uses the default APN, and then selects the PDN gateway. The selection uses subscriber information the HSS provides through the AAA server; for a new connection the ePDG typically resolves the gateway via DNS, while a gateway already assigned (for example, before a handover) comes from the AAA server. The selected gateway informs the AAA server of its identity, and the AAA server tells the HSS the gateway identity and the APN. S6b is the reference point between the gateway and the AAA server.

S2b then provides the user plane with related control and mobility support between the ePDG and the gateway. Uplink packets go from the phone into the IPsec tunnel to the ePDG, which tunnels them to the PDN gateway. Downlink works in the opposite direction.

The phone ends up with two kinds of IP address: one from the Wi-Fi network to reach the ePDG, and one or more for external PDNs via the PDN gateway. The second kind can come from the PDN gateway or from an external PDN, and the ePDG delivers it to the phone. The phone gets it in the CFG_REPLY payload of the IKE_AUTH response. When you read a trace, keep the two addresses apart: the first reaches the ePDG, the second goes towards the packet data network.

How does the phone reach IMS and register?

The PDN gateway reaches the packet data network over SGi, and that network can be an operator's own network that provides IMS services. GSMA IR.51 says SIP signalling uses the IMS well-known APN, and the phone sets up a separate IPsec tunnel for the PDN connection to that APN. For S2b over untrusted WLAN, the tunnel stays active for as long as the phone is connected to the IMS, from the initial registration at least until deregistration.

The P-CSCF comes next. To find it, the phone can ask for its addresses in the IKEv2 configuration payload. If addresses are returned, they come in the CFG_REPLY of the IKE_AUTH response. The attributes are P_CSCF_IP4_ADDRESS and P_CSCF_IP6_ADDRESS. The IMS signalling specification lists this as one discovery method next to DHCP (with DNS resolution of the returned name) and the IMS management object. GSMA IR.51 requires these attributes for untrusted access.

Registration follows. The phone may carry both SIP signalling and media inside the IPsec ESP security association. After a 401 response to its REGISTER request, the phone picks the topmost WWW-Authenticate header it supports, where the algorithm is AKAv2-SHA-256 or AKAv1-MD5 (IMS AKA). IMS AKA gives mutual authentication between the ISIM and the home network, and the HSS and the ISIM share a long-term key tied to the private user identity.

Why does the IMS side look familiar to anyone who has launched VoLTE? GSMA IR.51, the Wi-Fi profile, is based on the IMS voice and SMS profile IR.92 and points to IR.92 for call establishment and termination. IR.92 identifies the minimum mandatory set of 3GPP features a phone and the network must implement for interoperable IMS-based telephony over LTE radio access. The IMS architecture adds the access-specific concepts for IMS over untrusted WLAN access to the EPC.

What changes for emergency calls, roaming and handover?

Emergency calls come first. A phone may start an emergency session over WLAN access to the EPC only when 3GPP access for the emergency call is not possible or available, for example with no 3GPP coverage. Then it sets up an emergency PDN connection and performs an IMS emergency registration before the session request, and it includes any available location information. It also selects an ePDG that supports emergency services. Apple's guide says that enabling Wi-Fi Calling may ask the user to enter or confirm an address for emergency services.

For handover, the PDN gateway is the user plane anchor for mobility between 3GPP and non-3GPP access. GSMA IR.51 requires a phone that supports untrusted access to support handover from LTE to Wi-Fi and from Wi-Fi to LTE as described in the 3GPP architecture. GSMA IR.51 says the phone keeps using the P-CSCF it selected when the IMS connection moves between the two.

In a roaming case, the HSS and 3GPP AAA server in the home network make the final decision whether the Wi-Fi network is used as trusted or untrusted. A phone outside its home country that is not attached over 3GPP access performs a DNS query to learn whether the visited country mandates ePDG selection in that country.

What does our Stingray ePDG cover on this path?

Stingray ePDG lets an operator or MVNO launch Wi-Fi Calling (VoWiFi), voice and SMS over Wi-Fi. Our ePDG authenticates subscribers by SIM with EAP-AKA, consistent with 3GPP standards, and supports IPsec/IKEv2 with a dedicated tunnel per PDN session. Our ePDG works with the packet-switched core (EPC/5GC) and the IMS subsystem rather than with base stations. It is meant for areas with no 2G, 3G or LTE coverage at all, for example rural households, remote farms, new neighborhoods and large buildings with weak indoor signal. Our ePDG also supports handover between Wi-Fi and LTE, lets the operator choose whether subscribers connect to specific Wi-Fi hotspots or choose themselves, and supports emergency services.

What to check in a lab before launch

The starting set of checks was derived from the steps of the call path; it is a starting point, not a requirement of the standard.

  1. Name resolution. From a Wi-Fi network outside the operator, resolve the ePDG name built from the home MCC and MNC. Check that the answer has the same IP version as the phone's local address.
  2. Authentication, positive and negative. Run the IKEv2 tunnel setup with a test SIM and EAP-AKA. Then trigger a rejection and watch it. If the ePDG of the home network rejects the tunnel in IKE_AUTH with a cause such as USER_UNKNOWN or AUTHORIZATION_REJECTED, the phone closes the IKEv2 state. It does not retry an ePDG of the same PLMN until it is switched off or the USIM is removed.
  3. Core attach. Confirm that the gateway is selected as configured (DNS-based for initial attach, AAA-provided PGW identity on handover), and that the phone gets its address in the CFG_REPLY. Then check whether the P-CSCF addresses arrive in the same response.
  4. IMS registration. Watch the REGISTER, the 401 response and the IMS AKA step. Per GSMA IR.51, the IMS well-known APN gets its own tunnel; per TS 24.229, check that this tunnel stays up at least until deregistration.

Sources

Top comments (0)