Communication method and device

Through authentication and authentication network elements, the roaming status of the terminal device and the management of its access to HPLMN rights solves the problem that HPLMN operators cannot accurately manage and bill, and realizes accurate billing and management of roaming equipment.

CN119485300APending Publication Date: 2025-02-18HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311021341.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-08-11
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

When the terminal device is in a roaming state, the operator of HPLMN cannot accurately manage and bill, resulting in inaccurate billing.

Method used

The authentication authentication network element receives the authentication request message sent by the communication device, judges that the communication device is currently in a roaming state, and decides whether to allow the communication device to access the HPLMN based on the allowed MCC list in the contract data, thereby adopting different charging strategies.

Benefits of technology

It realizes better management of terminal devices in roaming state, ensures the accuracy of billing, and avoids economic losses caused by failure to identify roaming state.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119485300A_ABST
    Figure CN119485300A_ABST
Patent Text Reader

Abstract

The invention provides a communication method and device, and the method comprises the steps: an authentication network element receives an authentication request message sent by a communication device, and the authentication request message comprises a first MCC of the current position of the communication device, and is used for indicating the current country or region of the communication device; determining that the communication device is currently in a roaming state according to the fact that the first MCC is different from a second MCC, wherein the second MCC is an MCC contained in subscription data of the communication device; if the first MCC is the allowed MCC in the subscription data, the first MCC is allowed to access the HPLMN, and a charging strategy adopted by an operator of the HPLMN for the communication device is different from a charging strategy adopted by the communication device when the communication device is in a non-roaming state; or if the first MCC is not the allowed MCC in the subscription data, the first MCC is not allowed to access the HPLMN. In the scheme, when the communication device is in a roaming state and is accessed to the HPLMN, an operator of the HPLMN can better manage the communication device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communications, and more specifically, to a communication method and device. Background Art

[0002] Mobile communication systems provide roaming capabilities for terminal devices, which enable terminal devices to communicate in different places, such as different cellular network cells. Roaming is the name of a mobile phone service, which means that after a terminal device leaves its registered service area and moves to another service area, the mobile communication system can still provide services to it.

[0003] When the terminal device is not roaming, the terminal device is located in the home public land mobile network (HPLMN) and enjoys the services provided by the HPLMN. When the terminal device is in roaming state (also called roaming out), it is in the visited public land mobile network (VPLMN). The terminal device can not only access the VPLMN and enjoy the services provided by the VPLMN, but also access the HPLMN and enjoy the services provided by the HPLMN through the roaming agreement between the VPLMN and the HPLMN.

[0004] In the related technical solutions, when the terminal device roams out, the operator of the HPLMN does not know whether the terminal device is currently in a roaming state or a non-roaming state, so the operator of the HPLMN cannot manage the terminal device. For example, taking billing management as an example, when the terminal device roams out, the terminal device accesses the HPLMN, and the operator of the HPLMN does not know that the terminal device is currently in a roaming state. At this time, the operator of the HPLMN still charges the terminal device according to the non-roaming charging mode, resulting in inaccurate billing.

[0005] In view of this, when terminal devices roam out, how the operators of the HPLMN can better manage the terminal devices becomes a technical problem that needs to be solved urgently. Summary of the invention

[0006] The present application provides a communication method and apparatus, which can enable an operator of an HPLMN to better manage the terminal device when the terminal device is in a roaming state and accesses the HPLMN.

[0007] In a first aspect, a communication method is provided, comprising: an authentication network element receives an authentication request message sent by a communication device, the authentication request message including a first mobile country code MCC of the current location of the communication device, the first MCC being used to indicate the country or region where the communication device is currently located; the authentication network element determines that the communication device is currently in a roaming state based on the difference between the first MCC and a second MCC, the second MCC being an MCC in the contract data of the communication device used to identify the country or region to which the communication device belongs; the authentication network element sends a roaming request message to a mobile country code based on the first MCC and the MCC allowed in the contract data. The communication device sends an authentication response message, which includes indication information, and the indication information is used to indicate whether the communication device is allowed to access the HPLMN; if the first MCC is the MCC allowed in the subscription data, the indication information indicates that the communication device is allowed to access the home terrestrial public network HPLMN, and the charging policy adopted by the operator of the HPLMN for the communication device is different from the charging policy when the communication device is in a non-roaming state; or if the first MCC is not the MCC allowed in the subscription data, the indication information indicates that the communication device is not allowed to access the home terrestrial public network HPLMN.

[0008] In the above technical solution, the authentication network element in the HPLMN determines that the communication device is currently in a roaming state by comparing the MCC of the current location reported by the communication device with the MCC included in the contract data of the communication device. If the MCC of the current location reported by the communication device is the MCC allowed in the contract data, the authentication network element can allow it to access the HPLMN. At this time, the charging strategy adopted for the communication device is different from the charging strategy when the communication device is in a non-roaming state; if the MCC of the current location reported by the communication device is not the MCC allowed in the contract data, the authentication network element can prohibit it from accessing the HPLMN, so that the operator of the HPLMN can better manage the communication device in a roaming state.

[0009] In combination with the first aspect, in some implementations of the first aspect, the authentication network element is a home subscriber server HSS, and the HSS stores the subscription data, wherein the subscription data includes an allowed MCC list.

[0010] It should be understood that the allowed MCC list in the subscription data is used to identify the countries or regions that the communication device is allowed to access.

[0011] In the above technical solution, the authentication network element is the HSS in the HPLMN. Since the contract data of the communication device is stored in the HSS, the HSS determines whether the communication device is currently in a roaming state based on the stored contract data of the communication device, and determines whether to allow the communication device to access the HPLMN, which is relatively simple to implement.

[0012] In combination with the first aspect, in certain implementations of the first aspect, the authentication network element is an evolved packet data gateway ePDG or an authentication authentication and billing AAA network element, and the method also includes: the authentication network element receives the subscription data from the HSS, and the subscription data includes an allowed MCC list.

[0013] In combination with the first aspect, in certain implementations of the first aspect, if the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, and the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

[0014] In the above technical solution, when the indication information sent by the authentication network element to the communication device indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, and the communication device can learn the reason why it cannot access the HPLMN through the error code, thereby avoiding multiple attempts to access the HPLMN when the MCC of the current location of the communication device has not changed, thereby avoiding waste of resources.

[0015] In combination with the first aspect, in certain implementations of the first aspect, if the indication information indicates that the communication device is not allowed to access the HPLMN, the communication device may try again to send the MCC to the authentication network element in the HPLMN when the MCC at its location changes, so as to request again to try to access the HPLMN.

[0016] In the above technical solution, when the MCC of the communication device at its location changes, it tries to send the MCC to the authentication network element in the HPLMN again. If the changed MCC is the MCC allowed by the contract data of the communication device, the communication device can access the HPLMN in time.

[0017] In combination with the first aspect, in certain implementations of the first aspect, when the authentication network element uses the first MCC as the MCC allowed in the subscription data, the charging price for the communication device by the operator of the HPLMN is higher than the charging price when the communication device is in a non-roaming state.

[0018] In the above technical solution, when the communication device is in a roaming state and the MCC of its current location reported by the communication device is the MCC allowed in the contract data, the charging price for the communication device by the HPLMN operator is higher than the charging price when the communication device is in a non-roaming state. This can avoid the loss caused by the HPLMN operator charging the communication device in a roaming state according to the charging price in the non-roaming state.

[0019] In combination with the first aspect, in certain implementations of the first aspect, the communication device accesses the HPLMN and uses the services provided by the HPLMN, which may include but are not limited to: voice over wireless fidelity (VOWIFI) service, voice over long-term evolution (VOLTE) service, MMS, etc.

[0020] For VOWIFI services, the location information of the communication device is a default value configured in advance. If the communication device is currently in roaming status, the operator of the HPLMN cannot obtain the real location information of the terminal device, and the operator of the HPLMN cannot determine that the communication device is currently in roaming status. Therefore, the authentication network element in the HPLMN determines that the communication device is currently in roaming status by comparing the MCC of the current location reported by the communication device with the MCC included in the contract data of the communication device. When the HPLMN provides VOWIFI services to the communication device, it can manage the charges for the communication device according to the roaming status.

