Wire the 5G Core
into your head.
An advanced-analysis course built verbatim from the twelve Release-19 specifications on your disk. Every node you see below is clickable. Every flow animates. Every claim carries its clause.
From EPC boxes to a cloud-native mesh
Narrated lesson with English subtitles. Timings whisper-verified against the narration script.
TS 23.501 V19.6.0 §4.1, §4.2.3The morph: EPC → Service-Based Architecture
Press morph. Watch four heavy EPC boxes with fixed point-to-point interfaces shatter into service-based functions on one common bus.
TS 23.501 V19.6.0 §4.1 · Fig 4.2.3-1SBA Explorer — click any Network Function
The full Rel-19 core, drawn exactly like TS 23.501 draws it. Toggle between the service-based view (one bus, Nnf service interfaces) and the reference-point view (N1…N40 lines) — same core, two photographs.
TS 23.501 V19.6.0 §4.2.3 Fig 4.2.3-1 / 4.2.3-2 · §6.2 · §4.2.7Identifiers — who is who, and who may know it
The subscription identity is never sent in clear over the air. The UE conceals the SUPI into a SUCI using the home-network public key (ECIES). Only the UDM/SIDF in the home network can de-conceal it.
TS 23.501 V19.6.0 §5.9 · TS 33.501 V19.5.0 §6.12Subscription Permanent Identifier — IMSI or NAI. Lives in UDM. Never on the air in clear. §5.9.2
Concealed SUPI — ECIES-encrypted with home-network public key. Sent at first registration. 33.501 §6.12
Temporary identity assigned by AMF; reallocated to defeat tracking. §5.9.4
Permanent Equipment Identifier — the device (IMEI/IMEISV), checked against 5G-EIR. §5.9.3
Generic Public Subscription Identifier — MSISDN or external ID, used outside the 3GPP domain. §5.9.8
5G-GUTI structure
GUAMI = MCC+MNC+Region+Set+Pointer → routes N2 signaling to the right AMF. The 5G-S-TMSI (Set ID + Pointer + 5G-TMSI) is what pages you on the radio. TS 23.501 §5.9.4.
The SUCI on the wire — octet by octet
Exactly how the SUCI is encoded in the NAS 5GS mobile identity IE. Only the Scheme Output is encrypted — everything before it stays in the clear so the visited network can route the SUCI to the right home network and UDM. TS 24.501 §9.11.3.4
1 · The problem 5G fixes — never send the SUPI in the clear
In 2G/3G/4G the permanent subscriber identity (IMSI) was sent over the air in the clear whenever the network had no temporary identity for you — which a passive IMSI-catcher ("Stingray") could sniff to identify and track a phone.
5G closes that hole. The permanent identity — the SUPI — is never transmitted in clear over the radio. The UE always sends a SUCI (concealed SUPI) at first contact, or a temporary 5G-GUTI once it has one. "User identity confidentiality" is a named 5G security feature. TS 23.501 §5.10.1 · TS 33.501 §6.12
2 · SUPI — the permanent identity, two formats
The SUPI (Subscription Permanent Identifier) lives in the UDM/UDR and identifies the subscription globally. It comes in two shapes §5.9.2 · TS 33.501 §6.12.1:
- IMSI-based — the classic
MCC (3) + MNC (2–3) + MSIN. The MSIN is the part that actually names you; MCC+MNC name your home operator. - NAI-based — a network-specific identifier
username@realm(RFC 7542), used for SNPN / non-3GPP / IoT.
The SUPI may also carry the NSI and is provisioned in the USIM's home network. It never leaves the home network in clear — the visited network only ever learns it after the home UDM de-conceals it.
3 · SUCI — field by field (the byte-map above)
The SUCI (Subscription Concealed Identifier) is "a privacy-preserving identifier containing the concealed SUPI" §5.9.2a. For an IMSI-based SUPI it is built from these fields TS 24.501 §9.11.3.4:
- SUPI Type (3 bits) —
000IMSI ·001Network-Specific Identifier ·010GCI ·011GLI. - MCC + MNC — the home PLMN, BCD-coded, in the clear (the routing needs it).
- Routing Indicator — 1–4 BCD digits, assigned by the home operator;
0000+padding if none is configured. - Protection Scheme Id (4 bits) —
0000Null ·0001ECIES Profile A ·0010ECIES Profile B ·1100–1111operator-specific. - Home Network Public Key Id (1 octet) — which home public key concealed this SUCI (0–254);
0for the null scheme — lets the operator rotate keys. - Scheme Output — the only encrypted field: for Null it is the MSIN in clear (BCD); for ECIES it is hex = ephemeral public key ‖ ciphertext ‖ MAC.
4 · ECIES — how the UE actually conceals the SUPI
Concealment uses the Elliptic Curve Integrated Encryption Scheme (ECIES) with the operator's home-network public key provisioned in the USIM. The private key never leaves the home network, so only the home network can reverse it. UE-side steps TS 33.501 Annex C.3.2:
- Generate a fresh ephemeral ECC key pair (new for every concealment → two SUCIs of the same SUPI look unrelated).
- ECDH: ephemeral private key × home public key → a shared secret.
- KDF (ANSI-X9.63, SHA-256) derives an encryption key, an initial counter block and a MAC key.
- AES-128-CTR encrypts the plaintext block (the MSIN / username) → ciphertext.
- HMAC-SHA-256 over the ciphertext → truncated MAC tag.
- Scheme Output = ephemeral public key ‖ ciphertext ‖ MAC tag.
Because the ephemeral key is random each time, the SUCI is non-linkable across registrations — a tracker can't tell two SUCIs belong to one subscriber.
5 · Profiles A & B — the two standard curves
3GPP standardises two ECIES profiles; an operator's key belongs to exactly one TS 33.501 Annex C.3.4:
- Profile A — Curve Curve25519 / X25519 (RFC 7748); 32-byte ephemeral public key; ANSI-X9.63-KDF (SHA-256), AES-128-CTR, HMAC-SHA-256. C.3.4.1
- Profile B — Curve secp256r1 (NIST P-256); 33-byte compressed ephemeral public key; same KDF / AES-CTR / HMAC family. C.3.4.2
Both give the same privacy guarantee; the choice is an operator/regulator preference. The Null scheme (Protection Scheme = 0000) sends the MSIN in clear and is only allowed for unauthenticated emergency calls or where a regulator forbids concealment.
6 · SIDF — only the UDM can turn a SUCI back into a SUPI
De-concealment happens at exactly one place: the SIDF (Subscription Identifier De-concealing Function), a service of the UDM that holds the home-network private key TS 33.501 §6.12.5. Home-side steps C.3.3:
- The AUSF passes the SUCI to the UDM during authentication (
Nudm_UEAuthentication_Get). - The SIDF does ECDH with its private key × the UE's ephemeral public key → the same shared secret → the same keys.
- It verifies the MAC, AES-CTR-decrypts the ciphertext, recovers the MSIN → the full SUPI, and returns it with the authentication vector.
So the serving/visited network runs the whole authentication without ever seeing the SUPI until the home network chooses to reveal it.
7 · The Routing Indicator — how a SUCI finds the right UDM/AUSF
A large operator runs many UDM/AUSF instances, each holding a slice of the subscriber base. The Routing Indicator (carried in the SUCI, assigned by the home operator, stored on the USIM) is the key that lets the network route signalling to the specific AUSF/UDM group that can de-conceal and authenticate this subscriber — via NRF discovery, using Routing Indicator + Home Network Id. TS 23.003 · TS 29.510
Default value 0000 means "no specific routing" — discovery falls back to any suitable UDM. This is why the Routing Indicator stays in the clear inside the SUCI.
8 · 5G-GUTI, GUAMI & 5G-S-TMSI — the temporary identity machine
Once you're registered, the AMF hands you a 5G-GUTI and you stop sending the SUCI. Verbatim structures TS 23.501 §5.9.4:
<5G-GUTI> := <GUAMI> <5G-TMSI><GUAMI> := <MCC> <MNC> <AMF Region ID (8b)> <AMF Set ID (10b)> <AMF Pointer (6b)>— routes N2 signalling to the serving AMF.<5G-S-TMSI> := <AMF Set ID> <AMF Pointer> <5G-TMSI (32b)>— the shortened form used for paging & Service Request on the radio.
Two spec-exact details worth knowing: the AMF may re-assign a new 5G-GUTI at any time (and does so to defeat tracking — the temporary-identity equivalent of the ephemeral SUCI), and the NG-RAN uses the 10 least-significant bits of the 5G-TMSI to compute paging occasions, so "the AMF shall ensure that the 10 LSBs are evenly distributed." §5.9.4 · TS 33.501 §6.12.3
9 · PEI & GPSI — the device and the public identity
- PEI (Permanent Equipment Identifier) — identifies the device, not the subscription: an IMEI / IMEISV for any UE with a 3GPP radio (EUI-64 for pure non-3GPP). The AMF checks it against the 5G-EIR over N17 to block stolen/blacklisted handsets. §5.9.3
- GPSI (Generic Public Subscription Identifier) — a public handle for the subscription outside the 3GPP domain: an MSISDN (the phone number) or an External Identifier. The system stores the GPSI↔SUPI association — but "there is no implied 1-to-1 relationship." Used by the NEF/AF for exposure. §5.9.8
Subscription Permanent Identifier — IMSI or NAI. Home-only, never in clear.
The subscriber part of an IMSI — what actually names you inside MCC+MNC.
Concealed SUPI sent at first contact — only the Scheme Output is encrypted.
0 IMSI · 1 NAI · 2 GCI · 3 GLI.
1–4 digits routing the SUCI to the right AUSF/UDM group.
0 Null · 1 ECIES Profile A · 2 ECIES Profile B.
Which home public key concealed the SUCI (0–254) — enables key rotation.
Eph. public key ‖ ciphertext ‖ MAC (ECIES), or MSIN in clear (Null).
Elliptic Curve Integrated Encryption Scheme — the concealment mechanism.
Curve25519 / X25519 (RFC 7748) — 32-byte ephemeral key.
secp256r1 / NIST P-256 — 33-byte compressed ephemeral key.
The UDM function holding the private key — the only entity that de-conceals.
No concealment — MSIN in clear; emergency / regulator-forbidden only.
Temporary identity = GUAMI + 5G-TMSI; reassigned to defeat tracking.
MCC+MNC+Region+Set+Pointer — routes N2 to the serving AMF.
Set ID + Pointer + 5G-TMSI — the 48-bit radio paging identity.
32-bit AMF-local UE id; its 10 LSBs set the paging occasion.
Permanent Equipment Identifier — IMEI/IMEISV; checked at the 5G-EIR.
Public subscription id outside 3GPP — MSISDN or External Identifier.
Fresh ephemeral key each time → two SUCIs of one SUPI can't be linked.
The SBI wire — hover every header
A real Nsmf_PDUSession CreateSMContext request as the AMF sends it. Hover / tap any highlighted part for the 29.500-exact meaning.
TS 29.500 V19.4.0 §5.2 · TS 29.502 V19.4.0 §5.2.2.2← hover a header
Every 3gpp-Sbi-* header is defined in TS 29.500 §5.2.3. They are the fingerprints of advanced trace analysis — routing, binding, priority, overload, correlation.
NRF — registration, heartbeat, discovery, token
The phone book at work. Step through the four Nnrf operations every core transaction depends on. The JSON panel shows the real payload of the highlighted step.
TS 29.510 V19.4.0 §5.2.2 · §5.3.2 · §5.4.2Communication models A · B · C · D
Four legal ways for a consumer to reach a producer. Watch the pink packet — in Model D the SCP even does the discovery for you (delegated discovery, headers 3gpp-Sbi-Discovery-*).
TS 23.501 V19.6.0 Annex E · TS 29.500 V19.4.0 §6.10Call-flow player — General Registration (overview cut)
The 23.502 registration flow, cut to the 12 steps that matter for architecture understanding. Module 2 replays it with all 25 steps and every IE. Use ► to animate the message across the lifelines.
TS 23.502 V19.6.0 §4.2.2.2.2 Fig 4.2.2.2.2-1Lab 1 — Dissect an NFProfile & craft a discovery query
Part A. This SMF NFProfile was rejected by the NRF. Six attribute values are illegal per TS 29.510 Table 6.1.6.2.2-1. Click the lines you believe are wrong, then check.
TS 29.510 V19.4.0 §6.1.6.2 · Table 6.1.6.2.2-1Part B — build the discovery query
The AMF needs an SMF for slice SST=1/SD=000001, DNN internet. Compose the Nnrf_NFDiscovery request:
IE / attribute explorer
The two vocabularies you must read fluently before Module 2: the NFProfile that every NF registers, and the 3gpp-Sbi-* custom headers that ride every SBI message.
Module 1 mastery check
Questions and answer order reshuffle on every load. Score 70%+ to consider M1 done — the same gate the full course enforces server-side.