## 4 The Proposed Scheme
### Roaming Authentication Phase  
When the UE needs to roam across the network, due to changes in geographical location or network conditions, the roaming authentication phase can be completed. The proposed scheme designs a lightweight roaming authentication protocol to meet the needs of UE. For UE that need to change core network, they must be re-authenticated and negotiate a new session key. To reduce the overheads of roaming authentication, the UE should perform pre-negotiation after the initial authentication or the last roaming. **Pre-negotiation Phase**: The UE first collects optional satellite information, and then sends its \(TID_{i}\) and \(ID_{tLEO}\) to the source core network, namely sCN (i.e., NCCs or 6 SCs) through the sLEO, to request roaming authentication tokens. After receiving the UE's request information, the sCN selects the generation key \(K_{1}\). Then, sCN calculates \(Ticket_{i}=SENC_{\textit{KDF}(psk)}(TID_{i}||ID_{tLEO}||K_{1}||ET)\), where \(SENC(\cdot)\) is a symmetric encryption function, \(KDF(\cdot)\) is a key derivation function, \(psk\) is a pre-shared key maintained between the CNs and LEOs, and \(ET\) is the expiration time of the token. A secure channel is established between the UE and sLEO during the authentication phase, and secure channels exist between core networks. The sCN encrypts \((Ticket_{i},K_{1},ET)\) using the key \(K_{0}\) stored between sCN and UE, then returns the message to the UE. When \(Ticket_{i}\) expires or the UE discovers  
Figure 4: Authentication phase in the batch authentication scenario. new suitable LEOs, the UE needs to apply to the sLEO for new tokens. The LEO updates the token issued to the UE when the LEO or CN evaluates that it is necessary to change the \(psk\). At the same time, if the tLEO does not belong to the sCN as _Case ii_, the sCN sends the \(TID_{i}\) list to the tCN through the channel, then tCN sends \(TID_{i}\) to tLEO. Otherwise, sCN sends the \(TID_{i}\) list directly to tLEO as _Case i_. The specific negotiation process is shown in the upper part of Figure 5.  
**Roaming Authentication Phase**: When the UE needs to roam, the process is as shown in the lower part of Figure 5. The following steps need to be completed:  
1. The UE first generates a random number \(r_{UE}\), then uses the public key \(pk_{tLEO}\) of the tLEO to encrypt \(c_{1}=AENC_{pk_{tLEO}}(r_{UE},Ticket_{i})\), where \(AENC(\cdot)\) is an asymmetric encryption algorithm based on ECC. Then, the UE selects a random number \(r_{1}\in Z_{q}^{*}\) and obtains a timestamp \(TS_{1}\), sets \(g^{r_{1}}\), and generates \(v_{1}=H_{1}(TID_{i}||g^{r_{1}}||Ticket_{i}||C_{1}||TS_{1})\). Finally, the UE sends message \(M_{1}=(TID_{i}||g^{r_{1}}||C_{1}||v_{1}||TS_{1})\) to the tLEO;
2. Upon receiving the message, the tLEO first checks the timestamp then decrypts \(c_{1}\) using its private key \(sk_{tLEO}\) in order to obtain \(r_{UE}\) and \(Ticket_{i}\). The tLEO decrypts \(Ticket_{i}\) using \(KDF(psk)\) and checks the ID and ET in the token. If it does meet the conditions, the tLEO generates \(v_{1}^{\prime}\) to verify whether it is equal to \(v_{1}\). If verified, tLEO generates a random number \(r_{tLEO}\) and generates \(K_{2}=KDF(K_{1}||r_{UE})\). Then, the tLEO calculates \(c_{2}=SENC_{K_{2}}(r_{tLEO})\), where \(SENC(m)\) is a symmetric encryption algorithm. The tLEO selects a random number \(r_{2}\in Z_{q}^{*}\) and sets \(g^{r_{2}}\). Finally, the  
Figure 5: Pre-negotiation and roaming authentication phase in SGIN. tLEO calculates \(v_{2}=H_{1}(ID_{tLEO}||g^{r_{2}}||r_{tLEO}||K_{2}||c_{2}||TS_{2})\) and sends the message \(M_{2}=(ID_{tLEO}||g^{r_{2}}||c_{2}||v_{2}||TS_{2})\) to the UE, where \(TS_{2}\) is a timestamp;
3. While receiving the message, UE first checks the timestamp. If checks, UE calculates \(K_{2}=KDF(K_{1}||r_{tLE})\). Then UE decrypts \(c_{2}\) and gets \(r_{tLEO}\). UE calculates \(v_{2}^{\prime}\) and checks whether \(v_{2}^{\prime}=v_{2}\). If it does meet, the new conversation between UE and the tLEO is established.