[0021] In combination with the first aspect, in some implementations of the first aspect, the MCC is an octet string type, the MCC is used by the 3GPP-AAA server and the HSS to identify the country where the user equipment is located, and the encoding of the octet string of the MCC is defined by the H-PLMN operator. In a second aspect, a communication method is provided, comprising: when a communication device is in a roaming state, the communication device sends an authentication request message to an authentication and verification network element in a home terrestrial public network HPLMN, the authentication request message including a first mobile country code MCC of a current location of the communication device, the first MCC being used to indicate a country or region where the communication device is currently located; the communication device receives an authentication response message sent by the authentication and verification network element, the authentication response message including indication information, the indication information being used to indicate whether the communication device is allowed to access the HPLMN; if the indication information indicates that the communication device is allowed to access the HPLMN, the communication device accesses the HPLMN, and a charging policy adopted by an operator of the HPLMN for the communication device is different from a charging policy when the communication device is in a non-roaming state; or if the indication information indicates that the communication device is not allowed to access the HPLMN, the communication device does not access the HPLMN.

[0022] In combination with the second aspect, in certain implementations of the second aspect, the communication device determines that the communication device is currently in a roaming state based on the fact that the first MCC and the second MCC are different, and the second MCC is the MCC used to identify the country or region to which the communication device belongs in the contract data in the user identification card SIM card of the communication device.

[0023] In combination with the second aspect, in some implementations of the second aspect, the authentication network element is at least one of the following: an authentication and accounting AAA network element, a home subscriber server HSS network element, and an evolved packet data gateway ePDG.

[0024] In combination with the second aspect, in certain implementations of the second aspect, if the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, and the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

[0025] In combination with the second aspect, in certain implementations of the second aspect, when the communication device accesses the HPLMN, the charging price charged by the operator of the HPLMN to the communication device is higher than the charging price when the communication device is in a non-roaming state.

[0026] It should be understood that the above-mentioned communication device may be a terminal device, or may be a chip in the terminal device, and the embodiments of the present application do not specifically limit this.

[0027] It should also be understood that the beneficial effects of the second aspect and each aspect are the same as the beneficial effects of the first aspect and each aspect. Please refer to the beneficial effects of the first aspect and each aspect for details, and no further details will be given here.

[0028] According to a third aspect, an authentication network element is provided, which includes: a receiving module, a processing module, and a sending module. The receiving module is used to receive an authentication request message sent by a communication device, wherein the authentication request message includes a first mobile country code MCC of the current location of the communication device, and the first MCC is used to indicate the country or region where the communication device is currently located; the processing module is used to determine that the communication device is currently in a roaming state according to the difference between the first MCC and the second MCC, and the second MCC is the MCC used to identify the country or region to which the communication device belongs in the subscription data of the communication device; the sending module is used to send an authentication response message to the communication device according to the first MCC and the MCC allowed in the subscription data, and the authentication response message includes indication information, and the indication information is used to indicate whether the communication device is allowed to access the HPLMN; if the first MCC is the MCC allowed in the subscription data, the indication information indicates that the communication device is allowed to access the home terrestrial public network HPLMN, and the charging strategy adopted by the operator of the HPLMN for the communication device is different from the charging strategy when the communication device is in a non-roaming state; or if the first MCC is not the MCC allowed in the subscription data, the indication information indicates that the communication device is not allowed to access the home terrestrial public network HPLMN.

[0029] In combination with the third aspect, in some implementations of the third aspect, the authentication network element is a home subscriber server HSS, and the HSS stores the subscription data, wherein the subscription data includes an allowed MCC list.

[0030] It should be understood that the allowed MCC list is used to identify countries or regions that the UE is allowed to access.

[0031] In combination with the third aspect, in certain implementations of the third aspect, the authentication network element is an evolved packet data gateway ePDG or an authentication authentication and billing AAA network element, and the receiving module is further used to receive the subscription data from the HSS, and the subscription data includes an allowed MCC list.

[0032] In combination with the third aspect, in certain implementations of the third aspect, if the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, and the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

[0033] In conjunction with the third aspect, in certain implementations of the third aspect, the HSS shall check whether the received MCC is in the specified allowed MCC list. If not, the Experimental-Result-Code shall be set to DIAMETER_ERROR_MCC_NOT_ALLOWED, which is sent by the HSS to indicate that the user is restricted from accessing the service due to MCC code restrictions.

[0034] In combination with the third aspect, in certain implementations of the third aspect, when the authentication network element uses the first MCC as the MCC allowed in the subscription data, the charging price for the communication device by the operator of the HPLMN is higher than the charging price when the communication device is in a non-roaming state.

[0035] It should be understood that the beneficial effects of the third aspect and each aspect are the same as the beneficial effects of the first aspect and each aspect. Please refer to the beneficial effects of the first aspect and each aspect for details, and no further details will be given here.

[0036] In a fourth aspect, a communication device is provided, the device comprising: a sending module, a receiving module, and a processing module. The sending module is used to send an authentication request message to an authentication and verification network element in a home terrestrial public network HPLMN when the communication device is in a roaming state, the authentication request message including a first mobile country code MCC of the current location of the communication device, the first MCC being used to indicate the country or region where the communication device is currently located; the receiving module is used to receive an authentication response message sent by the authentication and verification network element, the authentication response message including indication information, the indication information being used to indicate whether the communication device is allowed to access the HPLMN; the processing module is used to, if the indication information indicates that the communication device is allowed to access the HPLMN, access the HPLMN, and the charging strategy adopted by the operator of the HPLMN for the communication device is different from the charging strategy when the communication device is in a non-roaming state; or the processing module is used to, if the indication information indicates that the communication device is not allowed to access the HPLMN, not access the HPLMN.

[0037] In combination with the fourth aspect, in certain implementations of the fourth aspect, the processing module is also used to determine that the communication device is currently in a roaming state based on the fact that the first MCC and the second MCC are different, and the second MCC is the MCC in the contract data of the user identification card SIM card of the communication device used to identify the country or region to which the communication device belongs.

[0038] In combination with the fourth aspect, in some implementations of the fourth aspect, the authentication network element is at least one of the following: an authentication and accounting AAA network element, a home subscriber server HSS network element, and an evolved packet data gateway ePDG.

[0039] In combination with the fourth aspect, in certain implementations of the fourth aspect, if the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, and the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

[0040] In combination with the fourth aspect, in certain implementations of the fourth aspect, when the communication device accesses the HPLMN, the charging price charged by the operator of the HPLMN to the communication device is higher than the charging price when the communication device is in a non-roaming state.

[0041] It should be understood that the beneficial effects of the fourth aspect and each aspect are the same as the beneficial effects of the first aspect and each aspect. Please refer to the beneficial effects of the first aspect and each aspect for details, and no further details will be given here.

[0042] According to a fifth aspect, an authentication network element is provided, the authentication network element comprising a processor for implementing the functions of the authentication network element in the method described in the first aspect.

[0043] In a possible implementation, the authentication network element may further include a memory, the memory is coupled to the processor, and the processor is used to implement the function of the authentication network element in the method described in the first aspect above.

[0044] In a possible implementation, the memory is used to store program instructions and data. The memory is coupled to the processor, and the processor can call and execute program instructions stored in the memory to implement the function of the authentication network element in the method described in the first aspect above.

[0045] In a possible implementation, the apparatus may further include a communication interface, which is used for the apparatus to communicate with other devices. The communication interface may be a transceiver, an input / output interface, or a circuit.

[0046] In one possible design, the authentication network element includes: a processor and a communication interface,

[0047] The processor is used to run a computer program so that the network element for obtaining the authentication and verification implements any one of the methods described in the first aspect above;

[0048] The processor communicates with the outside by using the communication interface.

[0049] It can be understood that the external object may be an object other than the processor, or an object other than the authentication network element.

[0050] In another possible design, the authentication network element is a chip or a chip system. The communication interface may be an input / output interface, an interface circuit, an output circuit, an input circuit, a pin or a related circuit on the chip or the chip system. The processor may also be embodied as a processing circuit or a logic circuit.

[0051] In a sixth aspect, a communication device is provided, which includes a processor for implementing the functions of the communication device in the method described in the second aspect.

[0052] In a possible implementation manner, the device may further include a memory, which is coupled to the processor, and the processor is used to implement the functions of the communication device in the method described in the first aspect above.

