与4G(LTE)网络中UE开机(或定期)需要在核心网附着(ATTACH)相似,在5G(NR)网络中终端开机后首先在核心网(5GC)的AMF中进行注册(Registration Request)请求;获得授权后接受服务并在5GS建立用户上下文。UE注册后才能进行连接管理和会话管理。
在UE初始发起时 UE与gNB建立RRC连接,并发起类型为InitialRegistration的Register Request,携带SUPI、NSSAI、安全参数等信息。
gNB收到UE的注册请求后,根据UE提供的NSSAI或者根据配置选择相应的AMF,将UE的NAS信息传递给AMF,同时携带gNB自身的位置信息、Cell ID等N2接口参数。
3.初始注册报文
NrnasOtaMsgInterface-MSG
1> 08 00001000 ..enNrnasOtaMsgId:nRMM-OTA-MSG-REGISTRATION-REQUEST (2048)
2> 00 00000000 ..ucUpDown:0x0 (0)
3> 04 00000100 ..ucVersion:0x4 (4)
7> 00 00000000 ..ulLengthASN:0x23 (35)
..struMsgChoice
....struNRNAS-MM-MSG-STRU
11> 00 00000000 ......ulNasMsgSize:0x17 (23)
12> 7E 01111110 ......extended-protocol-discriminator:0x7e (126)
13> 00 ----0000 ......sec-header-type:security-header-type-plain (0)
0000---- ......sPare-half-octet:0x0 (0)
......msg-body
14> 41 01000001 T ........registrationRequest
..........nAS-key-set-identifier
15> 79 0------- ............tSC:native-security-context (0)
-111---- ............nAS-key-set-identifier-value:key-set-identifier-value-nO-KEY (7)
..........registration-type
----1--- ............follow-on-request:0x1 (1)
-----001 ............registration-type-value:initial-registration (1)
17> 0D 00001101 L ..........nR-mobile-identity
18> 01 -----001 ............type-of-identity:suci (1)
----0--- ............odd-or-even-indic:even-number (0)
............suci-body
-000---- ..............supi-format:sUPI-Format-IMSI (0)
0------- ..............spare:0x0 (0)
..............supi-format-imsi
21> 70 01110000 ................mcc-mnc:0x64f070 (6615152)
................routing-indicator
24> 00 ----0000 ................protection-Scheme-ID:protection-Null-Scheme (0)
0000---- ................sPare-half-octet:0x0 (0)
25> 00 00000000 ................home-Network-Pub-Key-ID:0x0 (0)
30> 00 00000000 ................scheme-Output:00 00 00 00 00
整理:kangguoying20200922 本文参考:[url]https://blog.csdn.net/u011272715/article/details/104249738[/url]
"移动手机为啥要读联通WCDMA信号--LTE案例”已在微信公众号"跟着老康学5G"中推出,敬请关注!