The Diameter base protocol provides basic transport for diameter messages. There are many applications defined by 3GPP for telecom communications. Applications are also called diameter interfaces. The s6a and S6d are two examples of diameter interfaces. The s6a interface is between MME and HSS in the LTE network and s6d is between SGSN and HSS. Both provide messages and procedures for phone attach. MME is the node in visiting the 4G network. Which connects to the UE via eNodeB. eNodeB has a wireless interface with UE and wired interface with the MME. When a UE tries to register to network for mobile internet, MME sends signaling to the HSS and PGW. Both are located at the home network of an MNO (Mobile Network Operator).
The application id for s6a and s6d interface is 16777251, allocated by IANA. The 3GPP application specification is given in 3GPP TS 29.272
The s6d interface is also specified in the same specification as for s6a specification. In 4G the SGSN also uses the diameter protocol while in 3G it uses GSM MAP protocol over SS7 or Sigtran.
Messages Over S6a/S6d interface:
The first thing to send application-specific messages, base transport is required. For message transfer, a diameter base protocol is used. Base protocol setups Diameter connection with remote proxy or Diameter Routing Agent (DRA). It may use TCP or SCTP as a transport protocol over the IP network. The choice is a mobile operator specific. The application is the same for both types of transport protocols.
When a phone attaches to the visiting network. Network procedures start between roaming and home network over diameter protocol. The following are the messages/procedures.
AIR/AIA: Authentication information retrieval, is the first message which MME initiates towards the HSS, for a UE (User equipment, phone device in 4G) to attach to the visiting network for high-speed data services. The procedure is the authentication for a 4G SIM card. AIR message has IMSI and other information. On successful authentication, HSS returns the answer message (AIA), with authentication vectors in case of success else HSS sends a diameter error in response.
In case of a success response, UE verifies the authentication information in response. If Authentication is successful on UE too. MME initiates the location update request (ULR) towards the HSS, else. UE keeps trying authentication after some intervals.
ULR/ULA: As mentioned above, it is the next message after successful authentication. ULR sends the identity and roaming information to the home network. The primary identity is IMSI. Location information is visiting MCC, MNC, and cell id. Upon receiving ULR, HSS checks for the subscription. If IMSI (mobile subscriber) subscription is found and the subscriber is allowed to use data in the visiting network. Then HSS sends ULA (update location answer) with subscription data, else an error is returned in ULA. Subscription data have a list of APNs.
Following are the error codes for failures:
|DIAMETER_ERROR_USER_UNKNOWN||IMSI is not configured.|
|DIAMETER_ERROR_UNKNOWN_EPS_SUBSCRIPTION||No APN is configured.|
|DIAMETER_ERROR_ROAMING_NOT_ALLOWED||UE is not allowed in the roaming network.|
|DIAMETER_ERROR_RAT_NOT_ALLOWED||The selected Radio technology is not allowed. Following is a list of RAT types. This is defined in this 3GPP Spec
In case of success, the ULR has error code DIAMETER_SUCCESS and the Subscription profile AVP.
After receiving a success response, MME initiates a tunnel create procedure over GTPv2-C signaling. This is called a create session request over the GTP protocol. MME set up the session with the PGW located in-home network via, SGW located in the visiting network.
Once the session created successfully, the user data flow from MME to PGW over the GTP session.
If session creation is failed, MME sends the Purge Request (PUR), to the HSS to delete the roaming data from HSS.
CLR/CLA (Cancel Location Request/Answer):
During the roaming a Mobile phone changes the location, as a result of this, serving MME changes or roaming location. Phone attaches to new MME and HSS clears the data from older MME. When HSS detects that now subscriber is under new MME, it sends the CLR to the previous MME. As a response, MME sends the CLA to the HSS.
PUR/PUA (Purge UE Request/Answer):
When MME needs to delete the subscriber record. MME initiates a PUR towards the HSS. Records may be deleted in the following cases.
Subscriber is Inactive from very long time.
GTP session creation failure as a part of update location procedure.
IDR/IDA (Insert Subscriber Data Request/Answer):
When an information or full subscription data needs to change on MME by the mobile operator. HSS sends the IDR to the visiting MME.
DSR/DSA(Delete Subscriber Data Request/Answer):
When subscriber data needs to remove from MME.
NOR/NOA (Notify Request/Answer):
This procedure is used when HSS needs to modify the change in UE. This may be because of changes in terminal information, change in APN of any other cases.