[0053] In a possible implementation, the memory is used to store program instructions and data. The memory is coupled to the processor, and the processor can call and execute program instructions stored in the memory to implement the functions of the communication device in the method described in the second aspect above.

[0054] In a possible implementation, the apparatus may further include a communication interface, which is used for the apparatus to communicate with other devices. The communication interface may be a transceiver, an input / output interface, or a circuit.

[0055] In one possible design, the device includes: a processor and a communication interface,

[0056] The processor is used to run a computer program so that the communication device implements any one of the methods described in the second aspect above;

[0057] The processor communicates with the outside by using the communication interface.

[0058] It can be understood that the external part may be an object other than the processor, or an object other than the device.

[0059] In another possible design, the device is a chip or a chip system. The communication interface can be an input / output interface, an interface circuit, an output circuit, an input circuit, a pin or a related circuit on the chip or the chip system. The processor can also be embodied as a processing circuit or a logic circuit.

[0060] In a seventh aspect, the present application provides a computer-readable storage medium, which stores instructions. When the computer-readable storage medium is run on a computer, the computer executes the methods in the above aspects.

[0061] In an eighth aspect, the present application provides a computer program product comprising instructions, which, when executed on a computer, enables the computer to execute the methods in the above aspects.

[0062] In a ninth aspect, a communication system is provided, comprising the device shown in the third aspect and the device shown in the fourth aspect.

[0063] In the tenth aspect, a chip or a chip system is provided, the chip or chip system includes at least one processor and a communication interface, the communication interface and the at least one processor are interconnected by a line, and the at least one processor is used to run a computer program or instruction to perform the method in any possible implementation of the first aspect to the second aspect. The communication interface in the chip can be an input / output interface, a pin or a circuit, etc.

[0064] In a possible implementation, the chip or chip system described above in the present application further includes at least one memory, in which instructions are stored. The memory may be a storage unit inside the chip, such as a register, a cache, etc., or a storage unit of the chip (e.g., a read-only memory, a random access memory, etc.). BRIEF DESCRIPTION OF THE DRAWINGS

[0065] Figure 1 It is a schematic diagram of a network architecture applicable to an embodiment of the present application.

[0066] Figure 2 It is a schematic flow chart of the communication method provided in an embodiment of the present application.

[0067] Figure 3 It is a schematic flow chart of another communication method provided in an embodiment of the present application.

[0068] Figure 4 It is a schematic block diagram of an authentication network element 400 provided in an embodiment of the present application.

[0069] Figure 5 It is a schematic block diagram of a communication device 500 provided in an embodiment of the present application.

[0070] Figure 6 It is another schematic structural diagram of the communication device 600 provided in an embodiment of the present application. DETAILED DESCRIPTION

[0071] The technical solution in this application will be described below in conjunction with the accompanying drawings.

[0072] The third generation mobile communication network (3rd generation partnership project, 3GPP) is currently the most widely used wide area mobile communication network. The 3GPP standard group has formulated the 4G core network / evolved packet core network (evolved packet core, EPC) network. Figure 1 , a network architecture provided in an embodiment of the present application is described in detail.

[0073] refer to Figure 1 As shown, the core network under the above network architecture can be accessed through two access technologies, one is the 3GPP access technology, that is, accessing the core network through the 3GPP network; the other is the non-3GPP access technology, that is, accessing the core network through the non-3GPP network.

[0074] The above network architecture specifically includes:

[0075] 1. User equipment (UE)

[0076] UE, also known as terminal equipment, can access the core network using non-3GPP access technology and receive communication services provided by the network side.

[0077] UE may include various handheld devices with wireless communication functions, vehicle-mounted devices, wearable devices, computing devices or other processing devices connected to a wireless modem, as well as various forms of terminals, mobile stations (MS), terminals or soft terminals, etc. For example, water meters, electric meters, sensors, etc.

[0078] Exemplarily, the user equipment in the embodiments of the present application may refer to an access terminal, a user unit, a user station, a mobile station, a mobile station, a relay station, a remote station, a remote terminal, a mobile device, a user terminal, a terminal equipment, a wireless communication device, a user agent or a user device. The user equipment may also be a cellular phone, a cordless phone, a session initiation protocol (SIP) phone, a wireless local loop (WLL) station, a personal digital assistant (PDA), a handheld device with wireless communication function, a computing device or other processing device connected to a wireless modem, a vehicle-mounted device, a wearable device, a user equipment in a 5G network or a user equipment in a future evolved public land mobile communication network (PLMN) or a user equipment in a future Internet of Vehicles, etc., and the embodiments of the present application are not limited to this.

[0079] As an example and not a limitation, in the embodiments of the present application, wearable devices may also be referred to as wearable smart devices, which are a general term for wearable devices that are intelligently designed and developed by applying wearable technology to daily wear, such as glasses, gloves, watches, clothing, and shoes. A wearable device is a portable device that is worn directly on the body or integrated into the user's clothes or accessories. Wearable devices are not only hardware devices, but also achieve powerful functions through software support, data interaction, and cloud interaction. Broadly speaking, wearable smart devices include full-featured, large-sized, and independent of smartphones to achieve complete or partial functions, such as smart watches or smart glasses, as well as devices that only focus on a certain type of application function and need to be used in conjunction with other devices such as smartphones, such as various types of smart bracelets and smart jewelry for vital sign monitoring.

[0080] In addition, in the embodiment of the present application, the user device may also be a user device in the Internet of Things (IoT) system. IoT is an important part of the future development of information technology. Its main technical feature is to connect objects to the network through communication technology, thereby realizing an intelligent network of human-machine interconnection and object-to-object interconnection. In the embodiment of the present application, IOT technology can achieve massive connections, deep coverage, and terminal power saving through narrowband (NB) technology, for example. In addition, in the embodiment of the present application, the user device may also include sensors such as smart printers, train detectors, and gas stations. The main functions include collecting data (part of the user device), receiving control information and downlink data of the access network device, and sending electromagnetic waves to transmit uplink data to the access network device.

[0081] 2. Evolved Packet Data Gateway (ePDG)

[0082] ePDG is used to ensure that UEs transmitting data use untrusted non-3GPP access technology to access the EPC. Specifically, in the initial attachment scenario where the UE accesses the core network through non-3GPP access technology, the ePDG can determine the PGW corresponding to the access point name (APN) based on the domain name system (DNS) query; or the ePDG can obtain the PGW identifier corresponding to the APN from the user's contract data, select the corresponding session management network element to establish a public data network (PDN) connection for the terminal device, and then enable the UE to establish a connection with the PGW, thereby providing the UE with corresponding operator IP services, such as IP multimedia subsystem (IMS), packet switching service (PSS), etc.

[0083] 3. Packet data network gateway (PDN Gateway)

[0084] PDN Gateway, also referred to as PGW, is a session management network element used to connect to ePDG and then establish a connection with UE, so that UE can establish a PDN connection with the network side and receive communication services provided by the network side. In addition, in the initial attachment scenario where UE accesses the core network through non-3GPP access technology, during the connection between PGW and ePDG, PGW also needs to send its own identification to the AAA server through the S6b interface between PGW and AAA server.

[0085] It should be understood that in different types of communication systems, the specific expression of "establishing a connection" is different. For example, in a 4G network, establishing a session is called establishing a PDN connection, while in a 5G network, establishing a connection is called establishing a packet data unit (PDU) session. The meaning of "establishing a connection" in the embodiments of the present application is compatible with the meaning of the corresponding expressions in the above-mentioned 4G network and 5G network.

[0086] 4. 3GPP authentication, authorization, and accounting (AAA) server

[0087] The AAA server is used to register the received PGW identity with the HSS, and is also used to bill the UE that is using network resources. The AAA server specifically refers to the authentication server, authorization server, and accounting server. It is an important device in the network, mainly used to authenticate users, authorize access to network resources, and record users' network activities.

[0088] Specifically, the functions of the AAA server include: authentication, authorization, and accounting. Authentication refers to the identity verification of users to ensure that they are legitimate network users. Authentication methods can include username and password, digital certificates, biometrics, and other methods. Authorization refers to authorizing users to determine which network resources they can access. Authorization can be based on a variety of factors such as the user's identity, role, and organization. Accounting refers to recording users' network activities, including login time, access resources, usage duration, and other information. This information can be used for network security audits, resource management, and other aspects.

