Project

General

Profile

Open5GS-Traces » History » Version 40

jolly, 02/01/2024 04:10 PM

1 1 jolly
h1. Open5GS-Traces
2
3 23 jolly
{{>toc}}
4
5 8 jolly
h2. Setup of this example
6
7
* Ericsson RBS 6402 (eNodeB)
8
* Open5GS (4G network elements)
9
* OsmoHLR with OsmoDia2GSUP (HSS)
10
* OsmoMSC (SMS)
11
12 37 jolly
h2. Wireshark trace
13
14 40 jolly
This trace was used in this example. It includes attachment and detachment.
15
16
* attachment:attach_detach.pcapng
17
18 39 jolly
19 17 jolly
20 8 jolly
h2. Idle
21 1 jolly
22
When all phones are Idle, one will see the following trace with Wireshark on the link between eNodeB (Ericsson RBS) and MME (Open5GS).
23 10 jolly
24 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_idle.png, size=600)}}
25 8 jolly
26
The eNodeB (IP 10.0.15.117) is connected to MME (IP 10.0.15.1) via SCTP. Also the eNodeB syncs its clock to NTP server (IP 10.0.15.1).
27 19 jolly
28 9 jolly
The network 10.0.15.0/24 is the RAN network in this example.
29
30 17 jolly
31 9 jolly
h2. 4G Attachment
32
33 27 jolly
!enb_attach.png!
34 1 jolly
35 23 jolly
The phone is turned on and ready to attach to 4G network. The filter of Wireshark is set to "s1ap", so that only packages between eNodeB and MME are shown.
36 20 jolly
37 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach.png, size=1000)}}
38 16 jolly
39 18 jolly
A 4G phone is attached to the network, using SIM cards that is registered in the HSS. The APN name used is "internet".
40 19 jolly
41 1 jolly
Lets go into detail:
42 12 jolly
43
h3. Attach request
44 1 jolly
45 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_attach_request.png, size=1000)}}
46 17 jolly
47 18 jolly
The UE sends an "Attach request". It is the message type of the "NAS-PDU" information element of the "initiatingMessage". The "NAS-PDU" message type is highlighted blue in the picture above.
48 19 jolly
49 17 jolly
Also within the "NAS-PDU" is the "EPS mobile identity". In this case the UE has the mobile country code "999" and the mobile network code "10". The IMSI is not shown. Because the UE was attached before, a TMSI is used. 
50 1 jolly
51
If the mobile station was not registered to the MME, the MME will request identity and authentication and send "Attach Request" again after enabling encryption
52
53
h3. "Identity request" and "Identity response"
54 24 jolly
55 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_identity_request.png, size=1000)}}
56 24 jolly
57 30 jolly
Because identity is not know, the MME requests IMSI, as . (The MME was restartet before this trace, so that the TMSI is unknown.)
58 1 jolly
59 34 jolly
The MME sends an "Identity request" to the UE. The "NAS-PDU" message type is highlighted blue in the picture above. The identity type requested is highlighted light blue in the picture above.
60
61 1 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_identity_response.png, size=1000)}}
62
63 35 jolly
The MME receives the response with IMSI. Again, the "NAS-PDU" message type is highlighted blue in the picture above. The mobile identity is highlighted light blue in the picture above. The IMSI is now known to the MME.
64 31 jolly
65 24 jolly
h3. "Authentication request" and "Authentication response"
66
67 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_authentication_request.png, size=1000)}}
68 1 jolly
69 35 jolly
The MME sends an "Authentication request" to the UE. The "NAS-PDU" message type is highlighted blue in the picture above.
70 1 jolly
71 35 jolly
A random value "RAND" and authentication parameters "AUTN" are used to request authentication from UE.
72
73 1 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_authentication_response.png, size=1000)}}
74 35 jolly
75
The UE sends an "Authentication response" to the UE. The "NAS-PDU" message type is highlighted blue in the picture above.
76
77
The result "RES" is returned to the MME. (Highlighted light blue in the picture above.)
78 28 jolly
79 24 jolly
The subsequent “Security mode command” and “Security mode complete” messages are not depicted. The latter message is sent after encryption between UE and eNodeB is enabled. The message also carries the Attach request again.
80
81
h3. "ESM information request" and "ESM information response"
82
83 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_ESM_infomation_request.png, size=1000)}}
84 1 jolly
85
The MME sends an "ESM information request" to the UE, to request APN name. The "NAS-PDU" message type is highlighted blue in the picture above.
86 16 jolly
 