[0089] AAA servers are usually used in conjunction with other network devices (such as routers, switches, firewalls, etc.) to build a network security system and ensure the security and reliability of the network. In the process of authentication and authorization, the AAA server is also used to request and obtain the corresponding user contract data from the HSS, and perform the corresponding authentication and authorization process based on the user contract data. In addition, the AAA server can also include an AAA agent, which can perform corresponding operations on behalf of the AAA server.

[0090] 5. Home Subscriber Server (HSS)

[0091] HSS is one of the core network elements in the LTE network, mainly used to store and manage user identity information and service data. For example, HSS stores user subscription data corresponding to terminal devices and transmits user subscription data through the SWx interface.

[0092] The main functions of HSS include the following aspects:

[0093] (1) User identity management: HSS stores the identity information of all users, including the user's international mobile subscriber identity (IMSI), mobile station integrated services digital network (MSISDN), international mobile equipment identity (IMEI), etc. It also includes the user's service subscription information, authentication keys, etc. Among them, IMSI includes MCC, which is used to identify the country or region to which the user belongs.

[0094] (2) Location management: HSS stores the user's location information, including the user's mobility management entity (MME) and serving GPRS support node (SGSN), so that the network can quickly find the user and provide corresponding services.

[0095] (3) Authentication and authorization: HSS is responsible for authenticating and authorizing users to ensure the legitimacy of their identities and service subscription information. It is also responsible for generating and distributing authentication keys to ensure communication security.

[0096] (4) Service data management: HSS stores user service data, including user voice, SMS, data services and other information, so that the network can provide corresponding services according to user needs. In short, HSS is a very important core network element in the LTE network. Its functions cover user identity management, location management, authentication and authorization, service data management and other aspects, providing strong support and guarantee for the network.

[0097] In some possible embodiments, the AAA server and the HSS server may be separately provided and independent of each other. In addition, the AAA server and the HSS server may be provided in one network device, which is not limited in the embodiments of the present application.

[0098] 6. Policy and charging rules function (PCRF)

[0099] PCRF is used to provide corresponding policies and charging rules for targeted communication services.

[0100] In this application, for the sake of ease of understanding and explanation, the description of "network element" is omitted in some descriptions. For example, the HSS network element is referred to as HSS. In this case, the "HSS" should be understood as the HSS network element or HSS entity. The description of the same or similar situations is omitted below. It should be noted that the above-mentioned "network element" can also be referred to as an entity, device, apparatus or module, etc., which is not specifically limited in this application.

[0101] It should be noted that Figure 1 The naming of each network element included in is just a name, and the name does not limit the function of the network element itself. In 5G networks and other future networks, the above-mentioned network elements may also have other names, and the embodiments of the present application do not specifically limit this. For example, in a 6G network, some or all of the above-mentioned network elements may use the terminology in 5G, or may be other names, etc., which are uniformly explained here and will not be repeated below.

[0102] Roaming service means that mobile terminal users (also called terminal devices) can continue to use mobile terminal services when they move to a country or region outside the home operator's network. Roaming can only be carried out between operator networks in regions or countries where the network standards are compatible and bilateral roaming agreements have been signed.

[0103] Roaming can be divided into inbound roaming and outbound roaming services. Inbound roaming refers to users of other operators' networks moving to this network to access and use mobile terminal services. Outbound roaming refers to users of this network moving to other operators' networks to access and use mobile terminal services.

[0104] Based on the physical area accessed by roaming users, roaming can be divided into national roaming and international roaming. National roaming refers to mobile terminal users accessing and using mobile terminal services on networks of other operators within the country to which their home operator network belongs. International roaming refers to mobile terminal users accessing and using mobile terminal services on networks of operators in countries other than the country to which their home operator network belongs.

[0105] When the terminal device is not roaming, the terminal device is located in the home public land mobile network (HPLMN) and enjoys the services provided by the HPLMN. Figure 1As shown, when the terminal device is in roaming state (also called roaming out), it is in a visited public land mobile network (VPLMN). The terminal device can not only access the VPLMN and enjoy the services provided by the VPLMN, but also access the HPLMN through the roaming agreement between the VPLMN and the HPLMN, and obtain the services provided by the HPLMN.

[0106] However, when the terminal device is in a roaming state and enjoys the services provided by the HPLMN, such as voice services based on WIFI (VoWIFI), the address information of the terminal device obtained by the operator of the HPLMN is a pre-configured default value. Therefore, the operator of the HPLMN cannot obtain the real location information of the terminal device, and therefore does not know that the terminal device is currently in a roaming state. Therefore, the operator of the HPLMN cannot manage the terminal device in a roaming state. For example, taking billing management as an example, when the terminal device roams out, the terminal device accesses the HPLMN to enjoy the VoWIFI service provided by the HPLMN. Since the operator of the HPLMN does not know that the terminal device is currently in a roaming state, the operator of the HPLMN still charges the terminal device according to the non-roaming charging mode, resulting in inaccurate billing.

[0107] It should be understood that the HPLMN may also be referred to as a home PLMN, which is a PLMN subscribed to by a terminal device. The VPLMN may also be referred to as a visited PLMN, which is a PLMN visited by a terminal device.

[0108] It should be noted that the MCC of the terminal device in the VPLMN refers to the country code of the mobile network operator of the VPLMN, which is used to identify the country where the mobile network operator is located. The MCC in the subscriber identity module (SIM) of the terminal device refers to the country code of the mobile network operator of the HPLMN, which is used to identify the country to which the SIM belongs.

[0109] In view of this, an embodiment of the present application provides a communication method, which can be used when a terminal device is in a roaming state and accesses the HPLMN. The authentication network element in the HPLMN can determine that the terminal device is currently in a roaming state based on the MCC reported by the terminal device, so that the operator of the HPLMN can better manage the terminal device.

[0110] The technical solutions of the embodiments of the present application can be applied to various communication systems, such as: long term evolution (LTE) system, LTE frequency division duplex (FDD) system, LTE time division duplex (TDD) system, worldwide interoperability for microwave access (WiMAX) communication system, 5G system, new radio (NR) or future network, etc. The technical solutions provided in the present application can also be applied to future communication systems, such as the sixth generation mobile communication system. The communication system can also be a land public mobile communication network (PLMN) network, a device-to-device (D2D) communication system, a machine-to-machine (M2M) communication system, an Internet of Things (IoT) communication system or other communication systems.

[0111] In an embodiment of the present application, a user device or access network device includes a hardware layer, an operating system layer running on the hardware layer, and an application layer running on the operating system layer. The hardware layer includes hardware such as a central processing unit (CPU), a memory management unit (MMU), and a memory (also called main memory). The operating system can be any one or more computer operating systems that implement business processing through a process, such as a Linux operating system, a Unix operating system, an Android operating system, an iOS operating system, or a windows operating system. The application layer includes applications such as a browser, an address book, a word processing software, and an instant messaging software. In addition, the embodiment of the present application does not specifically limit the specific structure of the execution subject of the method provided in the embodiment of the present application, as long as it can communicate according to the method provided in the embodiment of the present application by running a program that records the code of the method provided in the embodiment of the present application, for example, the execution subject of the method provided in the embodiment of the present application can be a user device or an access network device, or a functional module in a user device or an access network device that can call and execute a program.

[0112] In addition, various aspects or features of the present application can be implemented as methods, devices or products using standard programming and / or engineering techniques. The term "product" used in this application covers computer programs that can be accessed from any computer-readable device, carrier or medium. For example, computer-readable media can include, but are not limited to: magnetic storage devices (e.g., hard disks, floppy disks or tapes, etc.), optical disks (e.g., compact discs (CDs), digital versatile discs (DVDs), etc.), smart cards and flash memory devices (e.g., erasable programmable read-only memory (EPROM), cards, sticks or key drives, etc.). In addition, the various storage media described herein may represent one or more devices and / or other machine-readable media for storing information. The term "machine-readable storage medium" may include, but is not limited to, wireless channels and various other media capable of storing, containing and / or carrying instructions and / or data.

[0113] Figure 2 is a schematic flow chart of a communication method provided in an embodiment of the present application. Figure 2 As shown, the method may include steps 210-260, which are described in detail below in conjunction with steps 210-260 respectively.

[0114] Step 210: The terminal device sends the first MCC of the terminal device in the visited terrestrial public network VPLMN to the authentication network element in the HPLMN.

[0115] In an embodiment of the present application, when the terminal device is in a VPLMN, it is in a roaming state. The terminal device can send the first mobile country code (MCC) of its current location to the authentication network element in the HPLMN. The first MCC can be used to indicate the country or region where the terminal device is currently located.

[0116] Specifically, when the terminal device is in the VPLMN, it will register with the VPLMN and obtain the first MCC of the current location of the terminal device from the VPLMN. The terminal device will compare the first MCC with the MCC included in the subscription data in its SIM card. If the first MCC is different from the MCC included in the subscription data in its SIM card, it can be considered that the terminal device is currently in a roaming state, and the terminal device will send the first MCC to the authentication network element in the HPLMN.

[0117] For example, China's MCC is 460, and the United States' MCC is 310. Assume that the HPLMN is located in China and the VPLMN is located in the United States. The MCC included in the subscription data in the SIM card is 460. The first MCC sent by the terminal device to the authentication network element in the HPLMN is 310.

[0118] The present application embodiment does not specifically limit the above authentication network element, which can be at least one of the following: AAA network element, HSS network element, ePDG. For detailed description of these network elements, please refer to Figure 1 The corresponding description in will not be repeated here.

[0119] Step 220: The authentication network element determines that the terminal device is currently in roaming state based on the difference between the first MCC and the second MCC.

[0120] After receiving the first MCC sent by the terminal device, the authentication network element in the HPLMN will obtain the subscription data corresponding to the terminal device according to the identifier of the terminal device. The subscription data will include a second MCC, which is an MCC in the subscription data. The MCC is the MCC obtained when the terminal device registers with the HPLMN, and is used to identify the country or region to which the UE belongs. If the first MCC and the second MCC are different, the authentication network element can determine that the terminal device is currently in a roaming state.

[0121] Step 230: The authentication network element sends an indication message to the terminal device to allow it to access the HPLMN based on the first MCC being the MCC allowed in the subscription data.

[0122] In the embodiment of the present application, the authentication network element may allow the terminal device to access the HPLMN based on the first MCC being the MCC allowed in the subscription data, and send indication information to the terminal device to allow it to access the HPLMN.

[0123] It should be noted that the allowed MCC included in the above subscription data may be an allowed MCC list, which includes multiple allowed MCCs, and the multiple allowed MCCs are MCCs of countries or regions determined by the operator of the HPLMN that allow the terminal device to access the HPLMN.

[0124] It should also be noted that the second MCC included in the above subscription data is different from the allowed MCC list here.

[0125] In a possible implementation, the authentication network element is an HSS network element. The HSS network element stores the subscription data of the terminal device, which includes a list of allowed MCCs. The HSS network element can determine whether to allow the terminal device to access the HPLMN based on whether the MCC reported by the terminal device is included in the list of allowed MCCs in the subscription data.

[0126] In another possible implementation, the authentication network element is an AAA network element or an ePDG. The HSS network element will send the saved subscription data of the terminal device to the AAA network element or the ePDG. One possible implementation is: the AAA or the ePDG requests the subscription data from the HSS, and the SS network element will send the saved subscription data of the terminal device to the AAA network element or the ePDG. The AAA network element or the ePDG can determine, based on the received subscription data, that the MCC reported by the terminal device is included in the list of MCCs allowed by the subscription data, thereby determining that the terminal device is allowed to access the HPLMN.

[0127] Step 240: After receiving the indication information allowing the terminal device to access the HPLMN, the terminal device can access the HPLMN.

[0128] In the embodiment of the present application, after receiving the indication information that allows the terminal device to access the HPLMN, the terminal device can access the HPLMN and obtain corresponding services from the HPLMN. At this time, since the terminal device is in a roaming state, the charging strategy adopted by the operator of the HPLMN for the terminal device after the terminal device accesses the HPLMN is different from the charging strategy when the terminal device is in a non-roaming state. For example, after the terminal device accesses the HPLMN, the operator of the HPLMN charges the terminal device at a higher standard than when the terminal device is in a non-roaming state.

[0129] In a possible implementation, the authentication network element is an HSS network element. The HSS network element stores the subscription data of the terminal device, which includes a list of allowed MCCs. The HSS network element can determine that the terminal device is not allowed to access the HPLMN based on the fact that the MCC reported by the terminal device is not included in the list of allowed MCCs in the subscription data.

[0130] In another possible implementation, the authentication network element is an AAA network element or an ePDG. The HSS network element will send the saved subscription data of the terminal device to the AAA network element or the ePDG. One possible implementation is: the AAA or the ePDG requests the subscription data from the HSS, and the SS network element will send the saved subscription data of the terminal device to the AAA network element or the ePDG. The AAA network element or the ePDG can determine, based on the received subscription data, that the MCC reported by the terminal device is not included in the list of MCCs allowed by the subscription data, thereby determining that the terminal device is not allowed to access the HPLMN.

[0131] In the embodiment of the present application, the services obtained by the terminal device from the HPLMN may include but are not limited to: voice over wireless fidelity (VOWIFI) service, voice over long-term evolution (VOLTE) service, MMS, etc.

[0132] Step 250: The authentication network element sends an indication message to the terminal device not to allow the terminal device to access the HPLMN based on the fact that the first MCC is not the MCC allowed in the subscription data.

[0133] In the embodiment of the present application, the authentication network element may not allow the terminal device to access the HPLMN based on the fact that the first MCC is not the MCC allowed in the subscription data, and send indication information to the terminal device that does not allow it to access the HPLMN.

[0134] In the embodiment of the present application, when the authentication network element determines that the terminal device is not allowed to access the HPLMN, the indication information may further include an error code, where the error code is used to indicate that the received first MCC is not the MCC allowed in the subscription data. The error code may inform the terminal device of the reason why it is not allowed to access the HPLMN, thereby avoiding multiple attempts to access the HPLMN when the MCC at the current location of the terminal device has not changed, thereby avoiding waste of resources.

[0135] Step 260: After receiving the indication information that the terminal device is not allowed to access the HPLMN, it will not receive services from the HPLMN.

[0136] In the embodiment of the present application, if the authentication network element does not allow the terminal device to access the HPLMN, after the terminal device receives the indication information that does not allow it to access the HPLMN, it will not access the HPLMN and will not receive services from the HPLMN.

[0137] As an example, if the indication information received by the terminal device includes the error code, the terminal device can learn the reason why it cannot access the HPLMN through the error code, avoiding multiple attempts to access the HPLMN when the MCC of the terminal device's current location has not changed, thereby avoiding waste of resources.

[0138] Optionally, in some embodiments, after the terminal device receives indication information that it is not allowed to access the HPLMN, if the terminal device subsequently determines that the MCC of its location has changed compared to the first MCC sent to the authentication network element last time, the terminal device will again attempt to send a new MCC to the authentication network element in the HPLMN to request to access the HPLMN again. In this way, if the changed MCC is the MCC allowed by the contract data of the terminal device, then the terminal device can access the HPLMN in time at this time. The implementation method is the same as the process in step 210. The terminal device sends the current new MCC of the terminal device to the authentication network element in the HPLMN. For details, please refer to the description in step 210, which will not be repeated here.

[0139] Optionally, in some embodiments, the terminal device can obtain a list of MCCs allowed by the subscription data. After the terminal device receives indication information that it is not allowed to access the HPLMN, if the terminal device subsequently determines that the MCC at its location is included in the list of MCCs allowed by the subscription data, the terminal device will again attempt to send a new MCC to the authentication network element in the HPLMN to request access to the HPLMN again. In this way, if the changed MCC is the MCC allowed by the subscription data of the terminal device, the terminal device can access the HPLMN in a timely manner. The implementation method is the same as the process in step 210. The terminal device sends the current new MCC of the terminal device to the authentication network element in the HPLMN. For details, please refer to the description in step 210, which will not be repeated here.

[0140] In the above technical solution, the authentication network element in the HPLMN determines that the terminal device is currently in a roaming state by comparing the MCC of the current location reported by the terminal device with the MCC included in the contract data of the terminal device. If the MCC of the current location reported by the terminal device is the MCC allowed in the contract data, the authentication network element can allow it to access the HPLMN. At this time, the charging strategy adopted for the terminal device is different from the charging strategy when the terminal device is in a non-roaming state; if the MCC of the current location reported by the terminal device is not the MCC allowed in the contract data, the authentication network element can prohibit it from accessing the HPLMN, so that the operator of the HPLMN can better manage the terminal devices in a roaming state.