87 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_ESM_infomation_response.png, size=1000)}}
88 19 jolly
89 1 jolly
The UE send an "ESM information response." The UE uses the APN name "internet". The "NAS-PDU" message type is highlighted blue in the picture above.
90 18 jolly
91
This is the default configuration in the example setup. It can be configured in the configuration file for OsmoHLR. (osmo-hlr.cfg)
92 14 jolly
93
94 24 jolly
h3. "Attach accept"
95 1 jolly
96 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_attach_accept.png, size=1000)}}
97 20 jolly
98 21 jolly
The MME sends an "Attach accept" to the UE. The "NAS-PDU" message type is highlighted blue in the picture above.
99 1 jolly
100 20 jolly
Also within the “NAS-PDU” is an “ESM message container” with an “EPS session management message” to activate the default EPS bearer context. (Highlighted light blue in the picture above.)
101
102 1 jolly
The subsequent “InitialContextSetupResponse” and “UECapabilityInfoIndication” messages are not depicted. The latter message contains capabilities of the UE.
103 20 jolly
104 1 jolly
h3. "Attach complete"
105 24 jolly
106 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_attach_attach_complete.png, size=1000)}}
107 1 jolly
108 20 jolly
Finally the UE sends an "Attach complete". The "NAS-PDU" message type is highlighted blue in the picture above.
109
110 36 jolly
Also within the “NAS-PDU” is an “ESM message container” with an “Activate default EPS bearer context accept”. (Highlighted light blue in the picture above.)
111 20 jolly
112
h2. Packet transfer
113
114 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_gtp_1.png, size=1000)}}
115 20 jolly
116 1 jolly
The "GPRS Tunneling Protocol" (GTP) is used to tunnel packet traffic of the user plane. between eNodeB and SGW.
117 20 jolly
118 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_gtp_2.png, size=1000)}}
119 20 jolly
120 21 jolly
As depicted above, the GTP packet transmitted from the eNodeB (IP 10.0.15.117) to the SGW (IP 10.0.15.3).
121 20 jolly
122 1 jolly
The carried packet is transmitted from the UE (IP 10.0.6.2) to the destination in the Internet (IP 104.26.15.42)
123 20 jolly
124 1 jolly
125 23 jolly
h2. 4G Detachment
126
127 26 jolly
!enb_detach.png!
128 1 jolly
129 20 jolly
The 4G phone is turned off or the airplane mode is turned on. The phone detaches from network.
130 10 jolly
131 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_detach.png, size=1000)}}
132 14 jolly
133 1 jolly
Lets go into detail:
134 14 jolly
135 26 jolly
136 25 jolly
h3. "Detach Request"
137 1 jolly
138 33 jolly
p{border: solid 1px #000; padding: 0.5em;}. {{thumbnail(wireshark_enb_detach_detach_request.png, size=1000)}}
139 21 jolly
140
Similar to the "Attach request", described above, the UE sends an "Detach request". It is the message type of the "NAS-PDU" information element of the "initiatingMessage". The "NAS-PDU" message type is highlighted blue in the picture above.
141
142
Also within the "NAS-PDU" is the "EPS mobile identity". This is also similar to the "Attach request".
143 1 jolly
144
The subsequent “UEContextReleaseCommand” message (sent from EMM) and “UEContextREleaseComplete” messages (sent from UE) are not depicted.
145 26 jolly
146
147
h2. Attachment inside EPC
148
149
!epc_attach.png!
150
151
After authentication is done and after receiving ESM information (e.g. APN), a session is created between network elements inside the Envolved Packet Code (EPC).
152
153 28 jolly
{{thumbnail(wireshark_epc_attach.png, size=1000)}}
154 26 jolly
155
h3. MME -> SGWc
156
157
As depicted in the Wireshark picture above, the MME sends "Create Session Request" towards the control plane of the SGW. The GPRS tunneling protocol (GTP) is used. The request is depicted at frame number 254, the response at frame number 266.
158
159
h3. SGWc -> SGWu
160
161
After receiving the "Create Session Request" from the MME, the control plane of the SGW sends a "PFCP Session Establishment Request" to the user plane of the SGW. The packet forwarding control protocol (PFCP) is used. The request is depicted at frame number 255, the response at frame number 257.
162
163
h3. SGWc -> PGWc
164
165
The control plane of the SGW also sends a "Create Session Request" to the control plane of the PGW. The GPRS tunneling protocol (GTP) is used here again. The request is depicted at frame number 258, the response at frame number 263.
166
167
h3. PGWc -> PCRF
168
169
The control plane of the PGW sends a "Credit-Control Request" to the PCRF. The Diameter protocol is used. The request is depicted at frame number 259, the answer at frame number 260.
170
171
h3. PGWc -> PGWu
172
173
After receiving the "Credit-Control Answer" from the PCRF, the control plane of the PGW sends a "PFCP Session Establishment Request" to the user plane of the PGW. The packet forwarding control protocol (PFCP) is used here again. The request is depicted at frame number 261, the response at frame number 262.
174
175
h3. SGWc -> SGWu
176
177
After receiving the "Create Session Response" from the control plane of the PGW, the control plane of the SGW sends a "PFCP Session Modification Request" to the user plane of the SGW. The packet forwarding control protocol (PFCP) is used here again. The request is depicted at frame number 264, the response at frame number 265.
Add picture from clipboard (Maximum size: 48.8 MB)