[0141] The following takes the above authentication network element as an HSS network element as an example. Figure 3 , a specific implementation of the communication method provided in the embodiment of the present application is described in detail. It should be understood that Figure 3 The examples are only intended to help those skilled in the art understand the embodiments of the present application, and are not intended to limit the embodiments of the present application to Figure 3The specific numerical values ​​or specific scenarios shown in the examples. Figure 3 The examples given below are obviously susceptible to various equivalent modifications or changes, and such modifications and changes also fall within the scope of the embodiments of the present application.

[0142] Figure 3 FIG. 1 is a schematic flow chart of another communication method provided in an embodiment of the present application. Figure 3 As shown, the method may include steps 310-350, which are described in detail below in conjunction with steps 310-350 respectively.

[0143] As an example, if the UE is not located in its registered country and the ePDG selected by the UE is in the HPLMN, the UE shall also provide the MCC information of the UE's current country by including the MCC_EPDG Notification payload in a new IKE_AUTH Request message (IKE_AUTH Request), including the EAP-Response / AKA-Challenge (EAP-Response / AKA-Challenge).

[0144] For ease of description, the following Figure 3 The communication device is taken as UE as an example.

[0145] It should be understood that Figure 3 It includes UE, ePDG, AAA network element, and HSS network element, wherein the UE is located in the VPLMN, and the ePDG, AAA and HSS are located in the HPLMN.

[0146] Step 310: The UE negotiates an encryption algorithm with the AAA network element / HSS network element, exchanges random numbers, and generates an authentication vector (AV).

[0147] It should be understood that the detailed process of step 310 can be referred to section 8.2.2 of TS 33.402 version 18.0.0, which will not be repeated here.

[0148] Step 315: The UE sends an authentication request to the ePDG.

[0149] The mobile country code (MCC) of the location where the UE is roaming.

[0150] Step 315 may refer to the relevant description in step 210. Specifically, when the UE is in a roaming state (located in a VPLMN), the UE may send an authentication request to the ePDG in the HPLMN, and the authentication request may include the MCC where the UE is located. In a roaming scenario, the UE may inform the ePDG of its location information to facilitate subsequent authentication and billing management processes.

[0151] As an example, the UE may send the MCC of the location of the UE to the ePDG in the HPLMN through an IKE_AUTH Request message.

[0152] It should be noted that, for details on how the UE determines whether it is currently in a roaming state, please refer to the method in step 210, which will not be repeated here.

[0153] Step 320: The ePDG sends an authentication certificate to AAA.

[0154] Step 320 may refer to the relevant description in step 210, where the UE sends the MCC of the UE's location to the AAA through the ePDG. Specifically, after the ePDG receives the MCC of the UE's location, it may send an authentication message to the AAA, which also includes the MCC of the UE's location. As an example, the authentication message is an Authentication&AuthorizationRequest message.

[0155] The ePDG may inform AAA of the location information of the UE in a roaming scenario, so that AAA can perform authentication and billing management on the UE.

[0156] Step 325: AAA authenticates the UE according to the authentication algorithm and the MCC where the UE is located.

[0157] In the embodiment of the present application, after AAA receives the authentication message sent by the ePDG, it can authenticate the UE according to the authentication algorithm and the MCC of the UE's location carried in the message.

[0158] If the authentication is successful, the AAA sends the MCC of the location of the UE to the HSS. As an example, the AAA sends the MCC of the location of the UE to the HSS via an Authentication Request message.

[0159] Step 327: AAA sends an authentication certificate to HSS.

[0160] In the embodiment of the present application, AAA sends an authentication message to the HSS, and the authentication message includes the MCC where the UE is located.

[0161] Step 330: HSS determines whether the MCC sent by AAA is in the subscription data.

[0162] The relevant description in step 330 is the relevant description in step 230 or step 250. Specifically, an allowed MCC list is added in the HSS subscription, and the allowed MCC list includes multiple MCCs, and the multiple MCCs are MCCs that the operator of the HPLMN allows to provide services. The allowed MCC list is used to authenticate the received MCC.

[0163] In the embodiment of the present application, the operator of the HPLMN takes measures to restrict access to the MCC of the country where the UE roams out, and the country (MCC) not in the contract data restricts the use of HPLMN services, which facilitates the operator of the HPLMN to perform billing management on the UE in the roaming state.

[0164] As an example, the HSS receives an Authentication Request message sent by the AAA, the Authentication Request message including the MCC where the UE is located. The HSS determines whether the UE is allowed to access the service of the HPLMN according to whether the received MCC is in the allowed MCC list.

[0165] In one possible implementation, if the MCC received by the HSS is in the above-mentioned allowed MCC list, the HSS sends a result code (Result Code) of successful authentication to the AAA, and the ePDG in the HPLMN can provide services for the UE. In another possible implementation, if the MCC received by the HSS is not in the above-mentioned allowed MCC list, the HSS sends a newly defined error code, such as DIAMETER_ERROR_MCC_NOT_ALLOWED.

[0166] Step 335: AAA receives the authentication response sent by HSS.

[0167] In one possible implementation, if the HSS determines that the MCC at the location of the UE is included in the list of allowed MCCs, the AAA will receive the Result Code of successful authentication sent by the HSS. In another possible implementation, if the HSS determines that the MCC at the location of the UE is not in the list of allowed MCCs, the AAA will receive an error code sent by the HSS, such as DIAMETER_ERROR_MCC_NOT_ALLOWED.

[0168] As an example, the HSS may send a Result Code indicating successful authentication or a newly defined error code to the AAA via an Authentication Response message.

[0169] Step 340: AAA sends an authentication response to the ePDG.

[0170] As an example, AAA may send the authentication result to the ePDG via an Authentication&Authorization Response message, where the authentication result includes a Result Code indicating successful authentication or a newly defined error code.

[0171] Step 345: The ePDG uses the master session key (MSK) to generate AUTH parameters and sends them to the UE.

[0172] It should be understood that in order to authenticate the IKE_SA_INIT message initially exchanged between the ePDG and the UE, the ePDG uses the MSK to generate the AUTH parameter and sends it to the UE. The MSK is a shared key generated in the extensible authentication protocol (EAP) exchange and is used to generate the AUTH parameter when used on the Internet Key Exchange Version 2 (IKEv2).

[0173] As an example, the ePDG sends the AUTH parameters to the UE via an IKE_AUTH Response message. After receiving the IKE_AUTH Response message, the UE runs an authentication and key agreement (AKA) algorithm, verifies the AUTH parameters, and generates an MSK.

[0174] It should be understood that in the event that the authentication response indicates that the UE is not allowed to access services using the HPLMN, step 345 is optional.

[0175] Step 350: The ePDG sends an authentication response to the UE.

[0176] Step 350 may refer to the relevant description in step 240 or step 260. Specifically, if the authentication is successful, the UE will receive the service provided by the ePDG. If the authentication is not successful, the UE will receive an error code, such as DIAMETER_ERROR_MCC_NOT_ALLOWED.

[0177] As an example, the ePDG sends the authentication result to the UE through an IKE_AUTH Response message.

[0178] It should be noted that the MCC list allowed for HSS user subscription data. When the UE is located in the VPLMN and selects the HPLMN's ePDG to use the VoWIFI service, the UE needs to carry the MCC of its current location and send it to the ePDG, and the ePDG needs to send the MCC to the AAA / HSS for authentication and authorization:

[0179] When the HSS receives the MCC of the UE's current location via the ePDG, the HSS shall check whether the MCC is included in the allowed MCC list:

[0180] If the MCC is not included in the allowed MCC list, the HSS shall return a newly defined error code DIAMETER_ERROR_MCC_NOT_ALLOWED to the 3GPP-AAA server;

[0181] If the MCC is included in the list of allowed MCCs, the HSS shall set the user status of the authenticated and authorized trusted or untrusted non-3GPP IP access user to registered, download the relevant user profile information, and set the result code to DIAMETER_SUCCESS in the Server-Assignment-Response command.

[0182] The above is combined Figures 1 to 3 The technical solution provided by the communication method of the embodiment of the present application is described in detail. Figures 4 to 6 The communication device provided in the embodiment of the present application is introduced.

[0183] Figure 4 4 is a schematic block diagram of an authentication network element 400 provided in an embodiment of the present application. Figure 4As shown, the network element 400 may include a receiving module 410, a processing module 420, and a sending module 430. The receiving module 410 is used to receive an authentication request message sent by a communication device, wherein the authentication request message includes a first mobile country code MCC of the current location of the communication device, and the first MCC is used to indicate the country or region where the communication device is currently located; the processing module 420 is used to determine that the communication device is currently in a roaming state according to the difference between the first MCC and the second MCC, and the second MCC is the MCC used to identify the country or region to which the communication device belongs in the subscription data of the communication device; the sending module 430 is used to send a roaming request to the communication device according to the first MCC and the MCC allowed in the subscription data. The device sends an authentication response message, the authentication response message including indication information, the indication information being used to indicate whether the communication device is allowed to access the HPLMN; if the first MCC is the MCC allowed in the subscription data, the indication information indicates that the communication device is allowed to access the home terrestrial public network HPLMN, and the charging strategy adopted by the operator of the HPLMN for the communication device is different from the charging strategy when the communication device is in a non-roaming state; or if the first MCC is not the MCC allowed in the subscription data, the indication information indicates that the communication device is not allowed to access the home terrestrial public network HPLMN.

[0184] Optionally, the authentication network element is a home subscriber server HSS, and the HSS stores the subscription data, which includes an allowed MCC list.

[0185] Optionally, the authentication network element is an evolved packet data gateway ePDG or an authentication and accounting AAA network element, and the receiving module is further used to receive the subscription data from the HSS, where the subscription data includes an allowed MCC list.

[0186] Optionally, if the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, where the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

[0187] Optionally, when the authentication network element uses the first MCC as the MCC allowed in the subscription data, the charging price for the communication device by the operator of the HPLMN is higher than the charging price when the communication device is in a non-roaming state.

[0188] Figure 5 is a schematic block diagram of a communication device 500 provided in an embodiment of the present application. Figure 5As shown, the device 500 may include a sending module 510, a receiving module 520, and a processing module 530. The sending module 510 is used to send an authentication request message to an authentication and verification network element in a home terrestrial public network HPLMN when the communication device is in a roaming state, wherein the authentication request message includes a first mobile country code MCC of the current location of the communication device, and the first MCC is used to indicate the country or region where the communication device is currently located; the receiving module 520 is used to receive an authentication response message sent by the authentication and verification network element, wherein the authentication response message includes indication information, and the indication information is used to indicate whether the communication device is allowed to access the HPLMN; the processing module 530 is used to, if the indication information indicates that the communication device is allowed to access the HPLMN, access the HPLMN, and the charging strategy adopted by the operator of the HPLMN for the communication device is different from the charging strategy when the communication device is in a non-roaming state; or the processing module is used to, if the indication information indicates that the communication device is not allowed to access the HPLMN, not access the HPLMN.

[0189] Optionally, the processing module 530 is further used to determine that the communication device is currently in a roaming state according to the first MCC and the second MCC being different, and the second MCC is the MCC used to identify the country or region to which the communication device belongs in the contract data in the user identification card SIM card of the communication device.

[0190] Optionally, the authentication network element is at least one of the following: an authentication and accounting AAA network element, a home subscriber server HSS network element, and an evolved packet data gateway ePDG.

[0191] Optionally, if the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, where the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

[0192] Optionally, when the communication device accesses the HPLMN, the charging price charged by the operator of the HPLMN to the communication device is higher than the charging price when the communication device is in a non-roaming state.

[0193] The functions of the network element 400 or the device 500 described above can be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the functions described above; for example, the transceiver module can be replaced by a transceiver (for example, the sending module in the transceiver module can be replaced by a transmitter, and the receiving module in the transceiver module can be replaced by a receiver), and other modules, such as the processing module, can be replaced by a processor to respectively perform the sending and receiving operations and related processing operations in each method embodiment.

[0194] It should be understood that the network element 400 or the device 500 here is embodied in the form of a functional unit. The term "unit" here may refer to an application specific integrated circuit (ASIC), an electronic circuit, a processor (such as a shared processor, a dedicated processor or a group processor, etc.) and a memory for executing one or more software or firmware programs, a combined logic circuit and / or other suitable components that support the described functions.

[0195] In addition, the above-mentioned transceiver module can also be a transceiver circuit (for example, it can include a receiving circuit and a sending circuit), and the processing module can be a processing circuit. In an embodiment of the present application, the device 500 can be a terminal device in the aforementioned embodiment, or a chip or a chip system, for example: a system on chip (SoC). The network element 400 can be an authentication network element in the aforementioned embodiment, or a chip or a chip system. Among them, the transceiver module can be an input and output circuit, a communication interface. The processing module is a processor or a microprocessor or an integrated circuit integrated on the chip. This is not limited here.

[0196] Figure 6 is another schematic structural diagram of a communication device provided in an embodiment of the present application. Figure 6 As shown, the communication device 600 includes: at least one processor 610, the processor 610 is used to execute instructions so that the above Figure 2-Figure 3 The method shown can be implemented.

[0197] Optionally, the device 600 may further include a transceiver 620, where the transceiver 620 is used to send signals and / or receive signals.

[0198] Optionally, the communication device 600 further includes a memory 630 for storing instructions. The processor 610 is coupled to the memory and is configured to execute the instructions stored in the memory to control the transceiver 620 to send and / or receive signals.

[0199] It should be understood that the processor 610 and the memory 630 can be combined into one processing device, and the processor 610 is used to execute the program code stored in the memory 630 to implement the above functions. In specific implementation, the memory 630 can also be integrated into the processor 610, or independent of the processor 610.

[0200] It should also be understood that the transceiver 620 may include a receiver (or receiver) and a transmitter (or transmitter). The transceiver 620 may further include an antenna, and the number of antennas may be one or more. The transceiver 620 may also be a communication interface or an interface circuit.

[0201] When the communication device 600 is a chip, the chip includes a transceiver unit and a processing unit, wherein the transceiver unit may be an input / output circuit or a communication interface; and the processing unit may be a processor or a microprocessor or an integrated circuit integrated on the chip.

[0202] The present application also provides a processing device, including a processor and an interface. The processor can implement the method in the above method embodiment.

[0203] It should be understood that the above-mentioned processing device can be a chip. For example, the processing device can be a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on chip (SoC), a central processor unit (CPU), a network processor (NP), a digital signal processor (DSP), a micro controller unit (MCU), a programmable logic device (PLD) or other integrated chips.

[0204] In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware in a processor or an instruction in the form of software. The steps of the method disclosed in conjunction with the embodiment of the present application can be directly embodied as a hardware processor for execution, or a combination of hardware and software modules in a processor for execution. The software module can be located in a storage medium mature in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in a memory, and the processor reads the information in the memory and completes the steps of the above method in conjunction with its hardware. To avoid repetition, it is not described in detail here.

[0205] An embodiment of the present application also provides a communication system, which includes the aforementioned communication device and an authentication network element.

[0206] The present application also provides a computer-readable storage medium in which instructions are stored. When the instructions are executed on a computer, the computer executes the above-mentioned Figure 2-Figure 3 The various steps in the method shown.

[0207] The present application also provides a computer program product comprising instructions, which, when executed on a computer, causes the computer to execute the following Figure 2-3 The various steps in the method shown.

[0208] The present application also provides a chip, including a processor. The processor is used to read and run a computer program stored in a memory to execute the corresponding operations and / or processes performed in the method provided in the present application. In a possible implementation, the chip also includes a memory, the memory and the processor are connected to the memory through a circuit or wire, and the processor is used to read and execute the computer program in the memory. Further in a possible implementation, the chip also includes a communication interface, and the processor is connected to the communication interface. The communication interface is used to receive processed data and / or information, and the processor obtains the data and / or information from the communication interface and processes the data and / or information. The communication interface can be an input / output interface, an interface circuit, an output circuit, an input circuit, a pin or a related circuit on the chip. The processor can also be embodied as a processing circuit or a logic circuit.

[0209] The present application also provides a chip, including a processor. The processor is used to read and run a computer program stored in a memory to perform the corresponding operations and / or processes provided by the present application. In a possible implementation, the chip also includes a memory, which is connected to the processor through a circuit or wire, and the processor is used to read and execute the computer program in the memory. Further in a possible implementation, the chip also includes a communication interface, and the processor is connected to the communication interface. The communication interface is used to receive processed data and / or information, and the processor obtains the data and / or information from the communication interface and processes the data and / or information. The communication interface can be an input / output interface, an interface circuit, an output circuit, an input circuit, a pin or a related circuit on the chip. The processor can also be embodied as a processing circuit or a logic circuit.

[0210] The above-mentioned chip can also be replaced by a chip system, which will not be described here.

[0211] The terms "including" and "having" and any variations thereof in this application are intended to cover non-exclusive inclusions. For example, a process, method, system, product or apparatus comprising a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to these processes, methods, products or apparatuses.

[0212] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0213] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0214] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0215] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0216] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0217] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0218] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A communication method, characterized in that: include: The authentication network element receives an authentication request message sent by a communication device, wherein the authentication request message includes a first mobile country code MCC of a current location of the communication device, wherein the first MCC is used to indicate a country or region where the communication device is currently located; The authentication network element determines that the communication device is currently in a roaming state according to that the first MCC and the second MCC are different, and the second MCC is an MCC in the subscription data of the communication device used to identify the country or region to which the communication device belongs; The authentication network element sends an authentication response message to the communication device according to the first MCC and the MCC allowed in the subscription data, wherein the authentication response message includes indication information, and the indication information is used to indicate whether the communication device is allowed to access a home terrestrial public network HPLMN; If the first MCC is an MCC allowed in the subscription data, the indication information indicates that the communication device is allowed to access the HPLMN, and the charging policy adopted by the operator of the HPLMN for the communication device is different from the charging policy when the communication device is in a non-roaming state; or If the first MCC is not an MCC allowed in the subscription data, the indication information indicates that the communication device is not allowed to access a home terrestrial public network HPLMN.

2. The method according to claim 1, characterized in that The authentication network element is a home subscriber server HSS, and the HSS stores the subscription data, wherein the subscription data includes an allowed MCC list.

3. The method according to claim 1, characterized in that The authentication network element is an evolved packet data gateway ePDG or an authentication, authentication and billing AAA network element, and the method further includes: The authentication network element receives the subscription data from the HSS, where the subscription data includes an allowed MCC list.

4. The method according to any one of claims 1 to 3, characterized in that If the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, where the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

5. The method according to any one of claims 1 to 4, characterized in that When the authentication network element uses the first MCC as the MCC allowed in the subscription data, the charging price charged by the operator of the HPLMN to the communication device is higher than the charging price when the communication device is in a non-roaming state.

6. A communication method, characterized in that: include: When the communication device is in a roaming state, the communication device sends an authentication request message to an authentication and certification network element in a home terrestrial public network HPLMN, wherein the authentication request message includes a first mobile country code MCC of a current location of the communication device, wherein the first MCC is used to indicate a country or region where the communication device is currently located; The communication device receives an authentication response message sent by the authentication network element, wherein the authentication response message includes indication information, and the indication information is used to indicate whether the communication device is allowed to access the HPLMN; If the indication information indicates that the communication device is allowed to access the HPLMN, the communication device accesses the HPLMN, and the charging policy adopted by the operator of the HPLMN for the communication device is different from the charging policy when the communication device is in a non-roaming state; or If the indication information indicates that the communication device is not allowed to access the HPLMN, the communication device does not access the HPLMN.

7. The method according to claim 6, characterized in that The communication device being in roaming state includes: The communication device determines that the communication device is currently in a roaming state according to the difference between the first MCC and the second MCC, where the second MCC is the MCC used to identify the country or region to which the communication device belongs in the subscription data in the user identification card SIM card of the communication device.

8. The method according to claim 6 or 7, characterized in that: The authentication network element is at least one of the following: an authentication and accounting AAA network element, a home subscriber server HSS network element, and an evolved packet data gateway ePDG.

9. The method according to any one of claims 6 to 8, characterized in that If the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, where the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

10. The method according to any one of claims 6 to 9, characterized in that When the communication device accesses the HPLMN, the charging price charged by the operator of the HPLMN to the communication device is higher than the charging price when the communication device is in a non-roaming state.

11. An authentication network element, characterized in that: include: A receiving module, configured to receive an authentication request message sent by a communication device, wherein the authentication request message includes a first mobile country code MCC of a current location of the communication device, wherein the first MCC is used to indicate a country or region where the communication device is currently located; a processing module, configured to determine that the communication device is currently in a roaming state according to that the first MCC and a second MCC are different, wherein the second MCC is an MCC in the subscription data of the communication device and is used to identify the country or region to which the communication device belongs; a sending module, configured to send an authentication response message to the communication device according to the first MCC and the MCC allowed in the subscription data, wherein the authentication response message includes indication information, and the indication information is used to indicate whether the communication device is allowed to access the HPLMN; If the first MCC is an MCC allowed in the subscription data, the indication information indicates that the communication device is allowed to access a home land public network HPLMN, and a charging policy adopted by an operator of the HPLMN for the communication device is different from a charging policy when the communication device is in a non-roaming state; or If the first MCC is not an MCC allowed in the subscription data, the indication information indicates that the communication device is not allowed to access a home terrestrial public network HPLMN.

12. The network element according to claim 11, characterized in that: The authentication network element is a home subscriber server HSS, and the HSS stores the subscription data, wherein the subscription data includes an allowed MCC list.

13. The network element according to claim 11, characterized in that: The authentication network element is an evolved packet data gateway ePDG or an authentication and accounting AAA network element, The receiving module is further configured to receive the subscription data from the HSS, where the subscription data includes an allowed MCC list.

14. The network element according to any one of claims 11 to 13, characterized in that: If the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, where the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

15. The network element according to any one of claims 11 to 14, characterized in that: When the authentication network element uses the first MCC as the MCC allowed in the subscription data, the charging price charged by the operator of the HPLMN to the communication device is higher than the charging price when the communication device is in a non-roaming state.

16. A communication device, characterized in that: include: a sending module, configured to send an authentication request message to an authentication and certification network element in a home terrestrial public network HPLMN when the communication device is in a roaming state, wherein the authentication request message includes a first mobile country code MCC of a current location of the communication device, wherein the first MCC is used to indicate a country or region where the communication device is currently located; A receiving module, configured to receive an authentication response message sent by the authentication network element, wherein the authentication response message includes indication information, and the indication information is used to indicate whether the communication device is allowed to access the HPLMN; a processing module, configured to, if the indication information indicates that the communication device is allowed to access the HPLMN, access the HPLMN, and the charging policy adopted by the operator of the HPLMN for the communication device is different from the charging policy when the communication device is in a non-roaming state; or The processing module is configured to not access the HPLMN if the indication information indicates that the communication device is not allowed to access the HPLMN.

17. The device according to claim 16, characterized in that The processing module is further used to determine that the communication device is currently in a roaming state according to that the first MCC and the second MCC are different, and the second MCC is the MCC used to identify the country or region to which the communication device belongs in the subscription data in the user identification card SIM card of the communication device.

18. The device according to claim 16 or 17, characterized in that The authentication network element is at least one of the following: an authentication and accounting AAA network element, a home subscriber server HSS network element, and an evolved packet data gateway ePDG.

19. The device according to any one of claims 16 to 18, characterized in that If the indication information indicates that the communication device is not allowed to access the HPLMN, the indication information includes an error code, where the error code is used to indicate that the first MCC is not an MCC allowed in the subscription data.

20. The device according to any one of claims 16 to 19, characterized in that When the communication device accesses the HPLMN, the charging price charged by the operator of the HPLMN to the communication device is higher than the charging price when the communication device is in a non-roaming state.

21. An authentication network element, characterized in that: include: Memory for storing computer programs; A processor, configured to execute the computer program stored in the memory so that the communication device executes the method according to any one of claims 1 to 5.

22. A communication device, characterized in that: include: Memory for storing computer programs; A processor, configured to execute the computer program stored in the memory so that the communication device executes the method according to any one of claims 6 to 10.

23. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed, the communication device executes the method according to any one of claims 1 to 5, or executes the method according to any one of claims 6 to 10.