WO2019096265A1 - Method and device for requesting connection recovery - Google Patents

Method and device for requesting connection recovery Download PDF

Info

Publication number
WO2019096265A1
WO2019096265A1 PCT/CN2018/116000 CN2018116000W WO2019096265A1 WO 2019096265 A1 WO2019096265 A1 WO 2019096265A1 CN 2018116000 W CN2018116000 W CN 2018116000W WO 2019096265 A1 WO2019096265 A1 WO 2019096265A1
Authority
WO
WIPO (PCT)
Prior art keywords
terminal
base station
message
authentication code
context
Prior art date
Application number
PCT/CN2018/116000
Other languages
French (fr)
Chinese (zh)
Inventor
胡力
李秉肇
陈璟
耿婷婷
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Priority claimed from CN201810149050.4A external-priority patent/CN109803258B/en
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to ES18879002T priority Critical patent/ES2928106T3/en
Priority to KR1020207017141A priority patent/KR102354626B1/en
Priority to EP18879002.6A priority patent/EP3713271B1/en
Priority to RU2020119591A priority patent/RU2772617C2/en
Priority to EP22186005.9A priority patent/EP4152790A1/en
Priority to BR112020009673-3A priority patent/BR112020009673A2/en
Priority to AU2018366755A priority patent/AU2018366755B2/en
Publication of WO2019096265A1 publication Critical patent/WO2019096265A1/en
Priority to US16/874,117 priority patent/US11627623B2/en
Priority to US18/185,762 priority patent/US20230292388A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/04Key management, e.g. using generic bootstrapping architecture [GBA]

Definitions

  • the present application relates to the field of mobile communications technologies, and in particular, to a method and apparatus for requesting to restore a connection.
  • the suspend and resume process can be used for narrowband internet of things (NB-IoT) terminals, ie, IoT devices with low mobility or low power consumption.
  • NB-IoT narrowband internet of things
  • IoT devices with low mobility or low power consumption.
  • the terminal and the base station When the base station informs the terminal to release the current connection in a suspended manner, the terminal and the base station delete the context of the part of the access layer, and also retain the context of the part of the access layer, such as the access layer key, the security capability of the terminal, and the current Selected security algorithms, etc.
  • the terminal then enters an inactive state from the connected state. When the terminal wishes to resume the connection with the base station, it can quickly recover from the inactive state to the connected state.
  • the above service flow can be extended to apply the suspend and resume process to an enhanced mobile broadband (eMBB) terminal such as a smart phone.
  • eMBB enhanced mobile broadband
  • the base station to which the terminal is connected may change. Further, when the base station serves the terminal, a scenario of load balancing is considered. For example, when the terminal requests to recover from the inactive state to the connected state, if the load of the base station that the terminal currently wants to access is heavy, the base station will reject the access of the terminal, that is, reject the connection recovery request of the terminal. And notify the terminal to rest for a while before trying to connect.
  • the authentication information sent by the terminal may be acquired by the attacker, and then the attacker uses the obtained authentication information to request the connection to establish a connection. May cause an attack.
  • the present application provides a method and apparatus for requesting a recovery connection to effectively defend against an attacker's attack.
  • the present application provides a method for requesting a connection to restore, comprising: generating, by a terminal, a message authentication code according to a freshness parameter and an integrity protection key of the terminal, where the message authentication code is generated by two adjacent messages.
  • the freshness parameter is different; the terminal sends a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, and the connection recovery request message is used to request to resume the radio resource control RRC connection.
  • the attack Since the message authentication code generated by the terminal is different from the message authentication code generated last time, even if the attacker steals the message authentication code used by the terminal last time, due to the "expired" message authentication code used, the attack is Will not be able to attack successfully.
  • the freshness parameter includes a number of rejections, and the number of rejections is used to indicate the number of times the terminal is rejected when attempting to resume the RRC connection.
  • the connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
  • the freshness parameter includes a packet data convergence protocol count PDCP COUNT, the indication parameter including some or all of the bits of the PDCP COUNT.
  • the terminal receives a connection recovery response message from the target base station, where the connection recovery response message is used to instruct the terminal to resume the RRC connection.
  • the present application provides a method for requesting a connection to restore, comprising: receiving, by a target base station, a connection recovery request message from a terminal, where the connection recovery request message includes a message authentication code, and the connection recovery request message is used to request to resume wireless
  • the resource control RRC connection the message authentication code is generated according to the integrity protection key of the terminal; if the target base station refuses to restore the RRC connection, sending a notification message to the source base station, where the notification message includes The message authentication code.
  • the notification message has one or more of the following functions:
  • the notification message is used to notify the update of the context of the terminal in the source base station;
  • the notification message is used to notify the target base station that the terminal is refused to resume the connection;
  • the notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
  • the notification message is used to notify the key of updating the context of the terminal in the source base station.
  • the source base station when the target base station refuses to restore the RRC connection, the source base station is further notified to update the context of the terminal, so that the context between the terminal and the source base station can be kept consistent, which helps reduce the probability of the terminal entering the connected state from the inactive state.
  • the notification message notifies that the updated context of the terminal includes an access layer key.
  • the freshness parameter includes a number of rejections, and the number of rejections is used to indicate the number of times the terminal is rejected when attempting to resume the RRC connection.
  • the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where the notification message notifies that the updated context of the terminal includes the freshness parameter
  • the freshness parameters used to generate the message authentication code two times are different.
  • connection recovery request message further includes an indication parameter
  • the indication parameter is used to indicate the freshness parameter
  • the notification message further includes the indication parameter.
  • the freshness parameter includes a PDCP COUNT
  • the indication parameter including some or all of the bits of the PDCP COUNT.
  • the present application provides a method for requesting a connection to restore, comprising: receiving, by a target base station, a connection recovery request message from a terminal, where the connection recovery request message includes a message authentication code, and the message authentication code is based on a freshness parameter and The integrity protection key of the terminal is generated, wherein the freshness parameter used by the two adjacent generation message authentication codes is different, and the connection recovery request message is used to request to restore the radio resource control RRC connection; the target base station If the RRC connection is restored, the context request message is sent to the source base station, where the context request message includes the message authentication code, and the context request message is used to request to acquire the context of the terminal.
  • the freshness parameter includes a number of rejections, and the number of rejections is used to indicate the number of times the terminal is rejected when attempting to resume the RRC connection.
  • connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, and the context request message further includes the indication parameter.
  • the freshness parameter includes a packet data convergence protocol PDCP count COUNT, the indication parameter including some or all of the bits of the PDCP COUNT.
  • the application provides a method for requesting to restore a connection, including: receiving, by a source base station, a notification message from a target base station, where the notification message includes a message authentication code, and the message authentication code is based on integrity protection of the terminal. Key generated
  • the source base station verifies the message authentication code according to the integrity protection key of the source base station
  • the source base station when the target base station refuses to restore the RRC connection, the source base station is further notified to update the context of the terminal, so that the source base station updates the context of the terminal, so that the source base station remains consistent with the context of the terminal, which helps to reduce the terminal from entering the inactive state.
  • the probability of failure of the connected state when the target base station refuses to restore the RRC connection, the source base station is further notified to update the context of the terminal, so that the source base station updates the context of the terminal, so that the source base station remains consistent with the context of the terminal, which helps to reduce the terminal from entering the inactive state. The probability of failure of the connected state.
  • the notification message has one or more of the following functions:
  • the notification message is used to notify the update of the context of the terminal in the source base station;
  • the notification message is used to notify the target base station that the terminal is refused to resume the connection;
  • the notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
  • the notification message is used to notify the key of updating the context of the terminal in the source base station.
  • the freshness parameter includes a number of rejections, and the number of rejections is used to indicate the number of times the terminal is rejected when attempting to resume the RRC connection.
  • the source base station updates a context of the terminal in the source base station, including: the source base station increments a number of rejections of a context of the terminal by one.
  • the source base station updates a context of the terminal in the source base station, where the source base station updates an access layer key in a context of the terminal.
  • the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where a freshness parameter used by generating a message authentication code twice is different; And verifying, by the source base station, the message authentication code according to the integrity protection key of the source base station, where the source base station performs verification according to the freshness parameter and the integrity protection key of the source base station.
  • the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where a freshness parameter used by generating a message authentication code twice is different; And verifying, by the source base station, the message authentication code according to the integrity protection key of the source base station, where the source base station performs verification according to the freshness parameter and the integrity protection key of the source base station.
  • the notification message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
  • the freshness parameter includes a packet data convergence protocol count PDCP COUNT
  • the source base station updates a context of the terminal in the source base station, including: if the value of the PDCP COUNT is greater than the terminal The value of the PDCP COUNT in the context, the source base station updates the value of the PDCP COUNT in the context of the terminal to the value of the PDCP COUNT indicated by the indication parameter.
  • the application provides a method for requesting a connection to restore, comprising: receiving, by a source base station, a context request message from a target base station, where the context request message includes a message authentication code, and the message authentication code is according to the freshness parameter And the freshness protection key generated by the integrity protection key of the terminal, where the freshness parameter used in generating the message authentication code is different, the context request message is used to request to acquire the context of the terminal; And verifying the message authentication code according to the freshness parameter and the integrity protection key of the source base station; if the source base station verifies that the message authentication code is correct, updating the freshness in the context of the terminal And a context response message to the target base station, the context response message including a context of the terminal.
  • the freshness parameter includes a number of rejections, where the number of rejections is used to indicate a number of times the terminal attempts to recover the RRC connection, and the source base station updates the source base station according to the source station.
  • the context of the terminal in the method includes: the source base station resetting the number of rejections in the context of the terminal to zero.
  • the context request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, the freshness parameter includes a PDCP COUNT; and the source base station updates the source base station
  • the context of the terminal in the method includes: if the value of the PDCP COUNT is greater than the value of the PDCP COUNT in the context of the terminal, the source base station updates the value of the PDCP COUNT in the context of the terminal to The value of the PDCP COUNT indicated by the indication parameter.
  • the indication parameter includes a partial bit of the PDCP COUNT; the source base station determines the PDCP COUNT indicated by the indication parameter according to the indication parameter.
  • the present application provides a device, which may be a terminal or a chip in a terminal.
  • the device has the functionality to implement the various embodiments of the first aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software.
  • the hardware or software includes one or more modules corresponding to the functions described above.
  • the terminal when the device is a terminal, the terminal includes: a transmitting unit and a processing unit, and optionally, a receiving unit.
  • the processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter.
  • the receiver and transmitter include radio frequency circuits.
  • the terminal further comprises a storage unit, which may be, for example, a memory.
  • the storage unit stores a computer execution instruction
  • the processing unit is connected to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit, so that the terminal performs the request to restore the connection according to any one of the foregoing first aspects.
  • the chip when the device is a chip in the terminal, the chip includes: a transmitting unit and a processing unit, and optionally, a receiving unit.
  • the processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc.
  • the transmitting unit can be, for example, an output interface, a pin or a circuit.
  • the processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of restoring the connection of any of the above-described first aspects to be performed.
  • the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a read-only memory (ROM), and may be stored.
  • ROM read-only memory
  • RAM random access memory
  • the processor mentioned in any of the above may be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more A program-implemented integrated circuit for controlling a method of requesting a resume connection of any of the above first aspects.
  • CPU central processing unit
  • ASIC application-specific integrated circuit
  • the application provides a device, which may be a target base station or a chip in a target base station.
  • the device has the functionality to implement the various embodiments of the second aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software.
  • the hardware or software includes one or more modules corresponding to the functions described above.
  • the base station when the device is a target base station, the base station includes: a receiving unit and a sending unit, and optionally, a processing unit.
  • the processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter.
  • the receiver and transmitter include radio frequency circuits.
  • the base station further comprises a storage unit, which may be, for example, a memory.
  • the storage unit stores a computer execution instruction
  • the processing unit is coupled to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit to cause the base station to perform the request to restore the connection according to any one of the foregoing second aspects.
  • the chip when the device is a chip in a target base station, the chip includes: a receiving unit and a transmitting unit, and optionally, a processing unit.
  • the processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc.
  • the transmitting unit can be, for example, an output interface, a pin or a circuit.
  • the processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of restoring the connection of any of the above-described second aspects to be performed.
  • the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM only, other types of statics that can store static information and instructions.
  • Storage device RAM, etc.
  • the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or a program executed by one or more methods for controlling the connection recovery request of any of the above second aspects. integrated circuit.
  • the present application provides an apparatus, which may be a target base station or a chip in a target base station.
  • the device has the functionality to implement the various embodiments of the third aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software.
  • the hardware or software includes one or more modules corresponding to the functions described above.
  • the base station when the device is a target base station, the base station includes: a receiving unit and a sending unit, and optionally, a processing unit.
  • the processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter.
  • the receiver and transmitter include radio frequency circuits.
  • the base station further comprises a storage unit, which may be, for example, a memory.
  • the storage unit stores a computer execution instruction
  • the processing unit is connected to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit, so that the base station performs the request to restore the connection according to any one of the foregoing third aspects.
  • the chip when the device is a chip in a target base station, the chip includes: a receiving unit and a transmitting unit, and optionally, a processing unit.
  • the processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc.
  • the transmitting unit can be, for example, an output interface, a pin or a circuit.
  • the processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of restoring the connection of any of the above-described third aspects to be performed.
  • the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM only, other types of statics that can store static information and instructions.
  • Storage device RAM, etc.
  • the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or a program executed by one or more methods for controlling the connection recovery request of any of the above third aspects. integrated circuit.
  • the present application provides an apparatus, which may be a source base station or a chip in a source base station.
  • the device has the functionality to implement the various embodiments of the fourth aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software.
  • the hardware or software includes one or more modules corresponding to the functions described above.
  • the base station when the device is a source base station, the base station includes: a receiving unit and a transmitting unit, and optionally, a processing unit.
  • the processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter.
  • the receiver and transmitter include radio frequency circuits.
  • the base station further comprises a storage unit, which may be, for example, a memory.
  • the storage unit stores a computer execution instruction
  • the processing unit is coupled to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit to cause the base station to perform the request to restore the connection according to any one of the foregoing fourth aspects.
  • the chip when the device is a chip in a source base station, the chip includes: a receiving unit and a transmitting unit, and optionally, a processing unit.
  • the processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc.
  • the transmitting unit can be, for example, an output interface, a pin or a circuit.
  • the processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of requesting to restore the connection of any of the above fourth aspects to be performed.
  • the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM only, other types of statics that can store static information and instructions.
  • Storage device RAM, etc.
  • the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or a program executed by one or more methods for controlling a connection recovery connection according to any of the above fourth aspects. integrated circuit.
  • the application provides a device, which may be a source base station or a chip in a source base station.
  • the device has the functionality to implement the various embodiments of the fifth aspect described above.
  • This function can be implemented in hardware or in hardware by executing the corresponding software.
  • the hardware or software includes one or more modules corresponding to the functions described above.
  • the base station when the device is a source base station, the base station includes: a receiving unit and a transmitting unit, and optionally, a processing unit.
  • the processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter.
  • the receiver and transmitter include radio frequency circuits.
  • the base station further comprises a storage unit, which may be, for example, a memory.
  • the storage unit stores a computer execution instruction
  • the processing unit is connected to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit, so that the base station performs the request to restore the connection according to any one of the foregoing fifth aspects.
  • the chip when the device is a chip in a source base station, the chip includes: a receiving unit and a transmitting unit, and optionally, a processing unit.
  • the processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc.
  • the transmitting unit can be, for example, an output interface, a pin or a circuit.
  • the processing unit may execute a computer execution instruction stored by the storage unit to cause the method of requesting to restore the connection of any of the above fifth aspects to be performed.
  • the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM only, other types of statics that can store static information and instructions.
  • Storage device RAM, etc.
  • the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or a program executed by one or more methods for controlling a connection recovery connection according to any of the above fifth aspects. integrated circuit.
  • the present application further provides a computer readable storage medium having instructions stored therein that, when executed on a computer, cause the computer to perform the methods described in the above aspects.
  • the present application also provides a computer program product comprising instructions which, when run on a computer, cause the computer to perform the methods described in the above aspects.
  • the present application provides a communication system, the system comprising the device of the sixth aspect, the device of the seventh aspect, and the device of the ninth aspect, or the system includes the sixth aspect
  • the system includes the apparatus of the sixth aspect, the apparatus of the eighth aspect, and the apparatus of the tenth aspect.
  • the present application further provides a method for requesting to restore a connection, comprising: updating a access layer key by a terminal to obtain an updated access layer key; and generating, by the terminal, an update according to the updated access layer key a security integrity key; the terminal generates a message authentication code according to the updated integrity protection key; the terminal sends a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, the connection And the recovery request message is used to request to resume the radio resource control RRC connection; the terminal receives a connection recovery reject message from the target base station, where the connection recovery reject message is used to indicate that the terminal is denied to restore the RRC connection; The access layer key is restored to the access layer key before the update.
  • the terminal has updated the access layer key.
  • the terminal may use the method of backing off the key by the terminal.
  • the access layer key is restored to the access layer key before the update. Therefore, the purpose of maintaining the same key between the terminal and the source base station is also achieved, and the problem that the terminal cannot be restored due to the key synchronization between the terminal and the source base station can be effectively solved.
  • the application provides a device, which may be a terminal or a chip in the terminal.
  • the device has the function of implementing the embodiment of the fourteenth aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software.
  • the hardware or software includes one or more modules corresponding to the functions described above.
  • the terminal when the device is a terminal, the terminal includes: a transmitting unit, a receiving unit, and a processing unit.
  • the processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter.
  • the receiver and transmitter include radio frequency circuits.
  • the terminal further comprises a storage unit, which may be, for example, a memory.
  • the storage unit stores a computer execution instruction
  • the processing unit is connected to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit, so that the terminal performs the request for restoring the connection according to the fourteenth aspect. .
  • the chip when the device is a chip in the terminal, the chip includes: a transmitting unit, a receiving unit, and a processing unit.
  • the processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc.
  • the transmitting unit can be, for example, an output interface, a pin or a circuit.
  • the processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of the above-described fourteenth aspect to request a connection to be restored.
  • the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM, other types of static storage that can store static information and instructions. Equipment, RAM, etc.
  • the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or an integrated circuit of one or more programs for controlling the method for requesting the restoration of the connection in the above fourteenth aspect. .
  • FIG. 1 is a schematic diagram of a possible network architecture provided by the present application
  • FIG. 2 is a schematic diagram of a process for a terminal to enter an inactive state from a connected state according to the present application
  • FIG. 3 is a flowchart of a method for requesting a recovery connection according to the present application.
  • FIG. 5 is a flowchart of another method for requesting a recovery connection according to the present application.
  • FIG. 6 is a flowchart of another method for requesting a recovery connection according to the present application.
  • FIG. 7 is a flowchart of another method for requesting to restore a connection provided by the present application.
  • Figure 8 is a schematic diagram of a device provided by the present application.
  • Figure 9 is a schematic view of another apparatus provided by the present application.
  • Figure 10 is a schematic view of another apparatus provided by the present application.
  • FIG. 11 is a schematic diagram of another apparatus provided by the present application.
  • the method of requesting to restore the connection of the present application may be performed by a device.
  • the device may include a device on the network side and/or a device on the terminal side.
  • the device On the network side, the device may be a chip in the base station or the base station, that is, the method of requesting to restore the connection may be performed by the chip in the base station or the base station;
  • the device on the terminal side, the device may be a chip in the terminal or the terminal, that is, The method of requesting to restore a connection of the present application can be performed by a chip in a terminal or a terminal.
  • the present application uses a device as a base station or a terminal as an example to describe a method for requesting to restore a connection.
  • a device is a chip in a base station or a chip in a terminal
  • the connection may be restored by referring to the request of the base station or the terminal. The specific description of the method is not repeated.
  • FIG. 1 is a schematic diagram of a possible network architecture of the present application. It includes a terminal, a source base station, and a target base station.
  • the terminal communicates with the source base station and the target base station through a wireless interface.
  • the source base station and the target base station can communicate through a wired connection, such as through an X2 interface, an Xn interface, or can communicate through an air interface.
  • the terminal may move from the source base station to the target base station due to the movement of the terminal or the like.
  • the source base station is a base station that the terminal accesses first
  • the target base station is a base station that is accessed after the terminal moves.
  • the terminal is a device with wireless transceiver function, which can be deployed on land, indoors or outdoors, handheld or on-board; it can also be deployed on the water surface (such as ships); it can also be deployed in the air (such as airplanes, balloons). And satellites, etc.).
  • the terminal may be a mobile phone, a tablet, a computer with wireless transceiver function, a virtual reality (VR) terminal, an augmented reality (AR) terminal, industrial control (industrial control) Wireless terminal, wireless terminal in self driving, wireless terminal in remote medical, wireless terminal in smart grid, wireless terminal in transportation safety, A wireless terminal in a smart city, a wireless terminal in a smart home, and the like.
  • a base station is a device that provides wireless communication functions for a terminal, including but not limited to: a next-generation base station (g nodeB, gNB), an evolved node B (eNB), and a radio network controller (radio) in 5G.
  • Network controller g nodeB, gNB
  • eNB evolved node B
  • RNC Radio network controller
  • NB node B
  • BSC base station controller
  • BTS base transceiver station
  • home base station for example, home evolved node B, or home node B
  • HNB BaseBand Unit
  • TRP transmission and receiving point
  • TP transmitting point
  • mobile switching center etc.
  • the terminal generally has three states, that is, a connected state, an idle state, and an inactive state.
  • the terminal when the terminal is in the connected state, the terminal is in a normal working state.
  • User data can be sent and received between the network side and the terminal.
  • the terminal and the base station When the terminal enters the idle state from the connected state, the terminal and the base station generally delete all the access stratum (AS) contexts of the terminal.
  • AS access stratum
  • the terminal and the base station when the network side releases the connection of the terminal by the suspend reason, the terminal also enters the idle state from the connected state, but at this time, the terminal and the base station delete part of the AS context, and retain A partial AS context, for example, may retain an access layer key (which may be referred to as KeNB in 4G), a security capability of the terminal, and a security algorithm (including an integrity protection algorithm and an encryption algorithm) for communication between the terminal and the source base station to which the terminal accesses. .
  • the security capability of the terminal refers to the security algorithm supported by the terminal, including the supported encryption algorithm and the supported integrity protection algorithm.
  • the special idle state in which the terminal is located may be referred to as a suspended state.
  • an inactive state is introduced.
  • the base station suspends the terminal.
  • the terminal and the base station delete part of the AS context, and reserve part of the AS context, for example, the access layer may be reserved.
  • the key (which can be called KgNB in 5G), the security capability of the terminal, and the security algorithm (including integrity protection algorithm and encryption algorithm) for communication between the terminal and the source base station accessed by the terminal.
  • the security capability of the terminal refers to the security algorithm supported by the terminal, including the supported encryption algorithm and the supported integrity protection algorithm.
  • the subsequent unification of the suspended state defined in 4G and the inactive state defined in 5G is called inactive state.
  • the base station connected to the terminal and the terminal before the terminal enters the inactive state will save part of the AS context. For details, refer to the foregoing description.
  • the terminal When the terminal is in an inactive state, since part of the AS context is reserved on the terminal, the terminal enters the connected state from the inactive state more quickly than when the terminal enters the connected state from the idle state.
  • the terminal when the terminal returns from the inactive state to the connected state, the terminal may need to replace the base station. That is, the terminal first establishes a connection with the source base station, and then the terminal enters an inactive state at the source base station for some reason, such as network side notification.
  • the terminal wishes to return to the connected state, if the terminal has moved to the coverage of the target base station, the terminal will resume from the inactive state to the connected state at the target base station.
  • the present application is also applicable to the scenario in which the target base station and the source base station are the same when the terminal is restored from the inactive state to the connected state, that is, the base station accessed by the terminal may not change, and is still the same base station.
  • a schematic diagram of a process for a terminal provided in the present application to enter an inactive state from a connected state includes the following steps:
  • Step 201 The base station determines to suspend a radio resource control (RRC) connection of the terminal.
  • RRC radio resource control
  • the base station when the base station does not receive the data sent by the terminal within a certain period of time, it decides to suspend the terminal.
  • Step 202 The base station sends a suspension message to the terminal.
  • the suspend message is used to notify the terminal to release the RRC connection and enter an inactive state.
  • the suspend message may be, for example, an RRC Connection Release message with a special indication.
  • the suspended message may carry the following parameters: a recovery identifier.
  • the suspended message may also carry a next hop chaining counter (NCC) or the like.
  • NCC next hop chaining counter
  • the recovery identifier is a parameter that is required for the terminal to enter the connection state from the inactive state.
  • the recovery identifier may include the identifier of the source base station, the identifier of the terminal, and the like. Specifically, the recovery identifier may be ResumeID, and the inactive state-cell wireless network temporarily Identification (INACTIVE-cell radio network temporary identifier, I-RNTI).
  • the NCC is an optional parameter, and the NCC may also be a parameter required when the terminal subsequently enters the connected state from the inactive state. If the suspended message carries the NCC, the access layer key used by the subsequent terminal and the base station will be updated.
  • the NCC is a parameter required to generate a new access layer key, ie the NCC can be used to generate a new access stratum key (this application uses KgNB* to represent the new access stratum key). If the suspended message does not carry the NCC, the access layer key used by the subsequent terminal and the base station will not be updated, that is, it will remain unchanged.
  • the suspend message may also carry a cause parameter releaseCause, and the releaseCause is used to notify the terminal to perform the suspend operation and enter the inactive state.
  • releaseCause can be set to "RRC Suspend” or "RRC Inactive”.
  • the terminal obtains the releaseCause parameter and determines that the releaseCause value is "RRC Suspend” or "RRC Inactive"
  • the terminal suspends the related operation.
  • the base station may further notify the control plane network element of the core network to release the bearer, for example, release a signaling radio bearer (SRB) or a data radio bearer (DRB).
  • SRB signaling radio bearer
  • DRB data radio bearer
  • Step 203 The terminal enters an inactive state.
  • the terminal saves the deleted part of the AS context and retains part of the AS context.
  • the reserved part of the AS context includes an access layer key, a security capability of the terminal, an integrity protection algorithm and an encryption algorithm for communication between the terminal and the source base station to which the terminal accesses.
  • the terminal also saves the recovery identifier sent by the base station.
  • the terminal also saves parameters such as NCC.
  • the terminal suspends the bearer, for example, suspending the signaling radio bearer, the data radio bearer, and then entering the inactive state.
  • the terminal From the process in which the terminal enters the inactive state from the connected state, it can be seen that after the terminal enters the inactive state, the terminal saves part of the AS context and parameters received from the base station, and thus, when the terminal wishes to recover from the inactive state to the connection. In the state, these parameters will help the terminal to quickly recover from the inactive state to the connected state.
  • the base station accessed by the terminal may also be referred to as a source base station accessed by the terminal.
  • the base station that the terminal requests to access may be the source base station or other base stations, which may be referred to as the target base station.
  • the following describes several methods for introducing a request to restore a connection in a base station rejection scenario. That is, the terminal requests to recover from the inactive state to the connected state, and the terminal requests to resume from the inactive state to the connected state under the target base station.
  • the target base station and the source base station may be different base stations, or may be the same base station.
  • the following is an example in which the target base station and the source base station are different base stations. In the case where the target base station and the source base station are the same base station, only the interaction between the source base station and the target base station needs to be omitted.
  • a method for requesting a recovery connection includes the following steps:
  • Step 301 The terminal generates a message authentication code (MAC).
  • MAC message authentication code
  • the message authentication code is used to authenticate the legitimacy of the terminal.
  • the message authentication code has at least two generation modes:
  • Manner 1 Generate a message authentication code according to the integrity protection algorithm of the terminal and the integrity protection key of the terminal, where the integrity protection key is the same as the integrity protection key used in the previous restoration.
  • the integrity protection key used by the terminal each time the message authentication code is generated is the same as the integrity protection key used in the previous restoration, and accordingly, the integrity protection key of the terminal stored in the source base station It is also the same as the integrity protection key used in the previous recovery.
  • the Krrc-int is used to represent the integrity protection key of the terminal. If the other parameters of the message authentication code are the same, the message authentication code generated by the terminal is the same every time, that is, according to the completeness of the Krrc-int and the terminal. Sex protection algorithm generation.
  • the Krrc-int is generated by the terminal according to the access layer key, the identifier of the integrity protection algorithm of the terminal, and the type of the integrity protection algorithm of the terminal. Therefore, in the first method, the integrity protection key Krrc-int of the terminal is the same as the integrity protection key used in the previous recovery, and can also be understood as the access layer key of the terminal and the last recovery used.
  • the access layer keys are the same.
  • the access layer key KgNB used by the terminal to generate the message authentication code remains the same as the access layer key used in the previous restoration.
  • Manner 2 Generate a message authentication code according to the integrity protection algorithm of the terminal and the integrity protection key of the terminal, where the integrity protection key is regenerated.
  • the integrity protection key used by the terminal each time the message authentication code is generated is regenerated, and is different from the integrity protection key used by the terminal last time.
  • the terminal will need to regenerate and use the new integrity protection key, for example using Krrc-int* to indicate the new integrity protection key.
  • the terminal may generate a new integrity protection key Krrc-int* by using the following method: the terminal generates a new access layer key, and then uses the new access layer key, the terminal integrity protection algorithm.
  • the type of identity and the integrity protection algorithm of the terminal generate Krrc-int*.
  • KgNB is used to indicate the current access layer key of the terminal
  • KgNB* is used to represent the new access layer key.
  • the terminal is based on the KgNB*, the identifier of the integrity protection algorithm of the terminal, and the terminal.
  • the type of integrity protection algorithm generates Krrc-int*, and then uses Krrc-int* and the terminal integrity protection algorithm to generate the message authentication code.
  • the resulting message authentication code has changed. That is, each time the terminal needs to use the message authentication code, the generated message authentication code is different from the message authentication code generated last time.
  • Step A1 The terminal acquires the first NCC and the second NCC.
  • the first NCC refers to the NCC that is sent by the source base station to the terminal and saved by the terminal in the suspending process. For details, refer to step 202 above.
  • the second NCC refers to the NCC saved by the terminal before the first NCC is obtained.
  • Step A2 The terminal determines whether the first NCC is the same as the second NCC. If they are the same, step A3 is performed; if not, step A4 is performed.
  • Step A3 The terminal obtains KgNB* according to KgNB.
  • KgNB* refers to the new access layer key (new KgNB), which may also be referred to as the updated access layer key (updated KgNB).
  • KgNB, KgNB* is just a symbolic representation.
  • the access layer key can be represented by KeNB, KeNB*.
  • the different manifestations used in the symbols themselves are not intended to limit the application.
  • the terminal may be based on KgNB, a target physical cell identifier (PCI), and an absolute radio frequency channel number-down link (ARFCN-). DL), get KgNB*.
  • PCI target physical cell identifier
  • ARFCN- absolute radio frequency channel number-down link
  • KgNB* for the prior art, reference may be made to related documents, for example, reference can be made to the 3rd generation partnership project (3GPP) technical specification (technical) Specification, TS) 33.401 or related description in 3GPP TS 33.501, which is not described here.
  • 3GPP 3rd generation partnership project
  • Step A4 The terminal obtains a next hop (NH) according to the first NCC and the second NCC, and obtains KgNB* according to the NH.
  • NH next hop
  • NH is associated with the first NCC and the second NCC.
  • the terminal can determine the number N of the derived NH according to the first NCC and the second NCC, and then derive the next NH according to the current NH, and obtain another NH by using the next NH, and repeat until the N is derived to obtain the final NH.
  • the terminal may obtain KgNB* according to NH, target PCI, and ARFCN-DL.
  • the terminal may use the integrity protection key, the source PCI, the source cell radio network temporary identifier (C-RNTI), and the target.
  • the cell identifier and the recovery constant generate a message authentication code.
  • the main difference between the first mode and the second mode is that, in the first mode, each time the terminal uses the message authentication code, the generated message authentication code is the same as the message authentication code generated last time, that is, the message authentication code. In the second mode, each time the terminal uses the message authentication code, the generated message authentication code is different from the message authentication code generated last time, that is, the message authentication code remains updated.
  • Step 302 The terminal sends a connection recovery request message to the target base station, and the target base station receives a connection recovery request message from the terminal.
  • a connection recovery request message sent by the terminal used to request to resume the RRC connection. That is, the terminal requests to return from the inactive state to the connected state.
  • connection recovery request message carries a recovery identifier.
  • the recovery identifier is sent by the source base station to the terminal when the terminal enters the inactive state from the connected state. For example, reference may be made to the related description of step 202 above, and details are not described herein again.
  • connection recovery request message further carries the message authentication code generated in step 301 above.
  • Step 303 The target base station determines whether to approve the recovery request of the terminal.
  • the target base station determines whether the terminal can be accessed based on the load capability.
  • the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, step 304 is performed.
  • the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station.
  • step 305-step 308 is performed.
  • Step 304 The target base station sends a connection recovery reject message to the terminal, and the terminal receives a connection recovery reject message from the target base station.
  • connection recovery reject message is used to indicate that the terminal is denied the RRC connection.
  • connection recovery refusal message may be carried with a wait timer, where the information of the wait timer is used to reject the terminal access time, and may also be used to indicate that the terminal requests the recovery again.
  • the minimum length of time that an RRC connection needs to wait For example, if it waits for 30 minutes indicated by the timer information, it is used to instruct the terminal to wait at least 30 minutes before the connection recovery request can be re-initiated. That is, the operations of steps 301 and 302 are re-executed, and the next connection recovery request flow is entered.
  • Step 305 The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
  • the context request message is used to request the context of the terminal.
  • the recovery identifier is obtained from the connection recovery request message, and according to the identifier of the source base station in the recovery identifier, it is determined that the terminal is connected to the source base station before, Sending a context request message to the source base station, where the context request message is used to request the acquisition of the context of the terminal, where the context request message carries the recovery identifier and the message authentication code.
  • the source base station After receiving the context request message, the source base station obtains the recovery identifier, and obtains the access layer context of the terminal according to the identifier of the terminal in the recovery identifier, including the security capability of the terminal.
  • the obtained access layer context of the terminal further includes information such as an encryption algorithm and an integrity protection algorithm negotiated between the terminal and the source base station.
  • Step 306 The source base station acquires the context of the terminal if the verification message authentication code is correct.
  • the method for the source base station to verify the message authentication code corresponds to the method for the terminal to generate the message authentication code.
  • the source base station checks the message authentication code in the following manner: the source base station acquires an integrity protection algorithm in the context of the terminal (which may also be referred to as an integrity protection algorithm of the source base station) and The access layer key is then derived according to the key of the access layer, and the integrity protection key (which may also be referred to as the integrity protection key of the source base station) is derived, or the source base station acquires the integrity in the context of the terminal.
  • an integrity protection algorithm in the context of the terminal which may also be referred to as an integrity protection algorithm of the source base station
  • the access layer key is then derived according to the key of the access layer, and the integrity protection key (which may also be referred to as the integrity protection key of the source base station) is derived, or the source base station acquires the integrity in the context of the terminal.
  • a protection algorithm (which may also be referred to as an integrity protection algorithm of the source base station) and an integrity protection key (which may also be referred to as an integrity protection key of the source base station), and then according to the integrity protection algorithm of the source base station and the integrity of the source base station
  • the protection key is generated, and the message authentication code is generated and compared with the message authentication code in the context request message. If they are the same, the verification is correct. If it is different, the verification fails.
  • the source base station checks the message authentication code by: the source base station determines whether the next hop NH has been used, and if not, the source base station obtains new access according to the NH.
  • the layer key KgNB* if used, the source base station obtains a new access layer key KgNB* according to the current access layer key KgNB of the terminal.
  • Krrc-int* is generated according to the KgNB*, the identity of the integrity protection algorithm of the source base station, and the type of the integrity protection algorithm of the source base station, and then the integrity protection of the source base station is performed using the Krrc-int* and the source base station.
  • the algorithm generates a message authentication code and compares it with the message authentication code in the context request message. If they are the same, the verification is correct. If it is different, the verification fails.
  • the source base station may further generate a message authentication code according to the integrity protection key, the source PCI, the source cell radio network temporary identifier (C-RNTI), the target cell identifier, and the recovery constant.
  • C-RNTI source cell radio network temporary identifier
  • Step 307 The source base station sends a context response message to the target base station if the verification message authentication code is correct.
  • the context response message may include a context of the terminal, for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station.
  • a context of the terminal for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station.
  • the generated KgNB* is also included.
  • Step 308 The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
  • connection recovery response message is used to instruct the terminal to resume the RRC connection.
  • the connection recovery response message may be integrity protected and encrypted by the target base station according to the integrity protection algorithm of the source base station and the integrity protection key and the encryption key generated by the KgNB*.
  • the KgNB* used by the target base station may be from the source base station.
  • step 308 the subsequent process of the terminal from the inactive state to the connected state is further included.
  • the subsequent process of the terminal from the inactive state to the connected state is further included.
  • the message authentication code is generated in the first step 301, that is, the message authentication code generated by the terminal is the same each time.
  • the terminal sends the connection recovery request message to the target base station for the first time
  • the target base station rejects the connection recovery request of the terminal
  • the attacker may steal the first connection of the terminal before the next (ie, second) transmission of the connection recovery request message.
  • the message authentication code carried in the connection recovery request message is sent, and then the attacker masquerades as a terminal, and sends a connection recovery request message to the target base station, where the connection recovery request message carries the message authentication code stolen by the attacker.
  • step 305-step 308 is performed, so that the source base station verifies that the message authentication code is correct, and then carries the context of the terminal in the context response message and sends the message to the target base station, and the source base station The context of the terminal is deleted. Further, when the terminal resends the connection recovery request message to the target base station for the second time, the source base station has deleted the context of the terminal, and the terminal cannot pass the authentication, so the terminal cannot enter the connected state from the inactive state.
  • the target base station rejects the attacker's connection recovery request, but the attacker can continuously attack until the target base station agrees to the attacker's connection recovery request. Therefore, in the first method, the above-mentioned vulnerable problem exists, and the terminal may not be able to enter the connected state from the inactive state.
  • the message authentication code generated by the terminal is different each time.
  • the terminal sends a connection recovery request message to the target base station for the first time
  • the target base station rejects the connection recovery request of the terminal
  • the access layer key stored on the terminal has been updated to KgNB*.
  • the target base station does not notify the source base station that the key has been updated, the access layer key stored on the source base station is still the original access layer key KgNB.
  • the terminal sends the connection recovery request message to the target base station for the second time
  • the access layer key stored on the terminal is KgNB*
  • the connection is stored on the source base station.
  • the inbound key is KgNB
  • the source base station fails to check the authentication code of the message sent by the terminal.
  • the terminal cannot enter the connected state from the inactive state. Therefore, there is also a problem that the second mode may not be able to enter the connected state from the inactive state.
  • the present application will propose the following solutions to the above problems with the method of requesting a connection recovery as shown in FIG. The following are explained separately.
  • the solution 1 can be used to solve the problem that the foregoing step 301 adopts the method 1 to generate the message authentication code.
  • a flowchart of a method for requesting a recovery connection includes the following steps:
  • Step 401 The terminal generates a message authentication code according to the freshness parameter and the integrity protection key of the terminal.
  • the freshness parameters used to generate the message authentication code twice are different. That is, the specific value of the freshness parameter changes every time the message authentication code is generated, and the freshness parameter used when generating the message authentication code is different from the freshness parameter used when the message authentication code was last generated. .
  • the freshness parameter includes a Packet Data Convergence Protocol COUNT (PDCP COUNT), and the PDCP COUNT may include an uplink PDCP COUNT and a downlink PDCP COUNT, and the terminal uplinks the PDCP every time an uplink PDCP packet is sent. COUNT plus 1, the downlink PDCP COUNT is incremented by 1 for each downlink PDCP packet sent by the base station.
  • the PDCP COUNT may be an uplink PDCP COUNT of a signaling radio bearer (SRB).
  • SRB signaling radio bearer
  • the PDCP COUNT can be reset to zero. Since the PDCP COUNT is constantly changing, the message authentication code generated by the terminal each time is different from the last generated message authentication code.
  • the freshness parameter may include the number of rejections, and the number of rejections may be used to indicate the number of times the terminal attempts to restore the RRC connection rejected by the network side. Each time the terminal attempts to resume being rejected by the network side, the number of rejections is increased by one. Alternatively, the number of rejections may be reset to zero each time the RRC connection is successfully restored. Since the number of rejections is always changing, the message authentication code generated by the terminal each time is different from the message authentication code generated last time.
  • the message authentication code may be generated according to the freshness parameter, the integrity protection key of the terminal, and the integrity protection algorithm of the terminal.
  • Step 402 The terminal sends a connection recovery request message to the target base station, and the target base station receives a connection recovery request message from the terminal.
  • connection recovery request message is used to request to restore the RRC connection, and the connection recovery request message includes a message authentication code and a recovery identifier.
  • the connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
  • the indication parameter may be the freshness parameter itself, or may be a parameter indicating the freshness parameter.
  • the connection recovery request message also includes a recovery identifier.
  • the connection recovery request message includes a message authentication code and a recovery identifier. If the freshness parameter is PDCP COUNT, the connection recovery request message includes a message authentication code, a recovery identifier, and an indication parameter, and the indication parameter is used to indicate PDCP COUNT.
  • the freshness parameter is PDCP COUNT
  • the PDCP COUNT is represented by a binary bit
  • the indication parameter PDCP COUNT itself is all bits of the PDCP COUNT.
  • the indication parameter can also be a partial bit of the PDCP COUNT.
  • the indication parameter can be represented using a portion of the low bit of the PDCP COUNT.
  • the PDCP COUNT used by the terminal to generate the message authentication code is “00000000000011111111111100011111”
  • the PDCP COUNT used by the terminal to generate the message authentication code is “00000000000011111111100100011”. It can be found that only the lower 5 bits of the PDCP COUNT have changed. The high 27 did not change. Therefore, the lower N bits of the PDCP COUNT can be selected as the indication parameter, N being greater than 1, and less than 32.
  • the indication parameter can also be all bits of the PDCP COUNT.
  • the terminal and the source base station each maintain the number of times the terminal is refused to resume the connection.
  • the message authentication code generated by the terminal is different from the message authentication code generated last time. Therefore, even if the attacker steals the message authentication code used by the terminal last time, the "expired" is used. The message authentication code, therefore, the attacker will not be able to attack successfully.
  • Step 403 The target base station determines whether to approve the recovery request of the terminal.
  • the target base station determines whether the terminal can be accessed based on the load capability.
  • the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station.
  • step 404-step 407 is performed.
  • the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station. At this time, steps 408 to 411 are performed.
  • Step 404 The target base station sends a notification message to the source base station, where the source base station receives the notification message from the target base station.
  • the notification message includes a message authentication code and a recovery identifier obtained by the target base station from the connection recovery request message, and optionally, an indication parameter, wherein the context of the terminal in the source base station that notifies the update includes a freshness parameter.
  • the notification message has one or more of the following functions:
  • the notification message is used to notify the update of the context of the terminal in the source base station;
  • the notification message is used to notify the target base station that the terminal is refused to resume the connection;
  • the notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
  • the notification message is used to notify the key of the context of the terminal in the update source base station.
  • Step 405 The source base station checks the message authentication code, and if the verification message authentication code is correct, updates the context of the terminal.
  • the source base station first acquires the context of the terminal in the source base station according to the recovery identifier in the notification message.
  • the source base station determines the freshness parameter.
  • the source base station determines a freshness parameter based on the indication parameters. For example, when the freshness parameter is PDCP COUNT, the source base station determines the PDCP COUNT indicating the parameter indication according to the indication parameter. In a specific implementation, if the indication parameter indicates a partial bit of the PDCP COUNT, the source base station may determine the indication according to a part of the high bit of the PDCP COUNT currently stored by the source base station and a part of the low bit of the PDCP COUNT indicated by the parameter. The PDCP COUNT indicated by the parameter.
  • the source base station directly determines the freshness parameter. For example, when the freshness parameter is the number of rejections, the source base station determines the current number of rejections as the number of rejections. That is, the target base station can directly obtain the number of rejections of the terminal locally.
  • the source base station generates a message authentication code according to the freshness parameter, the integrity protection key of the source base station, and the integrity protection algorithm of the source base station, if the generated message authentication code is the same as the message authentication code generated by the terminal carried in the notification message. , the verification is correct, if it is different, the verification fails.
  • the source base station may be based on a freshness parameter, an integrity protection key of the source base station, and an integrity protection algorithm of the source base station, a source PCI, a cell radio network temporary identifier (C-RNTI), The target cell identifier and the recovery constant generate a message authentication code.
  • a freshness parameter an integrity protection key of the source base station, and an integrity protection algorithm of the source base station
  • a source PCI a source PCI
  • C-RNTI cell radio network temporary identifier
  • the target cell identifier and the recovery constant generate a message authentication code.
  • the source base station verifies that the message authentication code is correct, the freshness parameter in the context of the terminal is updated.
  • the freshness parameter is PDCP COUNT
  • the source base station updates the context of the terminal in the source base station, including: if the value of the PDCP COUNT in the notification message is greater than the value of the PDCP COUNT in the context of the terminal in the source base station, the source The base station updates the value of the PDCP COUNT in the context of the terminal to the value of the PDCP COUNT in the notification message, or understands that the value of the PDCP COUNT in the context of the terminal is updated to the value of the PDCP COUNT indicating the parameter indication.
  • the freshness parameter is the number of rejections
  • the source base station updates the context of the terminal in the source base station according to the freshness parameter, including: the source base station increases the number of rejections by one.
  • the source base station may first determine whether the value of the PDCP COUNT in the notification message is greater than the value of the PDCP COUNT in the context of the terminal in the source base station, if the value of the PDCP COUNT in the notification message is greater than the source base station. If the value of the PDCP COUNT in the context of the terminal in the terminal is correct, the source base station checks the message authentication code. If the verification message authentication code is correct, the freshness parameter in the context of the terminal is updated according to the freshness parameter.
  • the specific update method is: The source base station updates the value of the PDCP COUNT in the context of the terminal to the value of the PDCP COUNT in the notification message.
  • Step 406 The source base station sends a response message to the target base station, and the target base station receives the response message from the source base station.
  • the step 406 is an optional step, and the response message is used by the source base station to notify the target base station after the context update of the terminal is completed.
  • Step 407 The target base station sends a connection recovery reject message to the terminal, where the terminal receives a connection recovery reject message from the target base station.
  • This step 407 is the same as step 304 above, and can be referred to the foregoing description.
  • the terminal updates the number of rejections after receiving the connection recovery rejection message, including: adding 1 to the number of rejections.
  • step 407 may be performed before step 404, may be performed after step 406, and may also be performed between step 404-step 406.
  • the target base station when the target base station decides to reject the connection recovery request of the terminal, on the one hand, the target base station notifies the terminal to reject the connection recovery request, and on the other hand, notifies the source base station to update the context of the terminal, specifically, the update source. Freshness parameters stored in the base station. Thereby the freshness parameters between the terminal and the source base station are kept consistent.
  • Step 408 The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
  • the context request message includes a message authentication code and a recovery identifier generated by the terminal, and the context request message is used to request to acquire the context of the terminal.
  • the context request message further includes an indication parameter.
  • Step 409 The source base station updates the freshness parameter in the context of the terminal if the verification message authentication code is correct.
  • step 405 For the manner in which the source base station checks the message authentication code and the manner in which the source base station updates the freshness parameter in the context of the terminal, refer to the description of step 405 above, and details are not described herein again.
  • Step 410 The source base station sends a context response message to the target base station, where the target base station receives a context response message from the source base station.
  • Step 411 The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
  • the source base station checks the message authentication code of the terminal according to the freshness parameter, and when the verification is correct, on the one hand, updates the source base station.
  • the freshness parameter in the context of the terminal sends the context of the acquired terminal to the target base station.
  • the freshness parameter is introduced in the input parameter of the terminal to generate the message authentication code, and accordingly, the freshness parameter is also introduced in the input parameter of the source base station verification message authentication code.
  • the target base station may notify the source base station to update the freshness parameter in the context of the terminal by step 404, thereby maintaining the consistency of the freshness parameter of the terminal and the source base station.
  • the target base station may request to acquire the context of the terminal from the source base station through step 408, and at the same time, the source base station may also update the source context of the source base station in the process. Sexual parameters, thereby maintaining the consistency of the terminal with the freshness parameters of the source base station.
  • the foregoing solution 1 can effectively solve the problem that the above-mentioned step 301 adopts the method 1 to generate a message authentication code, which is vulnerable.
  • the following is explained in conjunction with specific examples.
  • the freshness parameter as the PDCP COUNT as an example, it is assumed that the value of the PDCP COUNT currently stored by the terminal and the source base station is 5, and the terminal is currently in an inactive state.
  • the terminal sends a connection recovery request message to the target base station for the first time.
  • the connection recovery request message carries a message authentication code, an indication parameter, and a recovery identifier, and the message authentication code is generated according to the PDCP COUNT and the integrity protection key of the terminal, and the The PDCP COUNT indicated by the indication parameter is greater than 5, for example 10.
  • the target base station rejects the connection recovery request of the terminal, the connection recovery rejection message sent to the terminal carries the information of the waiting timer, and instructs the terminal to try to re-initiate the connection recovery request after 30 minutes.
  • the target base station informs the source base station to update the PDCP COUNT in the context of the terminal of the source base station to 10.
  • the PDCP COUNT used is 10.
  • the attacker sends a connection recovery request message to the target base station, where the connection recovery request message carries the stolen message authentication code and the recovery identifier, and after receiving the connection recovery request message, the target base station, if it agrees to the attacker's recovery request, then The source base station sends a context request message. Then, the source base station checks the message authentication code sent by the attacker.
  • the PDCP COUNT used in the generation of the message authentication code sent by the attacker is 10, and the PDCP COUNT in the context of the terminal of the source base station is also 10, two. The two are equal, so the verification fails. Thus, the attacker fails to attack.
  • the freshness parameter as the number of rejections
  • the value of the number of rejections currently stored by the terminal and the source base station is 2, and the terminal is currently in an inactive state.
  • the terminal sends a connection recovery request message to the target base station for the first time.
  • the connection recovery request message carries a message authentication code and a recovery identifier.
  • the message authentication code is generated according to the number of rejections and the integrity protection key of the terminal. 2.
  • the target base station rejects the connection recovery request of the terminal, the connection recovery rejection message sent to the terminal carries the information of the waiting timer, indicating that the terminal may try to re-initiate the connection recovery request after 30 minutes, and the terminal update rejection number is 3. At the same time, the target base station notifies the source base station to update the number of rejections in the context of the terminal of the source base station to 3.
  • the attacker steals the message authentication code and the recovery identifier from the connection recovery request message sent by the terminal to the target base station for the first time, where the message authentication code is generated.
  • the number of rejections used is 2.
  • the attacker sends a connection recovery request message to the target base station, where the connection recovery request message carries the stolen message authentication code and the recovery identifier, and after receiving the connection recovery request message, the target base station, if it agrees to the attacker's recovery request, then The source base station sends a context request message. Then, the source base station checks the message authentication code sent by the attacker, because the number of rejections used by the attacker to send the message authentication code is 2, and the number of rejections in the context of the terminal of the source base station is 3, so the school The test failed. Thus, the attacker fails to attack.
  • the first solution provided by the present application can effectively solve the problem of the method 1 for generating the message authentication code in the foregoing step 301, and can effectively resist the attack of the attacker.
  • the solution 2 can be used to solve the problem that the foregoing step 301 uses the second method to generate the message authentication code.
  • Step 501 The terminal generates a message authentication code.
  • the step 501 is the same as the second method of the foregoing step 301, and the foregoing description may be referred to.
  • the access layer key is also updated, that is, updated by KgNB to KgNB*, and the integrity protection key is also updated, that is, updated by Krrc-int to Krrc- Int*.
  • Step 502 The terminal sends a connection recovery request message to the target base station, where the target base station receives a connection recovery request message from the terminal.
  • This step 502 is the same as the foregoing step 302, and the foregoing description can be referred to.
  • Step 503 The target base station determines whether to agree to the recovery request of the terminal.
  • the target base station determines whether the terminal can be accessed based on the load capability.
  • the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, steps 504 to 507 are performed.
  • the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station.
  • step 508-step 511 is performed.
  • Step 504 The target base station sends a notification message to the source base station, where the source base station receives the notification message from the target base station.
  • the notification message includes a message authentication code and a recovery identifier obtained by the target base station from the connection recovery request message.
  • the notification message has one or more of the following functions:
  • the notification message is used to notify the update of the context of the terminal in the source base station;
  • the notification message is used to notify the target base station that the terminal is refused to resume the connection;
  • the notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
  • the notification message is used to notify the key of the context of the terminal in the update source base station.
  • the key may be an access layer key, and/or an integrity protection key.
  • Step 505 The source base station checks the message authentication code, and if the verification message authentication code is correct, updates the key of the context of the terminal.
  • the source base station first acquires the context of the terminal in the source base station according to the recovery identifier in the notification message.
  • the source base station generates a message authentication code according to the integrity protection algorithm of the source base station and the integrity protection key of the source base station. If the generated message authentication code is the same as the message authentication code carried in the notification message, the verification is correct. Different, the verification fails.
  • the integrity protection key of the source base station used by the source base station to generate the message authentication code is the new integrity protection key Krrc-int* generated by the source base station. For the specific generation method, refer to the related description in step 306 above. No longer.
  • the source base station verifies the message authentication code, and if the verification message authentication code is correct, updates the access layer key of the context of the terminal, and/or the integrity protection key.
  • Step 506 The source base station sends a response message to the target base station, and the target base station receives the response message from the source base station.
  • the step 506 is an optional step, and the response message is used by the source base station to notify the target base station after the context update of the terminal is completed.
  • Step 507 The target base station sends a connection recovery reject message to the terminal, where the terminal receives a connection recovery reject message from the target base station.
  • This step 507 is the same as step 304 above, and the foregoing description can be parameterized.
  • step 507 may be performed before step 504, may be performed after step 506, and may also be performed between steps 504-506.
  • the target base station decides to reject the connection recovery request of the terminal, on the one hand, the target base station notifies the terminal to reject the connection recovery request, and on the other hand, notifies the source base station to update the key of the context of the terminal. Thereby the keys between the terminal and the source base station are kept consistent.
  • Step 508 The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
  • the context request message includes a message authentication code and a recovery identifier generated by the terminal, and the context request message is used to request to acquire the context of the terminal.
  • This step is the same as step 305 above, and the foregoing description can be referred to.
  • Step 509 The source base station acquires the context of the terminal if the verification message authentication code is correct.
  • Step 510 The source base station sends a context response message to the target base station if the verification message authentication code is correct.
  • the context response message may include a context of the terminal, for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station.
  • a context of the terminal for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station.
  • the generated KgNB* is also included.
  • Step 511 The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
  • connection recovery response message is used to instruct the terminal to resume the RRC connection.
  • the connection recovery response message may be integrity protected and encrypted by the target base station according to the integrity protection algorithm of the source base station and the integrity protection key and the encryption key generated by the KgNB*.
  • step 308 the subsequent process of the terminal from the inactive state to the connected state is further included.
  • the subsequent process of the terminal from the inactive state to the connected state is further included.
  • the method for restoring the connection as shown in the above steps 501 to 511 can effectively solve the problem that occurs when the message authentication code is generated by the second method in the foregoing step 301.
  • the target base station decides to reject the terminal
  • the target base station sends a notification message to the source base station to notify the source base station to update the key, so that the key is always the same between the terminal and the source base station, so that the terminal and the source can be effectively solved.
  • the terminal that is not synchronized between the base stations cannot solve the problem of the connection being restored.
  • step 504-step 506 may also be deleted, and after step 507, the operation of the terminal is added: the terminal Restore the access layer key of the terminal to the access layer key before the update.
  • the terminal has updated the access layer key.
  • the terminal may also use the method of backing off the key by the terminal.
  • the access layer key of the terminal is restored to the access layer key before the update. Therefore, the purpose of maintaining the same key between the terminal and the source base station is also achieved, and the problem that the terminal cannot be restored due to the key synchronization between the terminal and the source base station can be effectively solved.
  • the solution three is a solution obtained by combining the above solution one and the solution two.
  • the solution 3 can effectively resist the attacker's attack while solving the above problem of inconsistent key.
  • Step 601 The terminal generates a message authentication code.
  • the message authentication code is generated by combining the manner in which the message authentication code is generated in the above step 401 and the manner in which the message authentication code is generated in step 501.
  • the terminal generates a message authentication code according to the integrity protection algorithm of the terminal, the integrity protection key of the terminal, and the freshness parameter, where the integrity protection key of the terminal is Krrc-int*, and the Krrc-int* is based on The updated access layer key KgNB*, the identity of the integrity protection algorithm of the terminal, and the type of integrity protection algorithm of the terminal are generated.
  • Step 602 The terminal sends a connection recovery request message to the target base station, where the target base station receives a connection recovery request message from the terminal.
  • connection recovery request message includes a message authentication code and a recovery identifier.
  • connection recovery request further includes an indication parameter, and the indication parameter is used to indicate a freshness parameter.
  • Step 603 The target base station determines whether to approve the recovery request of the terminal.
  • the target base station determines whether the terminal can be accessed based on the load capability.
  • the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, steps 604 to 607 are performed.
  • the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station.
  • step 608-step 611 is performed.
  • Step 604 The target base station sends a notification message to the source base station, where the source base station receives the notification message from the target base station.
  • the notification message includes a message authentication code and a recovery identifier obtained by the target base station from the connection recovery request message.
  • the notification message may further include an indication parameter.
  • the notification message has one or more of the following functions:
  • the notification message is used to notify the update of the context of the terminal in the source base station;
  • the notification message is used to notify the target base station that the terminal is refused to resume the connection;
  • the notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
  • the notification message is used to notify the key of the context of the terminal in the update source base station.
  • the key may be an access layer key, and/or an integrity protection key.
  • Step 605 The source base station checks the message authentication code. If the verification message authentication code is correct, the freshness parameter and the key of the context of the terminal are updated.
  • the source base station first determines the context of the terminal in the source base station according to the recovery identifier in the notification message.
  • the source base station determines the freshness parameter.
  • the source base station may determine the freshness parameter according to the indication parameter in the notification message. For example, when the freshness parameter is PDCP COUNT, the source base station determines the PDCP COUNT indicating the parameter indication according to the indication parameter.
  • the source base station can also directly determine the freshness parameters. For example, when the freshness parameter is the number of rejections, the source base station determines the current number of rejections as the number of rejections.
  • the source base station generates a message authentication code according to the freshness parameter, the integrity protection key of the source base station, and the integrity protection algorithm of the source base station, if the generated message authentication code is the same as the message authentication code generated by the terminal carried in the notification message. , the verification is correct, if it is different, the verification fails.
  • the integrity protection key of the source base station used by the source base station to generate the message authentication code is a new integrity protection key Krrc-int* generated by the source base station.
  • the freshness parameter in the context of the terminal is updated according to the freshness parameter. For details, refer to the related description of the foregoing step 405. And, the source base station also updates the key in the context of the terminal. For example, the integrity protection key Krrc-int in the source base station is updated to Krrc-int*, and/or the access layer key KgNB in the source base station is updated to KgNB*.
  • Step 606 The source base station sends a response message to the target base station, and the target base station receives the response message from the source base station.
  • the step 606 is an optional step, and the response message is used by the source base station to notify the target base station after the context update of the terminal is completed.
  • Step 607 The target base station sends a connection recovery reject message to the terminal, where the terminal receives a connection recovery reject message from the target base station.
  • This step 607 is the same as step 404 above, and the foregoing description can be parameterized.
  • step 607 may be performed before step 604, may be performed after step 606, and may also be performed between steps 604-606.
  • the target base station when the target base station decides to reject the connection recovery request of the terminal, on the one hand, the target base station notifies the terminal to reject the connection recovery request, and on the other hand, notifies the source base station to update the context of the terminal, specifically, the update source. Freshness parameters and keys stored in the base station. Therefore, the freshness parameters between the terminal and the source base station are consistent, and the keys are consistent.
  • Step 608 The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
  • the context request message includes a message authentication code generated by the terminal, a freshness parameter, and a recovery identifier, and the context request message is used to request to acquire the context of the terminal.
  • Step 609 If the source base station verifies that the message authentication code is correct, the freshness parameter and the key in the context of the terminal are updated.
  • step 605 For the manner in which the source base station checks the message authentication code, and the manner in which the source base station updates the freshness parameter and the key in the context of the terminal, refer to the description of step 605 above, and details are not described herein again.
  • Step 610 The source base station sends a context response message to the target base station, and the target base station receives a context response message from the source base station.
  • Step 611 The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
  • the source base station performs the message authentication code of the terminal according to the freshness parameter, the integrity protection key of the source base station, and the integrity protection algorithm of the source base station.
  • the freshness parameter is introduced in the input parameter of the terminal to generate the message authentication code by the method in the above steps 601-step 611.
  • the freshness parameter is also introduced in the input parameter of the source base station verification message authentication code.
  • the integrity protection key used to generate the message authentication code is generated based on the updated integrity protection key.
  • the target base station may notify the source base station to update the freshness parameter and the key in the context of the terminal by step 604, thereby maintaining the freshness parameter and the key of the terminal and the source base station. Consistent.
  • the target base station may request to acquire the context of the terminal from the source base station by using step 608, and the source base station may also update the source context of the source base station in the process. Sex parameters and keys, thereby maintaining the consistency of the terminal and the source station's freshness parameters and keys.
  • the key synchronization between the terminal and the source base station can be maintained, and on the other hand, the attacker can be effectively resisted, thereby facilitating the terminal to smoothly enter the connected state from the inactive state. .
  • the solution 4 can be used to solve the problem that the foregoing step 301 adopts the second method to generate the message authentication code.
  • Step 701 The terminal generates a message authentication code.
  • This step 701 is the same as the second method of the foregoing step 301, and reference may be made to the foregoing description.
  • the terminal updates the access layer key before the message authentication code is generated, that is, the KgNB is updated to KgNB*, and the integrity protection key is also updated, that is, updated by Krrc-int to Krrc-int. *.
  • a message authentication code is then generated based on the updated integrity protection key.
  • Step 702 The terminal sends a connection recovery request message to the target base station, where the target base station receives a connection recovery request message from the terminal.
  • This step 702 is the same as the foregoing step 302, and can be referred to the foregoing description.
  • Step 703 The target base station determines whether to agree with the recovery request of the terminal.
  • the target base station determines whether the terminal can be accessed based on the load capability.
  • the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, steps 704-705 are performed.
  • the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station.
  • step 706-step 709 is performed.
  • Step 704 The target base station sends a connection recovery reject message to the terminal, where the terminal receives a connection recovery reject message from the target base station.
  • This step 704 is the same as step 304 above, and reference may be made to the foregoing description.
  • Step 705 The terminal restores the access layer key of the terminal to the access layer key before the update.
  • One implementation may be that the terminal saves the access layer key before the update, such as KgNB, before receiving the reject message. After receiving the reject message, the terminal uses the access layer key before the update as the current or stored access layer key. Optionally, after receiving the reject message, the terminal may also delete the updated access layer key, such as KgNB*.
  • the terminal saves the security context before the update before receiving the reject message, and the security context before the update includes the access layer key before the update, such as KgNB.
  • the terminal uses the pre-update security context as the current or stored security context.
  • the terminal may also delete the updated security context.
  • the security context may be the AS security context of the terminal.
  • the terminal restores the access layer key of the terminal to the access layer key before the update
  • the access layer key before the update is saved, and the terminal performs the second mode in step 701 again after the next connection is restored.
  • the terminal has updated the access layer key.
  • the terminal may use the method of backing off the key by the terminal.
  • the access layer key is restored to the access layer key before the update. Therefore, the purpose of maintaining the same key between the terminal and the source base station is also achieved, and the problem that the terminal cannot be restored due to the key synchronization between the terminal and the source base station can be effectively solved.
  • Step 706 The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
  • the context request message includes a message authentication code and a recovery identifier generated by the terminal, and the context request message is used to request to acquire the context of the terminal.
  • This step is the same as step 305 above, and the foregoing description can be referred to.
  • Step 707 The source base station acquires the context of the terminal if the verification message authentication code is correct.
  • Step 708 The source base station sends a context response message to the target base station if the verification message authentication code is correct.
  • the context response message may include a context of the terminal, for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station.
  • a context of the terminal for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station.
  • the generated KgNB* is also included.
  • Step 709 The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
  • connection recovery response message is used to instruct the terminal to resume the RRC connection.
  • the connection recovery response message may be integrity protected and encrypted by the target base station according to the integrity protection algorithm of the source base station and the integrity protection key and the encryption key generated by the KgNB*.
  • step 709 the subsequent process of the terminal from the inactive state to the connected state is further included.
  • the subsequent process of the terminal from the inactive state to the connected state is further included.
  • the method for restoring the connection as shown in the foregoing steps 701 to 709 can effectively solve the problem that occurs when the message authentication code is generated by the second method in the foregoing step 301.
  • the target base station decides to reject the terminal
  • the target base station sends a connection recovery reject message to the terminal through step 704, and the terminal restores the access layer key of the terminal to the access layer key before the update by step 705, thereby causing the terminal and the source.
  • the keys are always the same between the base stations, so that the problem that the terminal cannot be restored due to the key synchronization between the terminal and the source base station can be effectively solved.
  • connection recovery request message, the connection recovery response message, the connection recovery completion message, the context request message, the context response message, and the like in the foregoing embodiment are only one name, and the name does not limit the message itself.
  • the connection recovery request message, the connection recovery response message, the connection recovery completion message, the context request message, and the context response message may be other names, which are not specifically limited in the embodiment of the present application.
  • the connection recovery request message may also be replaced with a request message, a recovery request message, a connection request message, etc.
  • the connection recovery response message may be replaced with a response message, a recovery response message, a connection response message, etc., and the connection is restored.
  • the completion message may also be replaced with a completion message, a recovery completion message, a connection completion message, etc.
  • the context request message may also be replaced with a request message or the like
  • the context response message may also be replaced with a response message or the like.
  • each of the foregoing network elements includes a hardware structure and/or a software module corresponding to each function.
  • the present invention can be implemented in a combination of hardware or hardware and computer software in combination with the elements and algorithm steps of the various examples described in the embodiments disclosed herein. Whether a function is implemented in hardware or computer software to drive hardware depends on the specific application and design constraints of the solution. A person skilled in the art can use different methods for implementing the described functions for each particular application, but such implementation should not be considered to be beyond the scope of the present invention.
  • FIG. 8 a schematic diagram of a device provided by the present application, which may be a terminal, a target base station, or a source base station, may be implemented by the terminal, the target base station, or the source base station in any of the foregoing embodiments.
  • the apparatus 800 includes at least one processor 801, a transmitter 802, a receiver 803, and optionally a memory 804.
  • the processor 801, the transmitter 802, the receiver 803, and the memory 804 are connected by a communication line.
  • Processor 801 can be a general purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of the program of the present invention.
  • CPU central processing unit
  • ASIC application-specific integrated circuit
  • the communication line can include a path for communicating information between the units.
  • the transmitter 802 and the receiver 803 are configured to communicate with other devices or communication networks.
  • the transmitter and receiver include radio frequency circuits.
  • the memory 804 can be a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a random access memory (RAM) or other type that can store information and instructions.
  • the dynamic storage device may also be an electrically erasable programmabler-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, or a disc storage ( Including compressed optical discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or can be used to carry or store desired program code in the form of instructions or data structures and can be stored by a computer Any other media taken, but not limited to this.
  • EEPROM electrically erasable programmabler-only memory
  • CD-ROM compact disc read-only memory
  • CD-ROM compact disc read-only memory
  • disc storage Including compressed optical discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.
  • the memory 804 may be independent and connected to the processor 801 via a communication line. Memory 804 can also be integrated with the processor.
  • the memory 804 is used to store application code for executing the solution of the present invention, and is controlled by the processor 801 for execution.
  • the processor 801 is configured to execute application code stored in the memory 804.
  • the processor 801 may include one or more CPUs, such as CPU0 and CPU1 in FIG.
  • apparatus 800 can include multiple processors, such as processor 801 and processor 808 in FIG. Each of these processors may be a single-CPU processor or a multi-core processor, where the processor may refer to one or more devices, circuits, and/or A processing core for processing data, such as computer program instructions.
  • the device 800 can be used to implement the steps performed by the terminal in the method of the embodiment of the present invention.
  • the device 800 can perform step 301, step 302, step 304 in FIG. 3 and Step 308, step 401, step 402, step 407, and step 411 in FIG. 4 may also be performed.
  • Step 501, step 502, step 507, and step 511 in FIG. 5 may also be performed, and step 601 in FIG. 6 may also be performed.
  • Step 602, step 607, and step 611, step 701, step 702, step 704, and step 709 in FIG. 7 can also be performed.
  • Related features can be referred to above, and will not be described again here.
  • the device 800 can be used to implement the steps performed by the target base station in the method of the embodiment of the present invention.
  • the device 800 can perform step 302, step 303, step 304, and step in FIG. 305, step 307 and step 308, step 402, step 403, step 404, step 406, step 407, step 408, step 410 and step 411 in FIG. 4 may also be performed, and step 502 and step 503 in FIG. 5 may also be performed.
  • Step 504, step 506, step 507, step 508, step 510, and step 511, step 602, step 603, step 604, step 606, step 607, step 608, step 610, and step 611 in FIG. 6 may also be performed.
  • Step 702, step 703, step 704, step 706, step 708, and step 709 in FIG. 7 can also be performed.
  • Related features can be referred to above, and will not be described again here.
  • the device 800 can be used to implement the steps performed by the source base station in the method of the embodiment of the present invention.
  • the device 800 can perform step 305, step 306, and step 307 in FIG. 3, Step 404, step 405, step 406, step 408, step 409, and step 410 in FIG. 4 may also be performed, and step 504, step 505, step 506, step 508, step 509, and step 510 in FIG. 5 may also be performed.
  • Step 604, step 605, step 606, step 608, step 609, and step 610 in FIG. 6 may also be performed, and step 706, step 707, and step 708 in FIG. 7 may also be performed, and related features may be referred to above. I will not repeat them here.
  • the application may divide the function module into the terminal according to the above method example.
  • each function module may be divided according to each function, or two or more functions may be integrated into one processing module.
  • the above integrated modules can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the present application is schematic, and is only a logical function division, and may be further divided in actual implementation.
  • FIG. 9 shows a schematic diagram of a device, which may be the terminal involved in the above embodiment, and the device 900 includes a processing unit 901 and a transmitting unit 903. .
  • a receiving unit 902 is further included.
  • the processing unit 901 is configured to generate a message authentication code according to the freshness parameter and the integrity protection key of the device, where the freshness parameter used in generating the message authentication code twice is different;
  • the sending unit 903 is configured to send a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, and the connection recovery request message is used to request to resume the radio resource control RRC connection.
  • the freshness parameter includes a number of rejections, the number of rejections being used to indicate the number of times the device is rejected when attempting to resume the RRC connection.
  • the receiving unit 902 is configured to receive a connection recovery response message from the target base station, where the connection recovery response message is used to instruct the terminal to resume the RRC connection.
  • connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
  • the freshness parameter includes a packet data convergence protocol count PDCPCOUNT
  • the indication parameter includes part or all of the bits of the PDCP COUNT.
  • the terminal may be used to implement the steps performed by the terminal in the method of the embodiment of the present invention.
  • the terminal may be used to implement the steps performed by the terminal in the method of the embodiment of the present invention.
  • the application may perform the division of the function modules on the target base station according to the foregoing method example.
  • each function module may be divided according to each function, or two or more functions may be integrated into one processing module.
  • the above integrated modules can be implemented in the form of hardware or in the form of software functional modules.
  • the division of modules in the present application is schematic, and is only a logical function division, and may be further divided in actual implementation.
  • FIG. 10 shows a schematic diagram of a device, which may be the target base station involved in the above embodiment, and the device 1000 includes a receiving unit 1001 and a transmitting unit. 1002.
  • the receiving unit 1001 is configured to receive a connection recovery request message from a terminal, where the connection recovery request message includes a message authentication code, where the connection recovery request message is used to request to restore a radio resource control RRC connection, where the message authentication code is Generating according to the integrity protection key of the terminal;
  • the sending unit 1002 is configured to: if the RRC connection is refused to be restored, send a notification message to the source base station, where the notification message includes the message authentication code.
  • the notification message has one or more of the following functions:
  • the notification message is used to notify the update of the context of the terminal in the source base station;
  • the notification message is used to notify the target base station that the terminal is refused to resume the connection;
  • the notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
  • the notification message is used to notify the key of the context of the terminal in the update source base station.
  • the notification message notifies that the updated context of the terminal includes an access layer key.
  • the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where the notification message notifies that the updated context of the terminal includes the freshness parameter
  • the freshness parameters used to generate the message authentication code two times are different.
  • connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, and the notification message further includes the indication parameter.
  • the freshness parameter includes a PDCP COUNT
  • the indication parameter includes part or all of the bits of the PDCP COUNT.
  • the freshness parameter includes a number of rejections, the number of rejections being used to indicate the number of times the device is rejected when attempting to resume the RRC connection.
  • the receiving unit 1001 is configured to receive a connection recovery request message from a terminal, where the connection recovery request message includes a message authentication code, where the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal.
  • the freshness parameter used in generating the message authentication code twice is different, and the connection recovery request message is used to request to resume the radio resource control RRC connection;
  • the sending unit 1002 is configured to: if the RRC connection is restored, send a context request message to the source base station, where the context request message includes the message authentication code, where the context request message is used to request to acquire the context of the terminal. .
  • connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, and the context request message further includes the indication parameter.
  • the freshness parameter includes a packet data convergence protocol PDCP count COUNT
  • the indication parameter includes part or all of the bits of the PDCP COUNT.
  • the freshness parameter includes a number of rejections, the number of rejections being used to indicate the number of times the device is rejected when attempting to resume the RRC connection.
  • target base station may be used to implement the steps performed by the target base station in the method of the embodiment of the present invention.
  • reference may be made to the above, and details are not described herein again.
  • the application may divide the function modules of the source base station according to the foregoing method example.
  • each function module may be divided according to each function, or two or more functions may be integrated into one processing module.
  • the above integrated modules can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the present application is schematic, and is only a logical function division, and may be further divided in actual implementation.
  • FIG. 11 shows a schematic diagram of a device, which may be the source base station involved in the above embodiment, and the device 1100 includes a processing unit 1101 and a receiving unit. 1102 and a transmitting unit 1103.
  • the receiving unit 1102 is configured to receive a notification message from a target base station, where the notification message includes a message authentication code, where the message authentication code is generated according to an integrity protection key of the terminal;
  • the processing unit 1101 is configured to check the message authentication code according to the integrity protection key of the source base station, and to update the source base station if the message authentication code is correct The context of the terminal.
  • the notification message has one or more of the following functions:
  • the notification message is used to notify the update of the context of the terminal in the source base station;
  • the notification message is used to notify the target base station that the terminal is refused to resume the connection;
  • the notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
  • the notification message is used to notify the key of the context of the terminal in the update source base station.
  • the processing unit 1101 is specifically configured to update an access layer key in a context of the terminal in the source base station.
  • the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where a freshness parameter used by generating a message authentication code twice is different;
  • the processing unit 1101 is specifically configured to check the message authentication code according to the freshness parameter and an integrity protection key of the source base station.
  • the notification message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
  • the freshness parameter includes a packet data convergence protocol, which is a PDCP COUNT
  • the processing unit 1101 is configured to update a context of the terminal in the source base station, and specifically includes:
  • the value of the PDCP COUNT is greater than the value of the PDCP COUNT in the context of the terminal, the value of the PDCP COUNT in the context of the terminal is updated to the value of the PDCP COUNT indicated by the indication parameter.
  • the freshness parameter includes a number of rejections, the number of rejections being used to indicate the number of times the device is rejected when attempting to resume the RRC connection.
  • the processing unit 1101 is specifically configured to increase the number of rejections of the context of the terminal by one.
  • the receiving unit 1102 is configured to receive a context request message from a target base station, where the context request message includes a message authentication code, where the message authentication code is generated according to the freshness parameter and an integrity protection key of the terminal.
  • the freshness parameter used by the neighboring two generation message authentication codes is different, and the context request message is used to request to acquire the context of the terminal;
  • the processing unit 1101 is configured to check the message authentication code according to the freshness parameter and the integrity protection key of the source base station; and, if used to verify that the message authentication code is correct, update Freshness parameters in the context of the terminal;
  • the sending unit 1103 is configured to send a context response message to the target base station, where the context response message includes a context of the terminal.
  • the context request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, and the freshness parameter includes a PDCP COUNT; the processing unit 1101 is configured according to the update.
  • the context of the terminal in the source base station specifically includes:
  • the value of the PDCP COUNT is greater than the value of the PDCP COUNT in the context of the terminal, the value of the PDCP COUNT in the context of the terminal is updated to the value of the PDCP COUNT indicated by the indication parameter.
  • the indication parameter includes a partial bit of the PDCP COUNT; the processing unit 1101 is further configured to: determine, according to the indication parameter, the PDCP COUNT indicated by the indication parameter.
  • the freshness parameter includes a number of rejections
  • the number of rejections is used to indicate a number of times the device attempts to recover the RRC connection
  • the processing unit 1101 is configured to update according to the update.
  • the context of the terminal in the source base station includes: resetting the number of rejections in the context of the terminal to zero.
  • the source base station may be used to implement the steps performed by the source base station in the method of the embodiment of the present invention.
  • reference may be made to the above, and details are not described herein again.
  • the above embodiments it may be implemented in whole or in part by software, hardware, firmware or any combination thereof.
  • software it may be implemented in whole or in part in the form of a computer program product.
  • the computer program product includes one or more computer instructions.
  • the computer program instructions When the computer program instructions are loaded and executed on a computer, the processes or functions described in accordance with embodiments of the present invention are generated in whole or in part.
  • the computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable device.
  • the computer instructions can be stored in a computer readable storage medium or transferred from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions can be from a website site, computer, server or data center Transfer to another website site, computer, server, or data center by wire (eg, coaxial cable, fiber optic, digital subscriber line (DSL), or wireless (eg, infrared, wireless, microwave, etc.).
  • the computer readable storage medium can be any available media that can be accessed by a computer or a data storage device such as a server, data center, or the like that includes one or more available media.
  • the usable medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a DVD), or a semiconductor medium (such as a Solid State Disk (SSD)) or the like.
  • a magnetic medium eg, a floppy disk, a hard disk, a magnetic tape
  • an optical medium eg, a DVD
  • a semiconductor medium such as a Solid State Disk (SSD)
  • the above embodiments it may be implemented in whole or in part by software, hardware, firmware, or any combination thereof.
  • software it may be implemented in whole or in part in the form of a computer program product.
  • the computer program product includes one or more computer instructions.
  • the computer program instructions When the computer program instructions are loaded and executed on a computer, the processes or functions described in accordance with embodiments of the present invention are generated in whole or in part.
  • the computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable device.
  • the computer instructions can be stored in a computer readable storage medium or transferred from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions can be from a website site, computer, server or data center Transfer to another website site, computer, server, or data center by wire (eg, coaxial cable, fiber optic, digital subscriber line (DSL), or wireless (eg, infrared, wireless, microwave, etc.).
  • the computer readable storage medium can be any available media that can be accessed by a computer or a data storage device such as a server, data center, or the like that includes one or more available media.
  • the usable medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a DVD), or a semiconductor medium (such as a Solid State Disk (SSD)) or the like.
  • a magnetic medium eg, a floppy disk, a hard disk, a magnetic tape
  • an optical medium eg, a DVD
  • a semiconductor medium such as a Solid State Disk (SSD)
  • embodiments of the present application can be provided as a method, apparatus (device), computer readable storage medium, or computer program product.
  • the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or a combination of software and hardware aspects, which are collectively referred to herein as "module” or "system.”

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

Provided are a method and device for requesting connection recovery. The method comprises: a terminal generating a message authentication code according to a freshness parameter and an integrity protection key of the terminal, wherein the freshness parameters used for two adjacent generations of message authentication codes are different; and the terminal sending a connection recovery request message to a target base station, the connection recovery request message comprising the message authentication code, and the connection recovery request message being used for requesting the recovery of radio resource control (RRC) connection. Since a message authentication code generated by a terminal each time is different from the message authentication code generated last time, even if an attacker steals the message authentication code used by the terminal last time, due to the "expired" message authentication code used, the attacker cannot attack successfully.

Description

一种请求恢复连接的方法及装置Method and device for requesting restoration of connection
本申请要求在2017年11月16日提交中华人民共和国知识产权局、申请号为201711138495.4、发明名称为“一种请求恢复连接的方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中,以及,要求在2018年2月13日提交中华人民共和国知识产权局、申请号为201810149050.4、发明名称为“一种请求恢复连接的方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese Patent Application filed on November 16, 2017, the disclosure of which is hereby incorporated by reference. In the present application, as well as the priority of the Chinese patent application filed on February 13, 2018, submitted to the Intellectual Property Office of the People's Republic of China, application number 201810149050.4, and the invention name "a method and apparatus for requesting restoration of connection" The entire content of which is incorporated herein by reference.
技术领域Technical field
本申请涉及移动通信技术领域,尤其涉及一种请求恢复连接的方法及装置。The present application relates to the field of mobile communications technologies, and in particular, to a method and apparatus for requesting to restore a connection.
背景技术Background technique
在长期演进(long term evolution,LTE)中,挂起和恢复流程可用于窄带-物联网(narrowband internet of things,NB-IoT)的终端,即移动性较低或耗电低的物联网设备,如智能水表。In long term evolution (LTE), the suspend and resume process can be used for narrowband internet of things (NB-IoT) terminals, ie, IoT devices with low mobility or low power consumption. Such as smart water meters.
当基站以挂起的方式通知终端释放当前连接时,终端和基站会删除部分接入层的上下文,以及还会保留部分接入层的上下文,如接入层密钥,终端的安全能力,当前选择的安全算法等。然后终端从连接态进入不活跃态。当终端希望恢复与基站的连接时,可以快速地从不活跃态恢复到连接态。When the base station informs the terminal to release the current connection in a suspended manner, the terminal and the base station delete the context of the part of the access layer, and also retain the context of the part of the access layer, such as the access layer key, the security capability of the terminal, and the current Selected security algorithms, etc. The terminal then enters an inactive state from the connected state. When the terminal wishes to resume the connection with the base station, it can quickly recover from the inactive state to the connected state.
第五代(5th generation,5G)系统及未来的通信系统中,可以扩展上述服务流程,将挂起和恢复流程应用到增强移动带宽(enhanced mobile broadband,eMBB)的终端,如智能手机。In the fifth generation (5th generation, 5G) system and future communication systems, the above service flow can be extended to apply the suspend and resume process to an enhanced mobile broadband (eMBB) terminal such as a smart phone.
由于终端的移动性较高,因而终端所接入的基站可能发生改变。进一步地,基站在服务终端时,会考虑负载均衡的场景。例如,当终端请求从不活跃态恢复到连接态时,若终端当前想要接入的基站的负载较重,则该基站将会拒绝该终端的接入,即拒绝该终端的连接恢复请求,并通知该终端休息一段时间后再尝试连接。Due to the high mobility of the terminal, the base station to which the terminal is connected may change. Further, when the base station serves the terminal, a scenario of load balancing is considered. For example, when the terminal requests to recover from the inactive state to the connected state, if the load of the base station that the terminal currently wants to access is heavy, the base station will reject the access of the terminal, that is, reject the connection recovery request of the terminal. And notify the terminal to rest for a while before trying to connect.
在上述场景下,由于终端在第一次请求恢复连接被拒绝后,终端所发送的认证信息有可能被攻击者获取到,然后攻击者利用获取到的认证信息,向该基站请求建立连接,进而可能造成攻击。In the above scenario, after the terminal requests that the connection is rejected for the first time, the authentication information sent by the terminal may be acquired by the attacker, and then the attacker uses the obtained authentication information to request the connection to establish a connection. May cause an attack.
因此,在上述场景下,如何有效抵御攻击者的攻击,是亟需解决的问题。Therefore, in the above scenario, how to effectively defend against an attacker's attack is an urgent problem to be solved.
发明内容Summary of the invention
本申请提供一种请求恢复连接的方法及装置,用以有效抵御攻击者的攻击。The present application provides a method and apparatus for requesting a recovery connection to effectively defend against an attacker's attack.
第一方面,本申请提供一种请求恢复连接的方法,包括:终端根据新鲜性参数和所述终端的完整性保护密钥,生成消息认证码,其中,相邻两次生成消息认证码所使用的新鲜性参数不同;所述终端向目标基站发送连接恢复请求消息,所述连接恢复请求消息包括所述消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接。In a first aspect, the present application provides a method for requesting a connection to restore, comprising: generating, by a terminal, a message authentication code according to a freshness parameter and an integrity protection key of the terminal, where the message authentication code is generated by two adjacent messages. The freshness parameter is different; the terminal sends a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, and the connection recovery request message is used to request to resume the radio resource control RRC connection.
由于终端每次生成的消息认证码与上次生成的消息认证码不同,因此,即使攻击 者窃取到终端上次所使用的消息认证码,由于使用的“过期的”消息认证码,因此,攻击者将无法攻击成功。Since the message authentication code generated by the terminal is different from the message authentication code generated last time, even if the attacker steals the message authentication code used by the terminal last time, due to the "expired" message authentication code used, the attack is Will not be able to attack successfully.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述终端尝试恢复所述RRC连接时被拒绝的次数。在一种可能的实现方式中,所述连接恢复请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数。In a possible implementation manner, the freshness parameter includes a number of rejections, and the number of rejections is used to indicate the number of times the terminal is rejected when attempting to resume the RRC connection. In a possible implementation manner, the connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
在一个示例中,所述新鲜性参数包括分组数据汇聚协议计数PDCP COUNT,所述指示参数包括所述PDCP COUNT的部分或全部比特位。In one example, the freshness parameter includes a packet data convergence protocol count PDCP COUNT, the indication parameter including some or all of the bits of the PDCP COUNT.
在一种可能的实现方式中,所述终端接收来自所述目标基站的连接恢复响应消息,所述连接恢复响应消息用于指示所述终端恢复所述RRC连接。In a possible implementation manner, the terminal receives a connection recovery response message from the target base station, where the connection recovery response message is used to instruct the terminal to resume the RRC connection.
第二方面,本申请提供一种请求恢复连接的方法,包括:目标基站接收来自终端的连接恢复请求消息,所述连接恢复请求消息包括消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接,所述消息认证码是根据所述终端的完整性保护密钥生成的;所述目标基站若拒绝恢复所述RRC连接,则向源基站发送通知消息,所述通知消息包括所述消息认证码。In a second aspect, the present application provides a method for requesting a connection to restore, comprising: receiving, by a target base station, a connection recovery request message from a terminal, where the connection recovery request message includes a message authentication code, and the connection recovery request message is used to request to resume wireless The resource control RRC connection, the message authentication code is generated according to the integrity protection key of the terminal; if the target base station refuses to restore the RRC connection, sending a notification message to the source base station, where the notification message includes The message authentication code.
其中,通知消息具有以下功能中的一个或多个:Wherein, the notification message has one or more of the following functions:
通知消息用于通知更新所述源基站中的所述终端的上下文;The notification message is used to notify the update of the context of the terminal in the source base station;
通知消息用于通知所述目标基站将拒绝所述终端恢复连接;The notification message is used to notify the target base station that the terminal is refused to resume the connection;
通知消息用于通知更新所述源基站中的所述终端的上下文的所述新鲜性参数;The notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
通知消息用于通知更新所述源基站中的所述终端的上下文的密钥。The notification message is used to notify the key of updating the context of the terminal in the source base station.
上述方法,当目标基站拒绝恢复RRC连接时,还通知源基站更新终端的上下文,从而可以保持终端与源基站之间的上下文一致,有助于降低终端从不活跃态进入连接态的失败概率。In the foregoing method, when the target base station refuses to restore the RRC connection, the source base station is further notified to update the context of the terminal, so that the context between the terminal and the source base station can be kept consistent, which helps reduce the probability of the terminal entering the connected state from the inactive state.
在一种可能的实现方式中,所述通知消息通知更新的所述终端的上下文包括接入层密钥。In a possible implementation manner, the notification message notifies that the updated context of the terminal includes an access layer key.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述终端尝试恢复所述RRC连接时被拒绝的次数。In a possible implementation manner, the freshness parameter includes a number of rejections, and the number of rejections is used to indicate the number of times the terminal is rejected when attempting to resume the RRC connection.
在一种可能的实现方式中,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,所述通知消息通知更新的所述终端的上下文包括所述新鲜性参数,其中,相邻两次生成消息认证码所使用的新鲜性参数不同。In a possible implementation manner, the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where the notification message notifies that the updated context of the terminal includes the freshness parameter Wherein, the freshness parameters used to generate the message authentication code two times are different.
在这种实现方式中,所述连接恢复请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数,所述通知消息还包括所述指示参数。在一个示例中,所述新鲜性参数包括PDCP COUNT,所述指示参数包括所述PDCP COUNT的部分或全部比特位。In this implementation manner, the connection recovery request message further includes an indication parameter, the indication parameter is used to indicate the freshness parameter, and the notification message further includes the indication parameter. In one example, the freshness parameter includes a PDCP COUNT, the indication parameter including some or all of the bits of the PDCP COUNT.
第三方面,本申请提供一种请求恢复连接的方法,包括:目标基站接收来自终端的连接恢复请求消息,所述连接恢复请求消息包括消息认证码,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;所述目标基站若恢复所述RRC连接,则向源基站发送上下文请求消息,所述上下文请求消息包括所述消息认证码,所述上下文请求消息用于请求获取所述终端的上下文。In a third aspect, the present application provides a method for requesting a connection to restore, comprising: receiving, by a target base station, a connection recovery request message from a terminal, where the connection recovery request message includes a message authentication code, and the message authentication code is based on a freshness parameter and The integrity protection key of the terminal is generated, wherein the freshness parameter used by the two adjacent generation message authentication codes is different, and the connection recovery request message is used to request to restore the radio resource control RRC connection; the target base station If the RRC connection is restored, the context request message is sent to the source base station, where the context request message includes the message authentication code, and the context request message is used to request to acquire the context of the terminal.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述终端尝试恢复所述RRC连接时被拒绝的次数。In a possible implementation manner, the freshness parameter includes a number of rejections, and the number of rejections is used to indicate the number of times the terminal is rejected when attempting to resume the RRC connection.
在一种可能的实现方式中,所述连接恢复请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数,所述上下文请求消息还包括所述指示参数。In a possible implementation manner, the connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, and the context request message further includes the indication parameter.
在一个示例中,所述新鲜性参数包括分组数据汇聚协议PDCP计数COUNT,所述指示参数包括所述PDCP COUNT的部分或全部比特位。In one example, the freshness parameter includes a packet data convergence protocol PDCP count COUNT, the indication parameter including some or all of the bits of the PDCP COUNT.
第四方面,本申请提供一种请求恢复连接的方法,包括:源基站接收来自目标基站的通知消息,所述通知消息包括消息认证码所述消息认证码是根据所述终端的完整性保护密钥生成的;In a fourth aspect, the application provides a method for requesting to restore a connection, including: receiving, by a source base station, a notification message from a target base station, where the notification message includes a message authentication code, and the message authentication code is based on integrity protection of the terminal. Key generated
所述源基站根据所述源基站的完整性保护密钥,校验所述消息认证码;The source base station verifies the message authentication code according to the integrity protection key of the source base station;
所述源基站若校验所述消息认证码正确,则更新所述源基站中的所述终端的上下文。And if the source base station verifies that the message authentication code is correct, updating the context of the terminal in the source base station.
上述方法,当目标基站拒绝恢复RRC连接时,还通知源基站更新终端的上下文,从而源基站更新终端的上下文,可使得源基站保持与终端的上下文一致,有助于降低终端从不活跃态进入连接态的失败概率。In the foregoing method, when the target base station refuses to restore the RRC connection, the source base station is further notified to update the context of the terminal, so that the source base station updates the context of the terminal, so that the source base station remains consistent with the context of the terminal, which helps to reduce the terminal from entering the inactive state. The probability of failure of the connected state.
其中,通知消息具有以下功能中的一个或多个:Wherein, the notification message has one or more of the following functions:
通知消息用于通知更新所述源基站中的所述终端的上下文;The notification message is used to notify the update of the context of the terminal in the source base station;
通知消息用于通知所述目标基站将拒绝所述终端恢复连接;The notification message is used to notify the target base station that the terminal is refused to resume the connection;
通知消息用于通知更新所述源基站中的所述终端的上下文的所述新鲜性参数;The notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
通知消息用于通知更新所述源基站中的所述终端的上下文的密钥。The notification message is used to notify the key of updating the context of the terminal in the source base station.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述终端尝试恢复所述RRC连接时被拒绝的次数。In a possible implementation manner, the freshness parameter includes a number of rejections, and the number of rejections is used to indicate the number of times the terminal is rejected when attempting to resume the RRC connection.
在一个示例中,所述源基站更新所述源基站中的所述终端的上下文,包括:所述源基站将所述终端的上下文的拒绝次数加1。In an example, the source base station updates a context of the terminal in the source base station, including: the source base station increments a number of rejections of a context of the terminal by one.
在一种可能的实现方式中,所述源基站更新所述源基站中的所述终端的上下文,包括:所述源基站更新所述终端的上下文中的接入层密钥。In a possible implementation manner, the source base station updates a context of the terminal in the source base station, where the source base station updates an access layer key in a context of the terminal.
在一种可能的实现方式中,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同;所述源基站根据所述源基站的完整性保护密钥,校验所述消息认证码,包括:所述源基站根据所述新鲜性参数和所述源基站的完整性保护密钥,校验所述消息认证码。In a possible implementation manner, the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where a freshness parameter used by generating a message authentication code twice is different; And verifying, by the source base station, the message authentication code according to the integrity protection key of the source base station, where the source base station performs verification according to the freshness parameter and the integrity protection key of the source base station. The message authentication code.
在一种可能的实现方式中,所述通知消息还包括指示参数,所述指示参数用于指示所述新鲜性参数。In a possible implementation manner, the notification message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
在一个示例中,所述新鲜性参数包括分组数据汇聚协议计数PDCP COUNT,所述源基站更新所述源基站中的所述终端的上下文,包括:若所述PDCP COUNT的数值大于所述终端的上下文中的PDCP COUNT的数值,则所述源基站将所述终端的上下文中的PDCP COUNT的数值更新为所述指示参数指示的PDCP COUNT的数值。In one example, the freshness parameter includes a packet data convergence protocol count PDCP COUNT, and the source base station updates a context of the terminal in the source base station, including: if the value of the PDCP COUNT is greater than the terminal The value of the PDCP COUNT in the context, the source base station updates the value of the PDCP COUNT in the context of the terminal to the value of the PDCP COUNT indicated by the indication parameter.
第五方面,本申请提供一种请求恢复连接的方法,包括:源基站接收来自目标基站的上下文请求消息,所述上下文请求消息包括消息认证码,所述消息认证码是根据所述新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同,所述上下文请求消息用于请求获取所述终端的上下文; 所述源基站根据所述新鲜性参数和所述源基站的完整性保护密钥,校验所述消息认证码;所述源基站若校验所述消息认证码正确,则更新所述终端的上下文中的新鲜性参数,以及向所述目标基站发送上下文响应消息,所述上下文响应消息包括所述终端的上下文。In a fifth aspect, the application provides a method for requesting a connection to restore, comprising: receiving, by a source base station, a context request message from a target base station, where the context request message includes a message authentication code, and the message authentication code is according to the freshness parameter And the freshness protection key generated by the integrity protection key of the terminal, where the freshness parameter used in generating the message authentication code is different, the context request message is used to request to acquire the context of the terminal; And verifying the message authentication code according to the freshness parameter and the integrity protection key of the source base station; if the source base station verifies that the message authentication code is correct, updating the freshness in the context of the terminal And a context response message to the target base station, the context response message including a context of the terminal.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述终端尝试恢复所述RRC连接时被拒绝的次数;所述源基站根据更新所述源基站中的所述终端的上下文,包括:所述源基站将所述终端的上下文中的拒绝次数重置为零。In a possible implementation manner, the freshness parameter includes a number of rejections, where the number of rejections is used to indicate a number of times the terminal attempts to recover the RRC connection, and the source base station updates the source base station according to the source station. The context of the terminal in the method includes: the source base station resetting the number of rejections in the context of the terminal to zero.
在一种可能的实现方式中,所述上下文请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数,所述新鲜性参数包括PDCP COUNT;所述源基站更新所述源基站中的所述终端的上下文,包括:若所述PDCP COUNT的数值大于所述终端的上下文中的PDCP COUNT的数值,则所述源基站将所述终端的上下文中的PDCP COUNT的数值更新为所述指示参数指示的PDCP COUNT的数值。In a possible implementation manner, the context request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, the freshness parameter includes a PDCP COUNT; and the source base station updates the source base station The context of the terminal in the method includes: if the value of the PDCP COUNT is greater than the value of the PDCP COUNT in the context of the terminal, the source base station updates the value of the PDCP COUNT in the context of the terminal to The value of the PDCP COUNT indicated by the indication parameter.
在一个示例中,所述指示参数包括所述PDCP COUNT的部分比特位;所述源基站根据所述指示参数,确定所述指示参数指示的所述PDCP COUNT。In one example, the indication parameter includes a partial bit of the PDCP COUNT; the source base station determines the PDCP COUNT indicated by the indication parameter according to the indication parameter.
第六方面,本申请提供一种装置,该装置可以是终端,也可以是终端内的芯片。该装置具有实现上述第一方面的各实施例的功能。该功能可以通过硬件实现,也可以通过硬件执行相应的软件实现。该硬件或软件包括一个或多个与上述功能相对应的模块。In a sixth aspect, the present application provides a device, which may be a terminal or a chip in a terminal. The device has the functionality to implement the various embodiments of the first aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software. The hardware or software includes one or more modules corresponding to the functions described above.
在一种可能的设计中,当该装置为终端时,终端包括:发送单元和处理单元,可选地,还包括接收单元。处理单元例如可以是处理器,接收单元例如可以是接收器,发送单元,例如可以是发送器。接收器和发送器包括射频电路。可选地,终端还包括存储单元,该存储单元例如可以是存储器。当终端包括存储单元时,该存储单元存储有计算机执行指令,处理单元与存储单元连接,处理单元执行存储单元存储的计算机执行指令,以使该终端执行上述第一方面任意一项的请求恢复连接的方法。In a possible design, when the device is a terminal, the terminal includes: a transmitting unit and a processing unit, and optionally, a receiving unit. The processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter. The receiver and transmitter include radio frequency circuits. Optionally, the terminal further comprises a storage unit, which may be, for example, a memory. When the terminal includes a storage unit, the storage unit stores a computer execution instruction, the processing unit is connected to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit, so that the terminal performs the request to restore the connection according to any one of the foregoing first aspects. Methods.
在另一种可能的设计中,当该装置为终端内的芯片时,芯片包括:发送单元和处理单元,可选地,还包括接收单元。处理单元例如可以是处理电路,接收单元例如可以是输入接口、管脚或电路等,发送单元例如可以是输出接口、管脚或电路等。该处理单元可执行存储单元存储的计算机执行指令,以使上述第一方面任意一项的请求恢复连接的方法被执行。可选地,存储单元可以是芯片内的存储单元,如寄存器、缓存等,存储单元还可以是终端内的位于芯片外部的存储单元,如只读存储器(read-only memory,ROM)、可存储静态信息和指令的其他类型的静态存储设备、随机存取存储器(random access memory,RAM)等。In another possible design, when the device is a chip in the terminal, the chip includes: a transmitting unit and a processing unit, and optionally, a receiving unit. The processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc., and the transmitting unit can be, for example, an output interface, a pin or a circuit. The processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of restoring the connection of any of the above-described first aspects to be performed. Optionally, the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a read-only memory (ROM), and may be stored. Other types of static storage devices, random access memory (RAM), etc. for static information and instructions.
其中,上述任一处提到的处理器,可以是一个通用的中央处理器(Central Processing Unit,CPU),微处理器,特定应用集成电路(application-specific integrated circuit,ASIC),或一个或多个用于控制上述第一方面任意一项的请求恢复连接的方法的程序执行的集成电路。The processor mentioned in any of the above may be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more A program-implemented integrated circuit for controlling a method of requesting a resume connection of any of the above first aspects.
第七方面,本申请提供一种装置,该装置可以是目标基站,也可以是目标基站内的芯片。该装置具有实现上述第二方面的各实施例的功能。该功能可以通过硬件实现,也可以通过硬件执行相应的软件实现。该硬件或软件包括一个或多个与上述功能相对 应的模块。In a seventh aspect, the application provides a device, which may be a target base station or a chip in a target base station. The device has the functionality to implement the various embodiments of the second aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software. The hardware or software includes one or more modules corresponding to the functions described above.
在一种可能的设计中,当该装置为目标基站时,基站包括:接收单元和发送单元,可选地,还包括处理单元。处理单元例如可以是处理器,接收单元例如可以是接收器,发送单元,例如可以是发送器。接收器和发送器包括射频电路。可选地,基站还包括存储单元,该存储单元例如可以是存储器。当基站包括存储单元时,该存储单元存储有计算机执行指令,处理单元与存储单元连接,处理单元执行存储单元存储的计算机执行指令,以使该基站执行上述第二方面任意一项的请求恢复连接的方法。In a possible design, when the device is a target base station, the base station includes: a receiving unit and a sending unit, and optionally, a processing unit. The processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter. The receiver and transmitter include radio frequency circuits. Optionally, the base station further comprises a storage unit, which may be, for example, a memory. When the base station includes a storage unit, the storage unit stores a computer execution instruction, the processing unit is coupled to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit to cause the base station to perform the request to restore the connection according to any one of the foregoing second aspects. Methods.
在另一种可能的设计中,当该装置为目标基站内的芯片时,芯片包括:接收单元和发送单元,可选地,还包括处理单元。处理单元例如可以是处理电路,接收单元例如可以是输入接口、管脚或电路等,发送单元例如可以是输出接口、管脚或电路等。该处理单元可执行存储单元存储的计算机执行指令,以使上述第二方面任意一项的请求恢复连接的方法被执行。可选地,存储单元可以是芯片内的存储单元,如寄存器、缓存等,存储单元还可以是终端内的位于芯片外部的存储单元,如只ROM、可存储静态信息和指令的其他类型的静态存储设备、RAM等。In another possible design, when the device is a chip in a target base station, the chip includes: a receiving unit and a transmitting unit, and optionally, a processing unit. The processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc., and the transmitting unit can be, for example, an output interface, a pin or a circuit. The processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of restoring the connection of any of the above-described second aspects to be performed. Optionally, the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM only, other types of statics that can store static information and instructions. Storage device, RAM, etc.
其中,上述任一处提到的处理器,可以是一个通用的CPU,微处理器,ASIC,或一个或多个用于控制上述第二方面任意一项的请求恢复连接的方法的程序执行的集成电路。Wherein, the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or a program executed by one or more methods for controlling the connection recovery request of any of the above second aspects. integrated circuit.
第八方面,本申请提供一种装置,该装置可以是目标基站,也可以是目标基站内的芯片。该装置具有实现上述第三方面的各实施例的功能。该功能可以通过硬件实现,也可以通过硬件执行相应的软件实现。该硬件或软件包括一个或多个与上述功能相对应的模块。In an eighth aspect, the present application provides an apparatus, which may be a target base station or a chip in a target base station. The device has the functionality to implement the various embodiments of the third aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software. The hardware or software includes one or more modules corresponding to the functions described above.
在一种可能的设计中,当该装置为目标基站时,基站包括:接收单元和发送单元,可选地,还包括处理单元。处理单元例如可以是处理器,接收单元例如可以是接收器,发送单元,例如可以是发送器。接收器和发送器包括射频电路。可选地,基站还包括存储单元,该存储单元例如可以是存储器。当基站包括存储单元时,该存储单元存储有计算机执行指令,处理单元与存储单元连接,处理单元执行存储单元存储的计算机执行指令,以使该基站执行上述第三方面任意一项的请求恢复连接的方法。In a possible design, when the device is a target base station, the base station includes: a receiving unit and a sending unit, and optionally, a processing unit. The processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter. The receiver and transmitter include radio frequency circuits. Optionally, the base station further comprises a storage unit, which may be, for example, a memory. When the base station includes a storage unit, the storage unit stores a computer execution instruction, the processing unit is connected to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit, so that the base station performs the request to restore the connection according to any one of the foregoing third aspects. Methods.
在另一种可能的设计中,当该装置为目标基站内的芯片时,芯片包括:接收单元和发送单元,可选地,还包括处理单元。处理单元例如可以是处理电路,接收单元例如可以是输入接口、管脚或电路等,发送单元例如可以是输出接口、管脚或电路等。该处理单元可执行存储单元存储的计算机执行指令,以使上述第三方面任意一项的请求恢复连接的方法被执行。可选地,存储单元可以是芯片内的存储单元,如寄存器、缓存等,存储单元还可以是终端内的位于芯片外部的存储单元,如只ROM、可存储静态信息和指令的其他类型的静态存储设备、RAM等。In another possible design, when the device is a chip in a target base station, the chip includes: a receiving unit and a transmitting unit, and optionally, a processing unit. The processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc., and the transmitting unit can be, for example, an output interface, a pin or a circuit. The processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of restoring the connection of any of the above-described third aspects to be performed. Optionally, the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM only, other types of statics that can store static information and instructions. Storage device, RAM, etc.
其中,上述任一处提到的处理器,可以是一个通用的CPU,微处理器,ASIC,或一个或多个用于控制上述第三方面任意一项的请求恢复连接的方法的程序执行的集成电路。Wherein, the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or a program executed by one or more methods for controlling the connection recovery request of any of the above third aspects. integrated circuit.
第九方面,本申请提供一种装置,该装置可以是源基站,也可以是源基站内的芯片。该装置具有实现上述第四方面的各实施例的功能。该功能可以通过硬件实现,也可以通过硬件执行相应的软件实现。该硬件或软件包括一个或多个与上述功能相对应 的模块。In a ninth aspect, the present application provides an apparatus, which may be a source base station or a chip in a source base station. The device has the functionality to implement the various embodiments of the fourth aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software. The hardware or software includes one or more modules corresponding to the functions described above.
在一种可能的设计中,当该装置为源基站时,基站包括:接收单元和发送单元,可选地,还包括处理单元。处理单元例如可以是处理器,接收单元例如可以是接收器,发送单元,例如可以是发送器。接收器和发送器包括射频电路。可选地,基站还包括存储单元,该存储单元例如可以是存储器。当基站包括存储单元时,该存储单元存储有计算机执行指令,处理单元与存储单元连接,处理单元执行存储单元存储的计算机执行指令,以使该基站执行上述第四方面任意一项的请求恢复连接的方法。In a possible design, when the device is a source base station, the base station includes: a receiving unit and a transmitting unit, and optionally, a processing unit. The processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter. The receiver and transmitter include radio frequency circuits. Optionally, the base station further comprises a storage unit, which may be, for example, a memory. When the base station includes a storage unit, the storage unit stores a computer execution instruction, the processing unit is coupled to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit to cause the base station to perform the request to restore the connection according to any one of the foregoing fourth aspects. Methods.
在另一种可能的设计中,当该装置为源基站内的芯片时,芯片包括:接收单元和发送单元,可选地,还包括处理单元。处理单元例如可以是处理电路,接收单元例如可以是输入接口、管脚或电路等,发送单元例如可以是输出接口、管脚或电路等。该处理单元可执行存储单元存储的计算机执行指令,以使上述第四方面任意一项的请求恢复连接的方法被执行。可选地,存储单元可以是芯片内的存储单元,如寄存器、缓存等,存储单元还可以是终端内的位于芯片外部的存储单元,如只ROM、可存储静态信息和指令的其他类型的静态存储设备、RAM等。In another possible design, when the device is a chip in a source base station, the chip includes: a receiving unit and a transmitting unit, and optionally, a processing unit. The processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc., and the transmitting unit can be, for example, an output interface, a pin or a circuit. The processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of requesting to restore the connection of any of the above fourth aspects to be performed. Optionally, the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM only, other types of statics that can store static information and instructions. Storage device, RAM, etc.
其中,上述任一处提到的处理器,可以是一个通用的CPU,微处理器,ASIC,或一个或多个用于控制上述第四方面任意一项的请求恢复连接的方法的程序执行的集成电路。Wherein, the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or a program executed by one or more methods for controlling a connection recovery connection according to any of the above fourth aspects. integrated circuit.
第十方面,本申请提供一种装置,该装置可以是源基站,也可以是源基站内的芯片。该装置具有实现上述第五方面的各实施例的功能。该功能可以通过硬件实现,也可以通过硬件执行相应的软件实现。该硬件或软件包括一个或多个与上述功能相对应的模块。In a tenth aspect, the application provides a device, which may be a source base station or a chip in a source base station. The device has the functionality to implement the various embodiments of the fifth aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software. The hardware or software includes one or more modules corresponding to the functions described above.
在一种可能的设计中,当该装置为源基站时,基站包括:接收单元和发送单元,可选地,还包括处理单元。处理单元例如可以是处理器,接收单元例如可以是接收器,发送单元,例如可以是发送器。接收器和发送器包括射频电路。可选地,基站还包括存储单元,该存储单元例如可以是存储器。当基站包括存储单元时,该存储单元存储有计算机执行指令,处理单元与存储单元连接,处理单元执行存储单元存储的计算机执行指令,以使该基站执行上述第五方面任意一项的请求恢复连接的方法。In a possible design, when the device is a source base station, the base station includes: a receiving unit and a transmitting unit, and optionally, a processing unit. The processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter. The receiver and transmitter include radio frequency circuits. Optionally, the base station further comprises a storage unit, which may be, for example, a memory. When the base station includes a storage unit, the storage unit stores a computer execution instruction, the processing unit is connected to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit, so that the base station performs the request to restore the connection according to any one of the foregoing fifth aspects. Methods.
在另一种可能的设计中,当该装置为源基站内的芯片时,芯片包括:接收单元和发送单元,可选地,还包括处理单元。处理单元例如可以是处理电路,接收单元例如可以是输入接口、管脚或电路等,发送单元例如可以是输出接口、管脚或电路等。该处理单元可执行存储单元存储的计算机执行指令,以使上述第五方面任意一项的请求恢复连接的方法被执行。可选地,存储单元可以是芯片内的存储单元,如寄存器、缓存等,存储单元还可以是终端内的位于芯片外部的存储单元,如只ROM、可存储静态信息和指令的其他类型的静态存储设备、RAM等。In another possible design, when the device is a chip in a source base station, the chip includes: a receiving unit and a transmitting unit, and optionally, a processing unit. The processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc., and the transmitting unit can be, for example, an output interface, a pin or a circuit. The processing unit may execute a computer execution instruction stored by the storage unit to cause the method of requesting to restore the connection of any of the above fifth aspects to be performed. Optionally, the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM only, other types of statics that can store static information and instructions. Storage device, RAM, etc.
其中,上述任一处提到的处理器,可以是一个通用的CPU,微处理器,ASIC,或一个或多个用于控制上述第五方面任意一项的请求恢复连接的方法的程序执行的集成电路。Wherein, the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or a program executed by one or more methods for controlling a connection recovery connection according to any of the above fifth aspects. integrated circuit.
第十一方面,本申请还提供一种计算机可读存储介质,所述计算机可读存储介质中存储有指令,当其在计算机上运行时,使得计算机执行上述各方面所述的方法。In an eleventh aspect, the present application further provides a computer readable storage medium having instructions stored therein that, when executed on a computer, cause the computer to perform the methods described in the above aspects.
第十二方面,本申请还提供一种包含指令的计算机程序产品,当其在计算机上运 行时,使得计算机执行上述各方面所述的方法。In a twelfth aspect, the present application also provides a computer program product comprising instructions which, when run on a computer, cause the computer to perform the methods described in the above aspects.
第十三方面,本申请提供一种通信系统,所述系统包括第六方面所述的装置、第七方面所述的装置和第九方面所述的装置,或者,所述系统包括第六方面所述的装置、第七方面所述的装置和第十方面所述的装置,或者,所述系统包括第六方面所述的装置、第八方面所述的装置和第九方面所述的装置,所述系统包括第六方面所述的装置、第八方面所述的装置和第十方面所述的装置。In a thirteenth aspect, the present application provides a communication system, the system comprising the device of the sixth aspect, the device of the seventh aspect, and the device of the ninth aspect, or the system includes the sixth aspect The device of claim 7, the device of the seventh aspect, and the device of the tenth aspect, or the system, comprising the device of the sixth aspect, the device of the eighth aspect, and the device of the ninth aspect The system includes the apparatus of the sixth aspect, the apparatus of the eighth aspect, and the apparatus of the tenth aspect.
第十四方面,本申请还提供一种请求恢复连接的方法,包括:终端更新接入层密钥,得到更新后的接入层密钥;终端根据更新后的接入层密钥,生成更新后的完整性保护密钥;终端根据更新后的完整性保护密钥,生成消息认证码;终端向目标基站发送连接恢复请求消息,所述连接恢复请求消息包括所述消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;终端接收来自所述目标基站的连接恢复拒绝消息,所述连接恢复拒绝消息用于指示拒绝所述终端恢复所述RRC连接;终端将所述终端的接入层密钥恢复为更新前的接入层密钥。In a fourteenth aspect, the present application further provides a method for requesting to restore a connection, comprising: updating a access layer key by a terminal to obtain an updated access layer key; and generating, by the terminal, an update according to the updated access layer key a security integrity key; the terminal generates a message authentication code according to the updated integrity protection key; the terminal sends a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, the connection And the recovery request message is used to request to resume the radio resource control RRC connection; the terminal receives a connection recovery reject message from the target base station, where the connection recovery reject message is used to indicate that the terminal is denied to restore the RRC connection; The access layer key is restored to the access layer key before the update.
由于在目标基站拒绝终端的连接恢复请求的场景中,终端已经更新了接入层密钥,为了保持终端与源基站之间的密钥一致,可以采用由终端回退密钥的方式,将终端的接入层密钥恢复为更新前的接入层密钥。因而,也可以达到使得终端与源基站之间始终保持密钥相同的目的,进而也可以有效解决终端与源基站之间的密钥不同步所带来的终端无法恢复连接的问题。In the scenario that the target base station rejects the connection recovery request of the terminal, the terminal has updated the access layer key. In order to keep the key between the terminal and the source base station consistent, the terminal may use the method of backing off the key by the terminal. The access layer key is restored to the access layer key before the update. Therefore, the purpose of maintaining the same key between the terminal and the source base station is also achieved, and the problem that the terminal cannot be restored due to the key synchronization between the terminal and the source base station can be effectively solved.
第十五方面,本申请提供一种装置,该装置可以是终端,也可以是终端内的芯片。该装置具有实现上述第十四方面的实施例的功能。该功能可以通过硬件实现,也可以通过硬件执行相应的软件实现。该硬件或软件包括一个或多个与上述功能相对应的模块。In a fifteenth aspect, the application provides a device, which may be a terminal or a chip in the terminal. The device has the function of implementing the embodiment of the fourteenth aspect described above. This function can be implemented in hardware or in hardware by executing the corresponding software. The hardware or software includes one or more modules corresponding to the functions described above.
在一种可能的设计中,当该装置为终端时,终端包括:发送单元、接收单元和处理单元。处理单元例如可以是处理器,接收单元例如可以是接收器,发送单元,例如可以是发送器。接收器和发送器包括射频电路。可选地,终端还包括存储单元,该存储单元例如可以是存储器。当终端包括存储单元时,该存储单元存储有计算机执行指令,处理单元与存储单元连接,处理单元执行存储单元存储的计算机执行指令,以使该终端执行上述第十四方面的请求恢复连接的方法。In a possible design, when the device is a terminal, the terminal includes: a transmitting unit, a receiving unit, and a processing unit. The processing unit may for example be a processor, which may for example be a receiver, a transmitting unit, for example a transmitter. The receiver and transmitter include radio frequency circuits. Optionally, the terminal further comprises a storage unit, which may be, for example, a memory. When the terminal includes a storage unit, the storage unit stores a computer execution instruction, the processing unit is connected to the storage unit, and the processing unit executes a computer execution instruction stored by the storage unit, so that the terminal performs the request for restoring the connection according to the fourteenth aspect. .
在另一种可能的设计中,当该装置为终端内的芯片时,芯片包括:发送单元、接收单元和处理单元。处理单元例如可以是处理电路,接收单元例如可以是输入接口、管脚或电路等,发送单元例如可以是输出接口、管脚或电路等。该处理单元可执行存储单元存储的计算机执行指令,以使上述第十四方面的请求恢复连接的方法被执行。可选地,存储单元可以是芯片内的存储单元,如寄存器、缓存等,存储单元还可以是终端内的位于芯片外部的存储单元,如ROM、可存储静态信息和指令的其他类型的静态存储设备、RAM等。In another possible design, when the device is a chip in the terminal, the chip includes: a transmitting unit, a receiving unit, and a processing unit. The processing unit can be, for example, a processing circuit, which can be, for example, an input interface, a pin or a circuit, etc., and the transmitting unit can be, for example, an output interface, a pin or a circuit. The processing unit may execute a computer-executed instruction stored by the storage unit to cause the method of the above-described fourteenth aspect to request a connection to be restored. Optionally, the storage unit may be a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the terminal, such as a ROM, other types of static storage that can store static information and instructions. Equipment, RAM, etc.
其中,上述任一处提到的处理器,可以是一个通用的CPU,微处理器,ASIC,或一个或多个用于控制上述第十四方面的请求恢复连接的方法的程序执行的集成电路。Wherein, the processor mentioned in any of the above may be a general-purpose CPU, a microprocessor, an ASIC, or an integrated circuit of one or more programs for controlling the method for requesting the restoration of the connection in the above fourteenth aspect. .
本申请的这些方面或其他方面在以下实施例的描述中会更加简明易懂。These and other aspects of the present application will be more readily apparent from the following description of the embodiments.
附图说明DRAWINGS
图1为本申请提供的一种可能的网络架构示意图;FIG. 1 is a schematic diagram of a possible network architecture provided by the present application;
图2为本申请提供的终端从连接态进入不活跃态的过程示意图;2 is a schematic diagram of a process for a terminal to enter an inactive state from a connected state according to the present application;
图3为本申请提供的一种请求恢复连接的方法流程图;FIG. 3 is a flowchart of a method for requesting a recovery connection according to the present application; FIG.
图4为本申请提供的另一种请求恢复连接的方法流程图;4 is a flowchart of another method for requesting a recovery connection according to the present application;
图5为本申请提供的另一种请求恢复连接的方法流程图;FIG. 5 is a flowchart of another method for requesting a recovery connection according to the present application; FIG.
图6为本申请提供的另一种请求恢复连接的方法流程图;FIG. 6 is a flowchart of another method for requesting a recovery connection according to the present application; FIG.
图7为本申请提供的另一种请求恢复连接的方法流程图;FIG. 7 is a flowchart of another method for requesting to restore a connection provided by the present application;
图8为本申请提供的一种装置示意图;Figure 8 is a schematic diagram of a device provided by the present application;
图9为本申请提供的另一种装置示意图;Figure 9 is a schematic view of another apparatus provided by the present application;
图10为本申请提供的另一种装置示意图;Figure 10 is a schematic view of another apparatus provided by the present application;
图11为本申请提供的另一种装置示意图。FIG. 11 is a schematic diagram of another apparatus provided by the present application.
具体实施方式Detailed ways
下面将结合附图对本申请作进一步地详细描述。方法实施例中的具体操作方法也可以应用于装置实施例或系统实施例中。其中,在本申请的描述中,除非另有说明,“多个”的含义是两个或两个以上。The present application will be further described in detail below with reference to the accompanying drawings. The specific method of operation in the method embodiments can also be applied to device embodiments or system embodiments. In the description of the present application, the meaning of "a plurality" is two or more unless otherwise stated.
需要说明的的是,本申请的请求恢复连接的方法可由装置执行。其中,该装置可以包括网络侧的装置和/或终端侧的装置。在网络侧,该装置可以是基站或基站内的芯片,即可以由基站或基站内的芯片执行本申请的请求恢复连接的方法;在终端侧,该装置可以是终端或终端内的芯片,即可以由终端或终端内的芯片执行本申请的请求恢复连接的方法。It should be noted that the method of requesting to restore the connection of the present application may be performed by a device. Wherein, the device may include a device on the network side and/or a device on the terminal side. On the network side, the device may be a chip in the base station or the base station, that is, the method of requesting to restore the connection may be performed by the chip in the base station or the base station; on the terminal side, the device may be a chip in the terminal or the terminal, that is, The method of requesting to restore a connection of the present application can be performed by a chip in a terminal or a terminal.
为方便说明,本申请,以装置为基站或终端为例,对请求恢复连接的方法进行说明,对于装置为基站内的芯片或终端内的芯片的实现方法,可参考基站或终端的请求恢复连接的方法的具体说明,不再重复介绍。For convenience of description, the present application uses a device as a base station or a terminal as an example to describe a method for requesting to restore a connection. For a method in which a device is a chip in a base station or a chip in a terminal, the connection may be restored by referring to the request of the base station or the terminal. The specific description of the method is not repeated.
如图1所示,为本申请的一种可能的网络架构示意图。包括终端、源基站和目标基站。终端通过无线接口与源基站、目标基站进行通信。源基站与目标基站之间可以通过有线连接进行通信,如通过X2接口,Xn接口进行通信,或者还可以通过空口的方式进行通信。FIG. 1 is a schematic diagram of a possible network architecture of the present application. It includes a terminal, a source base station, and a target base station. The terminal communicates with the source base station and the target base station through a wireless interface. The source base station and the target base station can communicate through a wired connection, such as through an X2 interface, an Xn interface, or can communicate through an air interface.
本申请中,由于终端的移动等原因,终端可能从源基站移动到目标基站。源基站是终端在先接入的基站,目标基站是终端移动后,在后接入的基站。In the present application, the terminal may move from the source base station to the target base station due to the movement of the terminal or the like. The source base station is a base station that the terminal accesses first, and the target base station is a base station that is accessed after the terminal moves.
其中,终端是一种具有无线收发功能的设备,可以部署在陆地上,包括室内或室外、手持或车载;也可以部署在水面上(如轮船等);还可以部署在空中(例如飞机、气球和卫星上等)。所述终端可以是手机(mobile phone)、平板电脑(pad)、带无线收发功能的电脑、虚拟现实(virtual reality,VR)终端、增强现实(augmented reality,AR)终端、工业控制(industrial control)中的无线终端、无人驾驶(self driving)中的无线终端、远程医疗(remote medical)中的无线终端、智能电网(smart grid)中的无线终端、运输安全(transportation safety)中的无线终端、智慧城市(smart city)中的无线终端、智慧家庭(smart home)中的无线终端等等。Among them, the terminal is a device with wireless transceiver function, which can be deployed on land, indoors or outdoors, handheld or on-board; it can also be deployed on the water surface (such as ships); it can also be deployed in the air (such as airplanes, balloons). And satellites, etc.). The terminal may be a mobile phone, a tablet, a computer with wireless transceiver function, a virtual reality (VR) terminal, an augmented reality (AR) terminal, industrial control (industrial control) Wireless terminal, wireless terminal in self driving, wireless terminal in remote medical, wireless terminal in smart grid, wireless terminal in transportation safety, A wireless terminal in a smart city, a wireless terminal in a smart home, and the like.
基站,是一种为终端提供无线通信功能的设备,包括但不限于:5G中的下一代基站(g nodeB,gNB)、演进型节点B(evolved node B,eNB)、无线网络控制器(radio network  controller,RNC)、节点B(node B,NB)、基站控制器(base station controller,BSC)、基站收发台(base transceiver station,BTS)、家庭基站(例如,home evolved nodeB,或home node B,HNB)、基带单元(BaseBand Unit,BBU)、传输点(transmitting and receiving point,TRP)、发射点(transmitting point,TP)、移动交换中心等。A base station is a device that provides wireless communication functions for a terminal, including but not limited to: a next-generation base station (g nodeB, gNB), an evolved node B (eNB), and a radio network controller (radio) in 5G. Network controller (RNC), node B (NB), base station controller (BSC), base transceiver station (BTS), home base station (for example, home evolved node B, or home node B) , HNB), BaseBand Unit (BBU), transmission and receiving point (TRP), transmitting point (TP), mobile switching center, etc.
本申请,终端一般情况下,具有三种状态,即连接(connected)态,空闲(idle)态和不活跃(inactive)态。In the present application, the terminal generally has three states, that is, a connected state, an idle state, and an inactive state.
其中,当终端处于连接态时,终端处于正常工作的状态。网络侧与终端之间可以发送和接收用户数据。Wherein, when the terminal is in the connected state, the terminal is in a normal working state. User data can be sent and received between the network side and the terminal.
当终端从连接态进入空闲态时,终端和基站一般会删除终端的全部的接入层(access stratum,AS)上下文。在一种特别的情况下,在4G中,当网络侧以挂起原因释放终端的连接时,终端也会从连接态进入空闲态,但此时,终端和基站会删除部分AS上下文,以及保留部分AS上下文,例如可以保留接入层密钥(4G中可以称为KeNB),终端的安全能力,终端和终端接入的源基站之间通信的安全算法(包括完整性保护算法和加密算法)。其中,终端的安全能力指的是终端支持的安全算法,包括支持的加密算法和支持的完整性保护算法。此时,终端所处于的特殊的空闲态可以称为挂起态。When the terminal enters the idle state from the connected state, the terminal and the base station generally delete all the access stratum (AS) contexts of the terminal. In a special case, in 4G, when the network side releases the connection of the terminal by the suspend reason, the terminal also enters the idle state from the connected state, but at this time, the terminal and the base station delete part of the AS context, and retain A partial AS context, for example, may retain an access layer key (which may be referred to as KeNB in 4G), a security capability of the terminal, and a security algorithm (including an integrity protection algorithm and an encryption algorithm) for communication between the terminal and the source base station to which the terminal accesses. . The security capability of the terminal refers to the security algorithm supported by the terminal, including the supported encryption algorithm and the supported integrity protection algorithm. At this time, the special idle state in which the terminal is located may be referred to as a suspended state.
在5G中,引入了不活跃态,当终端从连接态进入不活跃态时,基站将挂起终端,此时,终端和基站删除部分AS上下文,以及保留部分AS上下文,例如可以保留接入层密钥(5G中可以称为KgNB),终端的安全能力,终端和终端接入的源基站之间通信的安全算法(包括完整性保护算法和加密算法)。其中,终端的安全能力指的是终端支持的安全算法,包括支持的加密算法和支持的完整性保护算法。In 5G, an inactive state is introduced. When the terminal enters the inactive state from the connected state, the base station suspends the terminal. At this time, the terminal and the base station delete part of the AS context, and reserve part of the AS context, for example, the access layer may be reserved. The key (which can be called KgNB in 5G), the security capability of the terminal, and the security algorithm (including integrity protection algorithm and encryption algorithm) for communication between the terminal and the source base station accessed by the terminal. The security capability of the terminal refers to the security algorithm supported by the terminal, including the supported encryption algorithm and the supported integrity protection algorithm.
为方便说明,后续统一将4G中定义的挂起态和5G中定义的不活跃态,称为不活跃态。当终端处于不活跃态时,终端和终端进入不活跃态之前所连接的基站都会保存部分的AS上下文,具体内容参见前述描述。For convenience of explanation, the subsequent unification of the suspended state defined in 4G and the inactive state defined in 5G is called inactive state. When the terminal is in an inactive state, the base station connected to the terminal and the terminal before the terminal enters the inactive state will save part of the AS context. For details, refer to the foregoing description.
当终端处于不活跃态时,由于终端上保留了部分AS上下文,因此相较于终端从空闲态进入连接态,终端从不活跃态进入连接态会更加快速。When the terminal is in an inactive state, since part of the AS context is reserved on the terminal, the terminal enters the connected state from the inactive state more quickly than when the terminal enters the connected state from the idle state.
另外,考虑到终端的移动性,当终端从不活跃态恢复到连接态时,终端可能需要更换基站。即,终端先与源基站建立连接,然后由于某些原因,例如网络侧通知等,终端在源基站进入不活跃态。当终端希望恢复到连接态时,若终端已经移动至目标基站的覆盖范围,则终端将在目标基站从不活跃态恢复到连接态。In addition, considering the mobility of the terminal, when the terminal returns from the inactive state to the connected state, the terminal may need to replace the base station. That is, the terminal first establishes a connection with the source base station, and then the terminal enters an inactive state at the source base station for some reason, such as network side notification. When the terminal wishes to return to the connected state, if the terminal has moved to the coverage of the target base station, the terminal will resume from the inactive state to the connected state at the target base station.
当然,本申请同样也适用终端从不活跃态恢复到连接态时,接入的目标基站与源基站相同的场景,即终端接入的基站也可以不发发生改变,仍然是同一个基站。Of course, the present application is also applicable to the scenario in which the target base station and the source base station are the same when the terminal is restored from the inactive state to the connected state, that is, the base station accessed by the terminal may not change, and is still the same base station.
下面介绍终端从连接态进入不活跃态的过程。The following describes the process of the terminal entering the inactive state from the connected state.
如图2所示,为本申请提供的终端从连接态进入不活跃态的过程示意图,包括以下步骤:As shown in FIG. 2, a schematic diagram of a process for a terminal provided in the present application to enter an inactive state from a connected state includes the following steps:
步骤201、基站决定挂起终端的无线资源控制(radio resource control,RRC)连接。Step 201: The base station determines to suspend a radio resource control (RRC) connection of the terminal.
例如,当基站一段时间内未接收到终端发送的数据时,则决定将终端挂起。For example, when the base station does not receive the data sent by the terminal within a certain period of time, it decides to suspend the terminal.
步骤202、基站向终端发送挂起消息。Step 202: The base station sends a suspension message to the terminal.
挂起消息用于通知终端释放RRC连接,并进入不活跃态。挂起消息例如可以是具有特殊指示的RRC连接释放消息。The suspend message is used to notify the terminal to release the RRC connection and enter an inactive state. The suspend message may be, for example, an RRC Connection Release message with a special indication.
在具体实现中,挂起消息可以携带以下参数:恢复标识。可选地,挂起消息还可 以携带下一跳链计数器(next hop chaining counter,NCC)等。In a specific implementation, the suspended message may carry the following parameters: a recovery identifier. Optionally, the suspended message may also carry a next hop chaining counter (NCC) or the like.
恢复标识是终端后续从不活跃态进入连接态时所需要的参数,恢复标识可以包括源基站的标识、终端的标识等信息,具体地,恢复标识可以是ResumeID,不活跃态-小区无线网络临时标识(INACTIVE-cell radio network temporary identifier,I-RNTI)。The recovery identifier is a parameter that is required for the terminal to enter the connection state from the inactive state. The recovery identifier may include the identifier of the source base station, the identifier of the terminal, and the like. Specifically, the recovery identifier may be ResumeID, and the inactive state-cell wireless network temporarily Identification (INACTIVE-cell radio network temporary identifier, I-RNTI).
NCC是可选参数,NCC也可以是终端后续从不活跃态进入连接态时所需要的参数。如果挂起消息中携带NCC,则后续终端和基站所使用的接入层密钥将会发生更新。NCC是生成新的接入层密钥所需要的参数,即NCC可用于生成新的接入层密钥(本申请用KgNB*表示新的接入层密钥)。如果挂起消息中不携带NCC,则后续终端和基站所使用的接入层密钥将不发生更新,即始终保持不变。The NCC is an optional parameter, and the NCC may also be a parameter required when the terminal subsequently enters the connected state from the inactive state. If the suspended message carries the NCC, the access layer key used by the subsequent terminal and the base station will be updated. The NCC is a parameter required to generate a new access layer key, ie the NCC can be used to generate a new access stratum key (this application uses KgNB* to represent the new access stratum key). If the suspended message does not carry the NCC, the access layer key used by the subsequent terminal and the base station will not be updated, that is, it will remain unchanged.
可选地,挂起消息还可以携带原因参数releaseCause,releaseCause用于通知终端执行挂起操作并进入不活跃态。例如可以将releaseCause置为“RRC Suspend”或“RRC Inactive”。当终端获取到releaseCause参数时,确定releaseCause的值为“RRC Suspend”或“RRC Inactive”时,则执行终端挂起的相关操作。Optionally, the suspend message may also carry a cause parameter releaseCause, and the releaseCause is used to notify the terminal to perform the suspend operation and enter the inactive state. For example, releaseCause can be set to "RRC Suspend" or "RRC Inactive". When the terminal obtains the releaseCause parameter and determines that the releaseCause value is "RRC Suspend" or "RRC Inactive", the terminal suspends the related operation.
可选地,基站还可以通知核心网的控制面网元释放承载,例如释放信令无线承载(signaling radio bearer,SRB)、数据无线承载(data radio bearer,DRB)。Optionally, the base station may further notify the control plane network element of the core network to release the bearer, for example, release a signaling radio bearer (SRB) or a data radio bearer (DRB).
步骤203、终端进入不活跃态。Step 203: The terminal enters an inactive state.
终端保存删除部分AS上下文,以及保留部分AS上下文。保留的部分AS上下文包括接入层密钥,终端的安全能力,终端和终端接入的源基站之间通信的完整性保护算法和加密算法等。The terminal saves the deleted part of the AS context and retains part of the AS context. The reserved part of the AS context includes an access layer key, a security capability of the terminal, an integrity protection algorithm and an encryption algorithm for communication between the terminal and the source base station to which the terminal accesses.
终端还保存基站发送的恢复标识,可选地,终端还保存NCC等参数。The terminal also saves the recovery identifier sent by the base station. Optionally, the terminal also saves parameters such as NCC.
终端挂起承载,例如,挂起信令无线承载、数据无线承载,然后进入不活跃态。The terminal suspends the bearer, for example, suspending the signaling radio bearer, the data radio bearer, and then entering the inactive state.
从上述终端从连接态进入不活跃态的过程可看出,终端进入不活跃态之后,终端上保存有部分AS上下文和从基站接收的参数,因而,后续当终端希望从不活跃态恢复到连接态时,这些参数将有助于终端实现快速从不活跃态恢复到连接态。From the process in which the terminal enters the inactive state from the connected state, it can be seen that after the terminal enters the inactive state, the terminal saves part of the AS context and parameters received from the base station, and thus, when the terminal wishes to recover from the inactive state to the connection. In the state, these parameters will help the terminal to quickly recover from the inactive state to the connected state.
需要说明的是,上述终端接入的基站,也可以称为终端接入的源基站。当终端请求恢复连接时,终端所请求接入的基站可能是源基站,也可能是其它的基站,可以称为目标基站。It should be noted that the base station accessed by the terminal may also be referred to as a source base station accessed by the terminal. When the terminal requests to resume the connection, the base station that the terminal requests to access may be the source base station or other base stations, which may be referred to as the target base station.
下面介绍几种引入了基站拒绝场景的请求恢复连接的方法。即终端请求从不活跃态恢复到连接态,并且,终端是在目标基站下请求从不活跃态恢复到连接态。The following describes several methods for introducing a request to restore a connection in a base station rejection scenario. That is, the terminal requests to recover from the inactive state to the connected state, and the terminal requests to resume from the inactive state to the connected state under the target base station.
其中,目标基站和源基站可以是不同的基站,也可以是相同的基站。下面以目标基站和源基站是不同的基站为例进行说明。针对目标基站和源基站是相同的基站的情形,只需要将源基站和目标基站之间的交互操作省略即可。The target base station and the source base station may be different base stations, or may be the same base station. The following is an example in which the target base station and the source base station are different base stations. In the case where the target base station and the source base station are the same base station, only the interaction between the source base station and the target base station needs to be omitted.
如图3所示,为本申请提供的一种请求恢复连接的方法,该方法包括以下步骤:As shown in FIG. 3, a method for requesting a recovery connection is provided by the present application, and the method includes the following steps:
步骤301、终端生成消息认证码(message authentication code,MAC)。Step 301: The terminal generates a message authentication code (MAC).
消息认证码用于认证终端的合法性。具体实现中,消息认证码至少有以下两种生成方式:The message authentication code is used to authenticate the legitimacy of the terminal. In a specific implementation, the message authentication code has at least two generation modes:
方式一、根据终端的完整性保护算法和终端的完整性保护密钥,生成消息认证码,其中,该完整性保护密钥与上一次恢复所使用的完整性保护密钥相同。Manner 1: Generate a message authentication code according to the integrity protection algorithm of the terminal and the integrity protection key of the terminal, where the integrity protection key is the same as the integrity protection key used in the previous restoration.
该方式一中,终端每次生成消息认证码时所使用的完整性保护密钥与上一次恢复所使用的完整性保护密钥相同,相应地,源基站中保存的终端的完整性保护密钥也是 与上一次恢复所使用的完整性保护密钥相同的。In the first method, the integrity protection key used by the terminal each time the message authentication code is generated is the same as the integrity protection key used in the previous restoration, and accordingly, the integrity protection key of the terminal stored in the source base station It is also the same as the integrity protection key used in the previous recovery.
例如,使用Krrc-int来表示终端的完整性保护密钥,如果生成消息认证码的其他参数都相同,则终端每次生成的消息认证码都是相同的,即根据Krrc-int和终端的完整性保护算法生成。For example, the Krrc-int is used to represent the integrity protection key of the terminal. If the other parameters of the message authentication code are the same, the message authentication code generated by the terminal is the same every time, that is, according to the completeness of the Krrc-int and the terminal. Sex protection algorithm generation.
其中,Krrc-int是终端根据接入层密钥、终端的完整性保护算法的标识以及终端的完整性保护算法的类型生成的。因此,该方式一中,终端的完整性保护密钥Krrc-int与上一次恢复所使用的完整性保护密钥相同,也可以理解为,是终端的接入层密钥与上一次恢复所使用的接入层密钥相同。The Krrc-int is generated by the terminal according to the access layer key, the identifier of the integrity protection algorithm of the terminal, and the type of the integrity protection algorithm of the terminal. Therefore, in the first method, the integrity protection key Krrc-int of the terminal is the same as the integrity protection key used in the previous recovery, and can also be understood as the access layer key of the terminal and the last recovery used. The access layer keys are the same.
例如,使用KgNB来表示接入层密钥,则该方式一中,终端生成消息认证码时所使用的接入层密钥KgNB与上一次恢复所使用的接入层密钥保持相同。For example, if KgNB is used to represent the access layer key, in the first method, the access layer key KgNB used by the terminal to generate the message authentication code remains the same as the access layer key used in the previous restoration.
方式二、根据终端的完整性保护算法和终端的完整性保护密钥,生成消息认证码,其中,该完整性保护密钥是重新生成的。Manner 2: Generate a message authentication code according to the integrity protection algorithm of the terminal and the integrity protection key of the terminal, where the integrity protection key is regenerated.
该方式二中,终端每次生成消息认证码时所使用的完整性保护密钥都会重新生成,且与终端上次使用的完整性保护密钥不同。In the second mode, the integrity protection key used by the terminal each time the message authentication code is generated is regenerated, and is different from the integrity protection key used by the terminal last time.
例如,如果终端上次使用的完整性保护密钥是Krrc-int,则终端将需要重新生成并使用新的完整性保护密钥,例如使用Krrc-int*来表示新的完整性保护密钥。For example, if the last used integrity protection key of the terminal is Krrc-int, the terminal will need to regenerate and use the new integrity protection key, for example using Krrc-int* to indicate the new integrity protection key.
作为一种实现方式,终端可以使用下列方法生成新的完整性保护密钥Krrc-int*:终端生成新的接入层密钥,然后使用新的接入层密钥、终端的完整性保护算法的标识以及终端的完整性保护算法的类型生成Krrc-int*。As an implementation manner, the terminal may generate a new integrity protection key Krrc-int* by using the following method: the terminal generates a new access layer key, and then uses the new access layer key, the terminal integrity protection algorithm. The type of identity and the integrity protection algorithm of the terminal generate Krrc-int*.
例如,使用KgNB来表示终端当前的接入层密钥,使用KgNB*来表示新的接入层密钥,则该方式二中,终端是根据KgNB*、终端的完整性保护算法的标识以及终端的完整性保护算法的类型生成Krrc-int*,然后使用Krrc-int*和终端的完整性保护算法生成消息认证码。For example, KgNB is used to indicate the current access layer key of the terminal, and KgNB* is used to represent the new access layer key. In the second mode, the terminal is based on the KgNB*, the identifier of the integrity protection algorithm of the terminal, and the terminal. The type of integrity protection algorithm generates Krrc-int*, and then uses Krrc-int* and the terminal integrity protection algorithm to generate the message authentication code.
由于使用了新的接入层密钥KgNB*,因而导致最终生成的消息认证码发生了变化。即终端每次需要使用消息认证码时,所生成的消息认证码与上次所生成的消息认证码是不相同的。Due to the use of the new access layer key KgNB*, the resulting message authentication code has changed. That is, each time the terminal needs to use the message authentication code, the generated message authentication code is different from the message authentication code generated last time.
作为示例,下面介绍一种生成新的接入层密钥的KgNB*的方法,包括以下步骤:As an example, a method of generating a new access layer key KgNB* is described below, including the following steps:
步骤A1、终端获取第一NCC和第二NCC。Step A1: The terminal acquires the first NCC and the second NCC.
其中,第一NCC指的是终端是在挂起流程中由源基站发送至终端,并由终端保存的NCC,具体可参考上述步骤202。The first NCC refers to the NCC that is sent by the source base station to the terminal and saved by the terminal in the suspending process. For details, refer to step 202 above.
第二NCC指的是终端获得第一NCC之前保存的NCC。The second NCC refers to the NCC saved by the terminal before the first NCC is obtained.
步骤A2、终端判断第一NCC与第二NCC是否相同。若相同,则执行步骤A3;若不同,则执行步骤A4。Step A2: The terminal determines whether the first NCC is the same as the second NCC. If they are the same, step A3 is performed; if not, step A4 is performed.
步骤A3、终端根据KgNB,得到KgNB*。Step A3: The terminal obtains KgNB* according to KgNB.
其中,KgNB指的是老的接入层密钥(old KgNB),也可以称为原始的接入层密钥(original KgNB),或者还可以称为旧的接入层密钥(old KgNB)。Among them, KgNB refers to the old access layer key (old KgNB), which may also be called the original access layer key (original KgNB), or may also be called the old access layer key (old KgNB). .
相应地,KgNB*指的是新的接入层密钥(new KgNB),也可以称为更新的接入层密钥(updated KgNB)。Accordingly, KgNB* refers to the new access layer key (new KgNB), which may also be referred to as the updated access layer key (updated KgNB).
需要说明的是,KgNB,KgNB*仅仅是一种符号化的表示。例如,在4G应用中,接入层密钥则可以使用KeNB,KeNB*表示。符号本身所使用的不同表现形式,本不 构成对本申请的限定。It should be noted that KgNB, KgNB* is just a symbolic representation. For example, in a 4G application, the access layer key can be represented by KeNB, KeNB*. The different manifestations used in the symbols themselves are not intended to limit the application.
可选地,作为一种实现方式,该步骤A3中,可以由终端根据KgNB,目标物理小区标识(physical cell identifier,PCI),下行绝对无线频点(absolute radio frequency channel number-down link,ARFCN-DL),得到KgNB*。Optionally, as an implementation manner, in step A3, the terminal may be based on KgNB, a target physical cell identifier (PCI), and an absolute radio frequency channel number-down link (ARFCN-). DL), get KgNB*.
针对根据KgNB,目标PCI和ARFCN-DL,得到KgNB*的具体实现方式,为现有技术,可参考相关文献,例如可以参考第三代合作伙伴计划(3rd generation partnership project,3GPP)技术规范(technical specification,TS)33.401或3GPP TS 33.501中的相关说明,这里不再赘述。For the specific implementation of KgNB* according to KgNB, target PCI and ARFCN-DL, for the prior art, reference may be made to related documents, for example, reference can be made to the 3rd generation partnership project (3GPP) technical specification (technical) Specification, TS) 33.401 or related description in 3GPP TS 33.501, which is not described here.
步骤A4、终端根据第一NCC和第二NCC得到下一跳(next hop,NH),以及,根据NH,得到KgNB*。Step A4: The terminal obtains a next hop (NH) according to the first NCC and the second NCC, and obtains KgNB* according to the NH.
其中,NH是与第一NCC和第二NCC具有对应关系的。终端根据第一NCC和第二NCC可以确定衍生NH的次数N,再根据当前NH衍生得到下一个NH,使用下一个NH衍生得到再一个NH,如此反复,直到衍生N次,得到最终的NH。Wherein, NH is associated with the first NCC and the second NCC. The terminal can determine the number N of the derived NH according to the first NCC and the second NCC, and then derive the next NH according to the current NH, and obtain another NH by using the next NH, and repeat until the N is derived to obtain the final NH.
可选地,作为一种实现方式,可以由终端根据NH,目标PCI,ARFCN-DL,得到KgNB*。Optionally, as an implementation manner, the terminal may obtain KgNB* according to NH, target PCI, and ARFCN-DL.
生成KgNB*的具体实现方式为现有技术,可参考相关文献,例如可以参考3GPP TS33.401或3GPP TS 33.501中的相关说明,这里不再赘述。For a specific implementation of the method for generating the KgNB*, refer to the related literature. For example, reference may be made to the related description in 3GPP TS33.401 or 3GPP TS 33.501, and details are not described herein again.
可选地,在通过上述两种方式获得完整性保护密钥后,终端可以根据该完整性保护密钥,源PCI,源小区无线网络临时标识(cell radio network temporary identifier,C-RNTI),目标小区标识和恢复常量,生成消息认证码。Optionally, after obtaining the integrity protection key by using the foregoing two methods, the terminal may use the integrity protection key, the source PCI, the source cell radio network temporary identifier (C-RNTI), and the target. The cell identifier and the recovery constant generate a message authentication code.
综上,上述方式一和方式二的主要区别在于:方式一中,终端每次使用消息认证码时,所生成的消息认证码与上次所生成的消息认证码是相同的,即消息认证码保持不变;方式二中,终端每次使用消息认证码时,所生成的消息认证码与上次所生成的消息认证码是不同的,即消息认证码保持更新。In summary, the main difference between the first mode and the second mode is that, in the first mode, each time the terminal uses the message authentication code, the generated message authentication code is the same as the message authentication code generated last time, that is, the message authentication code. In the second mode, each time the terminal uses the message authentication code, the generated message authentication code is different from the message authentication code generated last time, that is, the message authentication code remains updated.
步骤302、终端向目标基站发送连接恢复请求消息,目标基站接收来自终端的连接恢复请求消息。Step 302: The terminal sends a connection recovery request message to the target base station, and the target base station receives a connection recovery request message from the terminal.
终端发送的连接恢复请求消息,用于请求恢复RRC连接。即终端请求从不活跃态恢复到连接态。A connection recovery request message sent by the terminal, used to request to resume the RRC connection. That is, the terminal requests to return from the inactive state to the connected state.
作为一种实现方式,连接恢复请求消息中携带恢复标识。该恢复标识是终端从连接态进入不活跃态时,由源基站发送给终端的。例如,可参考上述步骤202的相关描述,这里不再赘述。As an implementation manner, the connection recovery request message carries a recovery identifier. The recovery identifier is sent by the source base station to the terminal when the terminal enters the inactive state from the connected state. For example, reference may be made to the related description of step 202 above, and details are not described herein again.
进一步地,连接恢复请求消息中还携带上述步骤301中生成的消息认证码。Further, the connection recovery request message further carries the message authentication code generated in step 301 above.
步骤303、目标基站判断是否同意终端的恢复请求。Step 303: The target base station determines whether to approve the recovery request of the terminal.
目标基站基于负载能力,判断是否可以接入该终端。The target base station determines whether the terminal can be accessed based on the load capability.
一种情形是,目标基站的负载比较重,不能接入该终端,则目标基站可以拒绝该终端的恢复请求,即拒绝该终端接入目标基站。此时,则执行步骤304。In one case, if the load of the target base station is relatively heavy and cannot access the terminal, the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, step 304 is performed.
另一种情形是,目标基站的负载不是很重,还可以接入该终端,则目标基站可以同意该终端的恢复请求,即同意该终端接入目标基站。此时,则执行步骤305-步骤308。In another case, the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station. At this time, step 305-step 308 is performed.
步骤304、目标基站向终端发送连接恢复拒绝消息,终端接收来自目标基站的连接恢复拒绝消息。Step 304: The target base station sends a connection recovery reject message to the terminal, and the terminal receives a connection recovery reject message from the target base station.
该连接恢复拒绝消息用于指示拒绝终端恢复RRC连接。The connection recovery reject message is used to indicate that the terminal is denied the RRC connection.
可选地,可以在连接恢复拒绝消息中携带一个等待计时器(wait timer)的信息,该等待计时器的信息用于拒绝终端接入的时间,也可以理解为,用于指示终端重新请求恢复RRC连接所需要等待的最小时长。例如,若等待计时器的信息指示的30分钟,则用于指示终端,至少需要等待30分钟,才可以重新发起连接恢复请求。即重新执行步骤301及步骤302的动作,进入下一次的连接恢复请求流程。Optionally, the connection recovery refusal message may be carried with a wait timer, where the information of the wait timer is used to reject the terminal access time, and may also be used to indicate that the terminal requests the recovery again. The minimum length of time that an RRC connection needs to wait. For example, if it waits for 30 minutes indicated by the timer information, it is used to instruct the terminal to wait at least 30 minutes before the connection recovery request can be re-initiated. That is, the operations of steps 301 and 302 are re-executed, and the next connection recovery request flow is entered.
步骤305、目标基站向源基站发送上下文请求消息,源基站接收来自目标基站的上下文请求消息。Step 305: The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
该上下文请求消息用于请求终端的上下文。The context request message is used to request the context of the terminal.
作为一种实现方式,当目标基站决定同意终端的连接恢复请求时,则从连接恢复请求消息中获取恢复标识,根据恢复标识中的源基站的标识,确定终端之前是与源基站连接的,则向源基站发送上下文请求消息,上下文请求消息用于请求获取终端的上下文,其中,上下文请求消息中携带恢复标识和消息认证码。As an implementation manner, when the target base station determines to agree to the connection recovery request of the terminal, the recovery identifier is obtained from the connection recovery request message, and according to the identifier of the source base station in the recovery identifier, it is determined that the terminal is connected to the source base station before, Sending a context request message to the source base station, where the context request message is used to request the acquisition of the context of the terminal, where the context request message carries the recovery identifier and the message authentication code.
源基站接收到目标基站发送上下文请求消息后,从中获取恢复标识,根据恢复标识中的终端的标识,获取该终端的接入层上下文,包括终端的安全能力。可选地,获取的终端的接入层上下文还包括终端与源基站之间协商的加密算法、完整性保护算法等信息。After receiving the context request message, the source base station obtains the recovery identifier, and obtains the access layer context of the terminal according to the identifier of the terminal in the recovery identifier, including the security capability of the terminal. Optionally, the obtained access layer context of the terminal further includes information such as an encryption algorithm and an integrity protection algorithm negotiated between the terminal and the source base station.
步骤306、源基站若校验消息认证码正确,则获取终端的上下文。Step 306: The source base station acquires the context of the terminal if the verification message authentication code is correct.
其中,源基站校验消息认证码的方法与终端生成消息认证码的方法是相对应的。The method for the source base station to verify the message authentication code corresponds to the method for the terminal to generate the message authentication code.
若终端是通过上述方式一生成消息认证码,则源基站校验消息认证码的方式为:源基站获取终端的上下文中的完整性保护算法(也可以称为源基站的完整性保护算法)和接入层密钥,然后根据接入层的密钥,推衍得到完整性保护密钥(也可以称为源基站的完整性保护密钥),或,源基站获取终端的上下文中的完整性保护算法(也可以称为源基站的完整性保护算法)和完整性保护密钥(也可以称为源基站的完整性保护密钥),然后根据源基站的完整性保护算法和源基站的完整性保护密钥,生成消息认证码,并与上下文请求消息中的消息认证码比较,若相同,则校验正确,若不同,则校验失败。If the terminal generates the message authentication code in the foregoing manner, the source base station checks the message authentication code in the following manner: the source base station acquires an integrity protection algorithm in the context of the terminal (which may also be referred to as an integrity protection algorithm of the source base station) and The access layer key is then derived according to the key of the access layer, and the integrity protection key (which may also be referred to as the integrity protection key of the source base station) is derived, or the source base station acquires the integrity in the context of the terminal. A protection algorithm (which may also be referred to as an integrity protection algorithm of the source base station) and an integrity protection key (which may also be referred to as an integrity protection key of the source base station), and then according to the integrity protection algorithm of the source base station and the integrity of the source base station The protection key is generated, and the message authentication code is generated and compared with the message authentication code in the context request message. If they are the same, the verification is correct. If it is different, the verification fails.
若终端是通过上述方式二生成消息认证码,则源基站校验消息认证码的方式为:源基站判断下一跳NH是否已经使用,若未使用,则源基站根据NH,得到新的接入层密钥KgNB*,若已经使用,则源基站根据终端当前的接入层密钥KgNB,得到新的接入层密钥KgNB*。在得到KgNB*之后,再根据KgNB*、源基站的的完整性保护算法的标识以及源基站的完整性保护算法的类型生成Krrc-int*,然后使用Krrc-int*和源基站的完整性保护算法生成消息认证码,并与上下文请求消息中的消息认证码比较,若相同,则校验正确,若不同,则校验失败。If the terminal generates the message authentication code by using the foregoing mode 2, the source base station checks the message authentication code by: the source base station determines whether the next hop NH has been used, and if not, the source base station obtains new access according to the NH. The layer key KgNB*, if used, the source base station obtains a new access layer key KgNB* according to the current access layer key KgNB of the terminal. After obtaining KgNB*, Krrc-int* is generated according to the KgNB*, the identity of the integrity protection algorithm of the source base station, and the type of the integrity protection algorithm of the source base station, and then the integrity protection of the source base station is performed using the Krrc-int* and the source base station. The algorithm generates a message authentication code and compares it with the message authentication code in the context request message. If they are the same, the verification is correct. If it is different, the verification fails.
可选地,源基站还可以根据该完整性保护密钥,源PCI,源小区无线网络临时标识(cell radio network temporary identifier,C-RNTI),目标小区标识和恢复常量,生成消息认证码。Optionally, the source base station may further generate a message authentication code according to the integrity protection key, the source PCI, the source cell radio network temporary identifier (C-RNTI), the target cell identifier, and the recovery constant.
步骤307、源基站若校验消息认证码正确,则向目标基站发送上下文响应消息。Step 307: The source base station sends a context response message to the target base station if the verification message authentication code is correct.
上下文响应消息中可以包括终端的上下文,例如包括源基站的完整性保护算法、源基站的完整性保护密钥。可选地,还包括上述生成的KgNB*。The context response message may include a context of the terminal, for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station. Optionally, the generated KgNB* is also included.
步骤308、目标基站向终端发送连接恢复响应消息,终端接收来自目标基站的连接恢复响应消息。Step 308: The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
该连接恢复响应消息用于指示终端恢复RRC连接。可选地,该连接恢复响应消息可由目标基站根据源基站的完整性保护算法和KgNB*生成的完整性保护密钥和加密密钥,分别进行完整性保护和加密。其中,目标基站所使用的KgNB*可以是来自源基站。具体实现过程可参考现有技术的相关方案,这里不再赘述。The connection recovery response message is used to instruct the terminal to resume the RRC connection. Optionally, the connection recovery response message may be integrity protected and encrypted by the target base station according to the integrity protection algorithm of the source base station and the integrity protection key and the encryption key generated by the KgNB*. The KgNB* used by the target base station may be from the source base station. For the specific implementation process, reference may be made to related solutions of the prior art, and details are not described herein again.
在步骤308之后,还包括终端从不活跃态进入连接态的后续流程,为现有技术内容,具体细节可参考相关文献的说明,这里不再赘述。After the step 308, the subsequent process of the terminal from the inactive state to the connected state is further included. For details, refer to the description of related documents, and details are not described herein again.
针对上述请求恢复连接的方法,存在的主要问题如下:The main problems with the above method for restoring connections are as follows:
一方面,若上述步骤301中采用方式一生成消息认证码,即终端每次生成的消息认证码是相同的。当终端第一次向目标基站发送连接恢复请求消息时,若目标基站拒绝终端的连接恢复请求,则终端在下一次(即第二次)发送连接恢复请求消息之前,攻击者可能窃取到了终端第一次发送连接恢复请求消息时携带的消息认证码,然后攻击者伪装成终端,向目标基站发送连接恢复请求消息,连接恢复请求消息中携带攻击者窃取到的消息认证码。若目标基站的负荷不是很重,则会执行上述步骤305-步骤308,导致源基站会校验消息认证码正确,然后将终端的上下文携带于上下文响应消息中发送给目标基站,并且,源基站会删除终端的上下文。进而,当终端第二次重新向目标基站发送连接恢复请求消息时,由于源基站已经删除了终端的上下文,导致该终端无法认证通过,因而终端无法从不活跃态进入连接态。当然,若目标基站的负荷较重,则目标基站会拒绝攻击者的连接恢复请求,但攻击者可以不停地攻击,直至目标基站同意攻击者的连接恢复请求。因而,该方式一存在上述易受攻击的问题,进而导致终端可能无法从不活跃态进入连接态。On the one hand, if the message authentication code is generated in the first step 301, that is, the message authentication code generated by the terminal is the same each time. When the terminal sends the connection recovery request message to the target base station for the first time, if the target base station rejects the connection recovery request of the terminal, the attacker may steal the first connection of the terminal before the next (ie, second) transmission of the connection recovery request message. The message authentication code carried in the connection recovery request message is sent, and then the attacker masquerades as a terminal, and sends a connection recovery request message to the target base station, where the connection recovery request message carries the message authentication code stolen by the attacker. If the load of the target base station is not heavy, the foregoing step 305-step 308 is performed, so that the source base station verifies that the message authentication code is correct, and then carries the context of the terminal in the context response message and sends the message to the target base station, and the source base station The context of the terminal is deleted. Further, when the terminal resends the connection recovery request message to the target base station for the second time, the source base station has deleted the context of the terminal, and the terminal cannot pass the authentication, so the terminal cannot enter the connected state from the inactive state. Of course, if the load of the target base station is heavy, the target base station rejects the attacker's connection recovery request, but the attacker can continuously attack until the target base station agrees to the attacker's connection recovery request. Therefore, in the first method, the above-mentioned vulnerable problem exists, and the terminal may not be able to enter the connected state from the inactive state.
另一方面,若上述步骤301中采用方式二生成消息认证码,即终端每次生成的消息认证码是不同的。当终端第一次向目标基站发送连接恢复请求消息时,若目标基站拒绝终端的连接恢复请求,此时,终端上存储的接入层密钥已经更新为KgNB*。但由于目标基站并没有通知源基站密钥已更新,因此,在源基站上存储的接入层密钥仍然是原来的接入层密钥KgNB。进而,当终端第二次向目标基站发送连接恢复请求消息时,若目标基站同意终端的连接恢复请求,此时,终端上存储的接入层密钥为KgNB*,而源基站上存储的接入层密钥为KgNB,导致源基站会对终端发送的消息认证码校验失败,终端无法从不活跃态进入连接态。因而,该方式二也存在可能无法从不活跃态进入连接态的问题。On the other hand, if the message authentication code is generated by using the mode 2 in the above step 301, the message authentication code generated by the terminal is different each time. When the terminal sends a connection recovery request message to the target base station for the first time, if the target base station rejects the connection recovery request of the terminal, the access layer key stored on the terminal has been updated to KgNB*. However, since the target base station does not notify the source base station that the key has been updated, the access layer key stored on the source base station is still the original access layer key KgNB. Further, when the terminal sends the connection recovery request message to the target base station for the second time, if the target base station agrees to the connection recovery request of the terminal, the access layer key stored on the terminal is KgNB*, and the connection is stored on the source base station. The inbound key is KgNB, and the source base station fails to check the authentication code of the message sent by the terminal. The terminal cannot enter the connected state from the inactive state. Therefore, there is also a problem that the second mode may not be able to enter the connected state from the inactive state.
针对图3所示的请求恢复连接的方法所存在的上述问题,本申请将提出以下解决方案。下面分别说明。The present application will propose the following solutions to the above problems with the method of requesting a connection recovery as shown in FIG. The following are explained separately.
解决方案一Solution one
该解决方案一可用于解决上述步骤301采用方式一生成消息认证码时存在的问题。The solution 1 can be used to solve the problem that the foregoing step 301 adopts the method 1 to generate the message authentication code.
如图4所示,为本申请提供的一种请求恢复连接的方法的流程图,包括以下步骤:As shown in FIG. 4, a flowchart of a method for requesting a recovery connection provided by the present application includes the following steps:
步骤401、终端根据新鲜性参数和终端的完整性保护密钥,生成消息认证码。Step 401: The terminal generates a message authentication code according to the freshness parameter and the integrity protection key of the terminal.
其中,相邻两次生成消息认证码所使用的新鲜性参数不同。即,新鲜性参数的具体取值,在每次生成消息认证码是会发生变化,导致当前生成消息认证码时所使用的新鲜性参数与上次生成消息认证码时所使用的新鲜性参数不同。The freshness parameters used to generate the message authentication code twice are different. That is, the specific value of the freshness parameter changes every time the message authentication code is generated, and the freshness parameter used when generating the message authentication code is different from the freshness parameter used when the message authentication code was last generated. .
作为一种实现方式,新鲜性参数包括分组数据汇聚协议计数((Packet Data Convergence Protocol COUNT,PDCP COUNT),PDCP COUNT可以包含上行PDCP COUNT和下行PDCP COUNT,终端每发送一个上行PDCP数据包则上行PDCP COUNT加1,基站每发送一个下行PDCP数据包则下行PDCP COUNT加1。例如,PDCP COUNT可以是信令无线承载(signaling radio bearer,SRB)的上行PDCP COUNT。可选地,每当重建无线承载时,PDCP COUNT可以重置为零。由于PDCP COUNT是一直在变化的,因此,终端每次生成的消息认证码与上次生成的消息认证码是不同的。As an implementation manner, the freshness parameter includes a Packet Data Convergence Protocol COUNT (PDCP COUNT), and the PDCP COUNT may include an uplink PDCP COUNT and a downlink PDCP COUNT, and the terminal uplinks the PDCP every time an uplink PDCP packet is sent. COUNT plus 1, the downlink PDCP COUNT is incremented by 1 for each downlink PDCP packet sent by the base station. For example, the PDCP COUNT may be an uplink PDCP COUNT of a signaling radio bearer (SRB). Optionally, whenever the radio bearer is re-established At the same time, the PDCP COUNT can be reset to zero. Since the PDCP COUNT is constantly changing, the message authentication code generated by the terminal each time is different from the last generated message authentication code.
作为另一种实现方式,新鲜性参数可以包括拒绝次数,拒绝次数可以用于表示终端尝试恢复RRC连接被网络侧拒绝的次数。终端每次尝试恢复被网络侧拒绝,则拒绝次数加1。可选地,每当恢复RRC连接成功时,拒绝次数可以重置为零。由于拒绝次数是一直在变化的,因此,终端每次生成的消息认证码与上次生成的消息认证码是不同的。As another implementation manner, the freshness parameter may include the number of rejections, and the number of rejections may be used to indicate the number of times the terminal attempts to restore the RRC connection rejected by the network side. Each time the terminal attempts to resume being rejected by the network side, the number of rejections is increased by one. Alternatively, the number of rejections may be reset to zero each time the RRC connection is successfully restored. Since the number of rejections is always changing, the message authentication code generated by the terminal each time is different from the message authentication code generated last time.
在具体实现中,可以是根据新鲜性参数、终端的完整性保护密钥和终端的完整性保护算法,生成消息认证码。In a specific implementation, the message authentication code may be generated according to the freshness parameter, the integrity protection key of the terminal, and the integrity protection algorithm of the terminal.
步骤402、终端向目标基站发送连接恢复请求消息,目标基站接收来自终端的连接恢复请求消息。Step 402: The terminal sends a connection recovery request message to the target base station, and the target base station receives a connection recovery request message from the terminal.
其中,连接恢复请求消息用于请求恢复RRC连接,连接恢复请求消息包括消息认证码和恢复标识,可选的,连接恢复请求消息还包含指示参数,该指示参数用于指示新鲜性参数。具体地,该指示参数可以是新鲜性参数本身,也可以是可指示该新鲜性参数的参数。连接恢复请求消息还包括恢复标识。The connection recovery request message is used to request to restore the RRC connection, and the connection recovery request message includes a message authentication code and a recovery identifier. Optionally, the connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter. Specifically, the indication parameter may be the freshness parameter itself, or may be a parameter indicating the freshness parameter. The connection recovery request message also includes a recovery identifier.
具体地,若新鲜性参数为拒绝次数,则连接恢复请求消息包括消息认证码和恢复标识。若新鲜性参数为PDCP COUNT,则连接恢复请求消息包括消息认证码、恢复标识和指示参数,指示参数用于指示PDCP COUNT。Specifically, if the freshness parameter is the number of rejections, the connection recovery request message includes a message authentication code and a recovery identifier. If the freshness parameter is PDCP COUNT, the connection recovery request message includes a message authentication code, a recovery identifier, and an indication parameter, and the indication parameter is used to indicate PDCP COUNT.
其中,若新鲜性参数为PDCP COUNT,且PDCP COUNT采用二进制比特位表示,则该指示参数PDCP COUNT本身,即为PDCP COUNT的全部比特位。该指示参数还可以是PDCP COUNT的部分比特位。Wherein, if the freshness parameter is PDCP COUNT, and the PDCP COUNT is represented by a binary bit, the indication parameter PDCP COUNT itself is all bits of the PDCP COUNT. The indication parameter can also be a partial bit of the PDCP COUNT.
举例来说,假设PDCP COUNT采用32个比特位来表示,由于相邻两次生成消息认证码时所使用的PDCP COUNT之间的变化不会特别大,因此,相邻两次的PDCP COUNT之间也只是低位的比特位发生变化,而高位的比特位不会发生变化。因此,指示参数可以使用PDCP COUNT的部分低比特位来表示。例如,终端上次生成消息认证码所使用的PDCP COUNT为“00000000000011111111111100011111”,而终端本次生成消息认证码所使用的PDCP COUNT为“00000000000011111111111100100011”,可以发现,PDCP COUNT只有低5位发生了变化,而高27位未发生变化。因此,可以选择PDCP COUNT的低N个比特位作为指示参数,N大于1,且小于32。当然,指示参数也可以是PDCP COUNT的全部比特位。For example, suppose the PDCP COUNT is represented by 32 bits. Since the change between the PDCP COUNTs used when generating the message authentication code two times is not particularly large, between two adjacent PDCP COUNTs Only the lower bits change, and the higher bits do not change. Therefore, the indication parameter can be represented using a portion of the low bit of the PDCP COUNT. For example, the PDCP COUNT used by the terminal to generate the message authentication code is “00000000000011111111111100011111”, and the PDCP COUNT used by the terminal to generate the message authentication code is “00000000000011111111111100100011”. It can be found that only the lower 5 bits of the PDCP COUNT have changed. The high 27 did not change. Therefore, the lower N bits of the PDCP COUNT can be selected as the indication parameter, N being greater than 1, and less than 32. Of course, the indication parameter can also be all bits of the PDCP COUNT.
其中,若新鲜性参数为拒绝次数,则终端和源基站之间各自维持该终端被拒绝恢复连接的次数。Wherein, if the freshness parameter is the number of rejections, the terminal and the source base station each maintain the number of times the terminal is refused to resume the connection.
通过上述步骤401-步骤402,终端每次生成的消息认证码与上次生成的消息认证码不同,因此,即使攻击者窃取到终端上次所使用的消息认证码,由于使用的“过期 的”消息认证码,因此,攻击者将无法攻击成功。Through the above steps 401 to 402, the message authentication code generated by the terminal is different from the message authentication code generated last time. Therefore, even if the attacker steals the message authentication code used by the terminal last time, the "expired" is used. The message authentication code, therefore, the attacker will not be able to attack successfully.
下面给出后续目标基站和源基站的实现方法。The implementation methods of the subsequent target base station and source base station are given below.
可选地,在上述步骤402之后,还包括以下方法步骤:Optionally, after the foregoing step 402, the following method steps are further included:
步骤403、目标基站判断是否同意终端的恢复请求。Step 403: The target base station determines whether to approve the recovery request of the terminal.
目标基站基于负载能力,判断是否可以接入该终端。The target base station determines whether the terminal can be accessed based on the load capability.
一种情形是,目标基站的负载比较重,不能接入该终端,则目标基站可以拒绝该终端的恢复请求,即拒绝该终端接入目标基站。此时,则执行步骤404-步骤407。In one case, if the load of the target base station is relatively heavy and cannot access the terminal, the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, step 404-step 407 is performed.
另一种情形是,目标基站的负载不是很重,还可以接入该终端,则目标基站可以同意该终端的恢复请求,即同意该终端接入目标基站。此时,则执行步骤408-步骤411。In another case, the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station. At this time, steps 408 to 411 are performed.
步骤404、目标基站向源基站发送通知消息,源基站接收来自目标基站的通知消息。Step 404: The target base station sends a notification message to the source base station, where the source base station receives the notification message from the target base station.
其中,通知消息包括目标基站从连接恢复请求消息中获取的消息认证码和恢复标识,可选地,还包含指示参数,其中,通知更新的源基站中的终端的上下文包括新鲜性参数。The notification message includes a message authentication code and a recovery identifier obtained by the target base station from the connection recovery request message, and optionally, an indication parameter, wherein the context of the terminal in the source base station that notifies the update includes a freshness parameter.
其中,通知消息具有以下功能中的一个或多个:Wherein, the notification message has one or more of the following functions:
通知消息用于通知更新源基站中的终端的上下文;The notification message is used to notify the update of the context of the terminal in the source base station;
通知消息用于通知目标基站将拒绝终端恢复连接;The notification message is used to notify the target base station that the terminal is refused to resume the connection;
通知消息用于通知更新源基站中的终端的上下文的新鲜性参数;The notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
通知消息用于通知更新源基站中的终端的上下文的密钥。The notification message is used to notify the key of the context of the terminal in the update source base station.
步骤405、源基站校验消息认证码,若校验消息认证码正确,则更新终端的上下文。Step 405: The source base station checks the message authentication code, and if the verification message authentication code is correct, updates the context of the terminal.
该步骤中,源基站首先根据通知消息中的恢复标识,获取到源基站中的终端的上下文。In this step, the source base station first acquires the context of the terminal in the source base station according to the recovery identifier in the notification message.
接着,源基站确定新鲜性参数。Next, the source base station determines the freshness parameter.
作为一种示例,源基站根据指示参数确定新鲜性参数。例如,当新鲜性参数为PDCP COUNT时,则源基站根据指示参数确定指示参数指示的PDCP COUNT。具体实现中,若指示参数指示的是PDCP COUNT的部分比特位,则源基站可以根据源基站当前存储的PDCP COUNT的部分高比特位,和指示参数指示的PDCP COUNT的部分低比特位,确定指示参数指示的PDCP COUNT。As an example, the source base station determines a freshness parameter based on the indication parameters. For example, when the freshness parameter is PDCP COUNT, the source base station determines the PDCP COUNT indicating the parameter indication according to the indication parameter. In a specific implementation, if the indication parameter indicates a partial bit of the PDCP COUNT, the source base station may determine the indication according to a part of the high bit of the PDCP COUNT currently stored by the source base station and a part of the low bit of the PDCP COUNT indicated by the parameter. The PDCP COUNT indicated by the parameter.
另一种示例,源基站直接确定新鲜性参数。例如,当新鲜性参数为拒绝次数时,则源基站将当前拒绝次数确定为拒绝次数。即目标基站可以直接本地获取到该终端的拒绝次数。As another example, the source base station directly determines the freshness parameter. For example, when the freshness parameter is the number of rejections, the source base station determines the current number of rejections as the number of rejections. That is, the target base station can directly obtain the number of rejections of the terminal locally.
接着,源基站根据新鲜性参数、源基站的完整性保护密钥和源基站的完整性保护算法,生成消息认证码,若生成的消息认证码与通知消息中携带的终端生成的消息认证码相同,则校验正确,若不同,则校验失败。Then, the source base station generates a message authentication code according to the freshness parameter, the integrity protection key of the source base station, and the integrity protection algorithm of the source base station, if the generated message authentication code is the same as the message authentication code generated by the terminal carried in the notification message. , the verification is correct, if it is different, the verification fails.
可选地,源基站可以根据新鲜性参数、源基站的完整性保护密钥和源基站的完整性保护算法,源PCI,源小区无线网络临时标识(cell radio network temporary identifier,C-RNTI),目标小区标识和恢复常量,生成消息认证码。Optionally, the source base station may be based on a freshness parameter, an integrity protection key of the source base station, and an integrity protection algorithm of the source base station, a source PCI, a cell radio network temporary identifier (C-RNTI), The target cell identifier and the recovery constant generate a message authentication code.
其中,若源基站校验消息认证码正确,则更新终端的上下文中的新鲜性参数。例如,当新鲜性参数为PDCP COUNT时,源基站更新源基站中的终端的上下文,包括: 若通知消息中的PDCP COUNT的数值大于源基站中的终端的上下文中的PDCP COUNT的数值,则源基站将终端的上下文中的PDCP COUNT的数值更新为通知消息中的PDCP COUNT的数值,或者理解为,终端的上下文中的PDCP COUNT的数值更新为指示参数指示的PDCP COUNT的数值。再比如,当新鲜性参数为拒绝次数时,源基站根据新鲜性参数更新源基站中的终端的上下文,包括:源基站将拒绝次数加1。Wherein, if the source base station verifies that the message authentication code is correct, the freshness parameter in the context of the terminal is updated. For example, when the freshness parameter is PDCP COUNT, the source base station updates the context of the terminal in the source base station, including: if the value of the PDCP COUNT in the notification message is greater than the value of the PDCP COUNT in the context of the terminal in the source base station, the source The base station updates the value of the PDCP COUNT in the context of the terminal to the value of the PDCP COUNT in the notification message, or understands that the value of the PDCP COUNT in the context of the terminal is updated to the value of the PDCP COUNT indicating the parameter indication. For another example, when the freshness parameter is the number of rejections, the source base station updates the context of the terminal in the source base station according to the freshness parameter, including: the source base station increases the number of rejections by one.
作为另一种实现方式,还可以是源基站先判断通知消息中的PDCP COUNT的数值是否大于源基站中的终端的上下文中的PDCP COUNT的数值,若通知消息中的PDCP COUNT的数值大于源基站中的终端的上下文中的PDCP COUNT的数值,则源基站校验消息认证码,若校验消息认证码正确,则根据新鲜性参数,更新终端的上下文中的新鲜性参数,具体更新方法为:源基站将终端的上下文中的PDCP COUNT的数值更新为通知消息中的PDCP COUNT的数值。As another implementation manner, the source base station may first determine whether the value of the PDCP COUNT in the notification message is greater than the value of the PDCP COUNT in the context of the terminal in the source base station, if the value of the PDCP COUNT in the notification message is greater than the source base station. If the value of the PDCP COUNT in the context of the terminal in the terminal is correct, the source base station checks the message authentication code. If the verification message authentication code is correct, the freshness parameter in the context of the terminal is updated according to the freshness parameter. The specific update method is: The source base station updates the value of the PDCP COUNT in the context of the terminal to the value of the PDCP COUNT in the notification message.
步骤406、源基站向目标基站发送响应消息,目标基站接收来自源基站的响应消息。Step 406: The source base station sends a response message to the target base station, and the target base station receives the response message from the source base station.
该步骤406为可选步骤,响应消息用于源基站在终端的上下文更新完成后,通知目标基站。The step 406 is an optional step, and the response message is used by the source base station to notify the target base station after the context update of the terminal is completed.
步骤407、目标基站向终端发送连接恢复拒绝消息,终端接收来自目标基站的连接恢复拒绝消息。Step 407: The target base station sends a connection recovery reject message to the terminal, where the terminal receives a connection recovery reject message from the target base station.
该步骤407与上述步骤304相同,可参考前述描述。This step 407 is the same as step 304 above, and can be referred to the foregoing description.
当新鲜性参数为拒绝次数时,终端在收到连接恢复拒绝消息后,会更新拒绝次数,包括:将拒绝次数加1。When the freshness parameter is the number of rejections, the terminal updates the number of rejections after receiving the connection recovery rejection message, including: adding 1 to the number of rejections.
需要说明的是,上述步骤407与步骤404-步骤406之间没有顺序限定,即步骤407可以在步骤404之前执行,也可以在步骤406之后执行,还可以在步骤404-步骤406之间执行。It should be noted that there is no order limitation between the above step 407 and step 404-step 406, that is, step 407 may be performed before step 404, may be performed after step 406, and may also be performed between step 404-step 406.
通过上述步骤404-步骤407,当目标基站决定拒绝终端的连接恢复请求时,一方面,目标基站通知终端拒绝连接恢复请求,另一方面,还通知源基站更新终端的上下文,具体地,更新源基站中存储的新鲜性参数。从而使得终端与源基站之间的新鲜性参数保持一致。Through the above steps 404-407, when the target base station decides to reject the connection recovery request of the terminal, on the one hand, the target base station notifies the terminal to reject the connection recovery request, and on the other hand, notifies the source base station to update the context of the terminal, specifically, the update source. Freshness parameters stored in the base station. Thereby the freshness parameters between the terminal and the source base station are kept consistent.
步骤408、目标基站向源基站发送上下文请求消息,源基站接收来自目标基站的上下文请求消息。Step 408: The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
上下文请求消息包括终端生成的消息认证码和恢复标识,上下文请求消息用于请求获取终端的上下文。可选的,上下文请求消息还包括指示参数。The context request message includes a message authentication code and a recovery identifier generated by the terminal, and the context request message is used to request to acquire the context of the terminal. Optionally, the context request message further includes an indication parameter.
步骤409、源基站若校验消息认证码正确,则更新终端的上下文中的新鲜性参数。Step 409: The source base station updates the freshness parameter in the context of the terminal if the verification message authentication code is correct.
其中,源基站校验消息认证码的方式,及源基站更新终端的上下文中的新鲜性参数的方式,可参考上述步骤405的描述,这里不再赘述。For the manner in which the source base station checks the message authentication code and the manner in which the source base station updates the freshness parameter in the context of the terminal, refer to the description of step 405 above, and details are not described herein again.
步骤410、源基站向目标基站发送上下文响应消息,目标基站接收来自源基站的上下文响应消息。Step 410: The source base station sends a context response message to the target base station, where the target base station receives a context response message from the source base station.
步骤411、目标基站向终端发送连接恢复响应消息,终端接收来自目标基站的连接恢复响应消息。Step 411: The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
上述步骤410-步骤411,与上述步骤307-步骤308相同,可参数前述描述,这里不再赘述。The foregoing steps 410-411 are the same as the above steps 307-308, and the foregoing description may be omitted, and details are not described herein again.
通过上述步骤408-步骤411,当目标基站决定同意恢复终端的连接时,源基站根据新鲜性参数,对终端的消息认证码进行校验,且在校验正确时,一方面,更新源基站的终端的上下文中的新鲜性参数,另一方面,将获取的终端的上下文发送给目标基站。Through the foregoing steps 408-411, when the target base station decides to agree to restore the connection of the terminal, the source base station checks the message authentication code of the terminal according to the freshness parameter, and when the verification is correct, on the one hand, updates the source base station. The freshness parameter in the context of the terminal, on the other hand, sends the context of the acquired terminal to the target base station.
通过上述步骤401-步骤411的方法,在终端生成消息认证码的输入参数中引入了新鲜性参数,相应地,在源基站校验消息认证码的输入参数中也引入了新鲜性参数。一方面,若目标基站拒绝了终端的连接恢复请求,则目标基站可以通过步骤404通知源基站更新终端的上下文中的新鲜性参数,从而保持终端与源基站的新鲜性参数的一致。另一方面,若目标基站同意了终端的连接恢复请求,则目标基站可以通过步骤408请求从源基站获取终端的上下文,同时,源基站还可在此过程中更新源基站的终端上下文中的新鲜性参数,从而保持终端与源基站的新鲜性参数的一致。Through the method of the above steps 401-411, the freshness parameter is introduced in the input parameter of the terminal to generate the message authentication code, and accordingly, the freshness parameter is also introduced in the input parameter of the source base station verification message authentication code. On the one hand, if the target base station rejects the connection recovery request of the terminal, the target base station may notify the source base station to update the freshness parameter in the context of the terminal by step 404, thereby maintaining the consistency of the freshness parameter of the terminal and the source base station. On the other hand, if the target base station agrees to the connection recovery request of the terminal, the target base station may request to acquire the context of the terminal from the source base station through step 408, and at the same time, the source base station may also update the source context of the source base station in the process. Sexual parameters, thereby maintaining the consistency of the terminal with the freshness parameters of the source base station.
上述解决方案一可有效解决上述步骤301采用方式一生成消息认证码时,所存在的易受攻击的问题。下面结合具体例子进行解释说明。The foregoing solution 1 can effectively solve the problem that the above-mentioned step 301 adopts the method 1 to generate a message authentication code, which is vulnerable. The following is explained in conjunction with specific examples.
以新鲜性参数为PDCP COUNT为例,假设终端与源基站当前存储的PDCP COUNT的数值均为5,且终端当前处于不活跃态。Taking the freshness parameter as the PDCP COUNT as an example, it is assumed that the value of the PDCP COUNT currently stored by the terminal and the source base station is 5, and the terminal is currently in an inactive state.
终端第一次向目标基站发送连接恢复请求消息,连接恢复请求消息中携带消息认证码、指示参数和恢复标识,该消息认证码是根据PDCP COUNT和终端的完整性保护密钥生成的,且该指示参数指示的PDCP COUNT大于5,例如为10。The terminal sends a connection recovery request message to the target base station for the first time. The connection recovery request message carries a message authentication code, an indication parameter, and a recovery identifier, and the message authentication code is generated according to the PDCP COUNT and the integrity protection key of the terminal, and the The PDCP COUNT indicated by the indication parameter is greater than 5, for example 10.
目标基站若拒绝了终端的连接恢复请求,向终端发送的连接恢复拒绝消息中携带等待计时器的信息,指示终端30分钟后可以尝试重新发起连接恢复请求。同时,目标基站通知源基站将源基站的终端的上下文中的PDCP COUNT更新为10。If the target base station rejects the connection recovery request of the terminal, the connection recovery rejection message sent to the terminal carries the information of the waiting timer, and instructs the terminal to try to re-initiate the connection recovery request after 30 minutes. At the same time, the target base station informs the source base station to update the PDCP COUNT in the context of the terminal of the source base station to 10.
假设在终端第二次向目标基站发送连接恢复请求消息之前,攻击者从终端第一次向目标基站发送的连接恢复请求消息中窃取到了消息认证码和恢复标识,其中,生成该消息认证码所使用的PDCP COUNT为10。It is assumed that before the terminal sends the connection recovery request message to the target base station for the second time, the attacker steals the message authentication code and the recovery identifier from the connection recovery request message sent by the terminal to the target base station for the first time, where the message authentication code is generated. The PDCP COUNT used is 10.
接着,攻击者向目标基站发送连接恢复请求消息,连接恢复请求消息中携带窃取到的消息认证码和恢复标识,目标基站接收到连接恢复请求消息后,若同意该攻击者的恢复请求,则向源基站发送上下文请求消息。接着,源基站对攻击者发送的消息认证码进行校验,由于攻击者发送的消息认证码在生成时所使用的PDCP COUNT为10,源基站的终端的上下文中的PDCP COUNT也为10,二者相等,因此校验失败。从而,攻击者攻击失败。Then, the attacker sends a connection recovery request message to the target base station, where the connection recovery request message carries the stolen message authentication code and the recovery identifier, and after receiving the connection recovery request message, the target base station, if it agrees to the attacker's recovery request, then The source base station sends a context request message. Then, the source base station checks the message authentication code sent by the attacker. The PDCP COUNT used in the generation of the message authentication code sent by the attacker is 10, and the PDCP COUNT in the context of the terminal of the source base station is also 10, two. The two are equal, so the verification fails. Thus, the attacker fails to attack.
以新鲜性参数为拒绝次数为例,假设终端与源基站当前存储的拒绝次数的数值均为2,且终端当前处于不活跃态。Taking the freshness parameter as the number of rejections, the value of the number of rejections currently stored by the terminal and the source base station is 2, and the terminal is currently in an inactive state.
终端第一次向目标基站发送连接恢复请求消息,连接恢复请求消息中携带消息认证码和恢复标识,该消息认证码是根据拒绝次数和终端的完整性保护密钥生成的,此时拒绝次数为2。The terminal sends a connection recovery request message to the target base station for the first time. The connection recovery request message carries a message authentication code and a recovery identifier. The message authentication code is generated according to the number of rejections and the integrity protection key of the terminal. 2.
目标基站若拒绝了终端的连接恢复请求,向终端发送的连接恢复拒绝消息中携带等待计时器的信息,指示终端30分钟后可以尝试重新发起连接恢复请求,此时终端更新拒绝次数为3。同时,目标基站通知源基站将源基站的终端的上下文中的拒绝次数更新为3。If the target base station rejects the connection recovery request of the terminal, the connection recovery rejection message sent to the terminal carries the information of the waiting timer, indicating that the terminal may try to re-initiate the connection recovery request after 30 minutes, and the terminal update rejection number is 3. At the same time, the target base station notifies the source base station to update the number of rejections in the context of the terminal of the source base station to 3.
假设在终端第二次向目标基站发送连接恢复请求消息之前,攻击者从终端第一次 向目标基站发送的连接恢复请求消息中窃取到了消息认证码和恢复标识,其中,生成该消息认证码所使用的拒绝次数为2。It is assumed that before the terminal sends the connection recovery request message to the target base station for the second time, the attacker steals the message authentication code and the recovery identifier from the connection recovery request message sent by the terminal to the target base station for the first time, where the message authentication code is generated. The number of rejections used is 2.
接着,攻击者向目标基站发送连接恢复请求消息,连接恢复请求消息中携带窃取到的消息认证码和恢复标识,目标基站接收到连接恢复请求消息后,若同意该攻击者的恢复请求,则向源基站发送上下文请求消息。接着,源基站对攻击者发送的消息认证码进行校验,由于攻击者发送的消息认证码在生成时所使用的拒绝次数为2,源基站的终端的上下文中的拒绝次数为3,因此校验失败。从而,攻击者攻击失败。Then, the attacker sends a connection recovery request message to the target base station, where the connection recovery request message carries the stolen message authentication code and the recovery identifier, and after receiving the connection recovery request message, the target base station, if it agrees to the attacker's recovery request, then The source base station sends a context request message. Then, the source base station checks the message authentication code sent by the attacker, because the number of rejections used by the attacker to send the message authentication code is 2, and the number of rejections in the context of the terminal of the source base station is 3, so the school The test failed. Thus, the attacker fails to attack.
因此,本申请提供的上述解决方案一,可以有效解决上述步骤301生成消息认证码的方法一所存在的问题,可以有效抵抗攻击者的攻击。Therefore, the first solution provided by the present application can effectively solve the problem of the method 1 for generating the message authentication code in the foregoing step 301, and can effectively resist the attack of the attacker.
解决方案二Solution two
该解决方案二可用于解决上述步骤301采用方式二生成消息认证码时存在的问题。The solution 2 can be used to solve the problem that the foregoing step 301 uses the second method to generate the message authentication code.
步骤501、终端生成消息认证码。Step 501: The terminal generates a message authentication code.
该步骤501与上述步骤301的方式二相同,可参考前述描述。The step 501 is the same as the second method of the foregoing step 301, and the foregoing description may be referred to.
在该步骤501中,终端生成消息认证码的同时,也会更新接入层密钥,即由KgNB更新为KgNB*,同时也会更新完整性保护密钥,即由Krrc-int更新为Krrc-int*。In this step 501, when the terminal generates the message authentication code, the access layer key is also updated, that is, updated by KgNB to KgNB*, and the integrity protection key is also updated, that is, updated by Krrc-int to Krrc- Int*.
步骤502、终端向目标基站发送连接恢复请求消息,目标基站接收来自终端的连接恢复请求消息。Step 502: The terminal sends a connection recovery request message to the target base station, where the target base station receives a connection recovery request message from the terminal.
该步骤502与前述步骤302相同,可参考前述描述。This step 502 is the same as the foregoing step 302, and the foregoing description can be referred to.
步骤503、目标基站判断是否同意终端的恢复请求。Step 503: The target base station determines whether to agree to the recovery request of the terminal.
目标基站基于负载能力,判断是否可以接入该终端。The target base station determines whether the terminal can be accessed based on the load capability.
一种情形是,目标基站的负载比较重,不能接入该终端,则目标基站可以拒绝该终端的恢复请求,即拒绝该终端接入目标基站。此时,则执行步骤504-步骤507。In one case, if the load of the target base station is relatively heavy and cannot access the terminal, the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, steps 504 to 507 are performed.
另一种情形是,目标基站的负载不是很重,还可以接入该终端,则目标基站可以同意该终端的恢复请求,即同意该终端接入目标基站。此时,则执行步骤508-步骤511。In another case, the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station. At this time, step 508-step 511 is performed.
步骤504、目标基站向源基站发送通知消息,源基站接收来自目标基站的通知消息。Step 504: The target base station sends a notification message to the source base station, where the source base station receives the notification message from the target base station.
其中,通知消息包括目标基站从连接恢复请求消息中获取的消息认证码和恢复标识。The notification message includes a message authentication code and a recovery identifier obtained by the target base station from the connection recovery request message.
其中,通知消息具有以下功能中的一个或多个:Wherein, the notification message has one or more of the following functions:
通知消息用于通知更新源基站中的终端的上下文;The notification message is used to notify the update of the context of the terminal in the source base station;
通知消息用于通知目标基站将拒绝终端恢复连接;The notification message is used to notify the target base station that the terminal is refused to resume the connection;
通知消息用于通知更新源基站中的终端的上下文的新鲜性参数;The notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
通知消息用于通知更新源基站中的终端的上下文的密钥。The notification message is used to notify the key of the context of the terminal in the update source base station.
其中,该密钥可以是接入层密钥,和/或,完整性保护密钥。The key may be an access layer key, and/or an integrity protection key.
步骤505、源基站校验消息认证码,若校验消息认证码正确,则更新终端的上下文的密钥。Step 505: The source base station checks the message authentication code, and if the verification message authentication code is correct, updates the key of the context of the terminal.
该步骤中,源基站首先根据通知消息中的恢复标识,获取源基站中的终端的上下文。In this step, the source base station first acquires the context of the terminal in the source base station according to the recovery identifier in the notification message.
接着,源基站根据源基站的完整性保护算法和源基站的完整性保护密钥,生成消息认证码,若生成的消息认证码与通知消息中携带的消息认证码相同,则校验正确, 若不同,则校验失败。其中,源基站生成消息认证码所使用的源基站的完整性保护密钥是源基站生成的新的完整性保护密钥Krrc-int*,具体生成方法可参考上述步骤306中的相关描述,这里不再赘述。Then, the source base station generates a message authentication code according to the integrity protection algorithm of the source base station and the integrity protection key of the source base station. If the generated message authentication code is the same as the message authentication code carried in the notification message, the verification is correct. Different, the verification fails. The integrity protection key of the source base station used by the source base station to generate the message authentication code is the new integrity protection key Krrc-int* generated by the source base station. For the specific generation method, refer to the related description in step 306 above. No longer.
源基站校验消息认证码,若校验消息认证码正确,则更新终端的上下文的接入层密钥,和/或,完整性保护密钥。The source base station verifies the message authentication code, and if the verification message authentication code is correct, updates the access layer key of the context of the terminal, and/or the integrity protection key.
步骤506、源基站向目标基站发送响应消息,目标基站接收来自源基站的响应消息。Step 506: The source base station sends a response message to the target base station, and the target base station receives the response message from the source base station.
该步骤506为可选步骤,响应消息用于源基站在终端的上下文更新完成后,通知目标基站。The step 506 is an optional step, and the response message is used by the source base station to notify the target base station after the context update of the terminal is completed.
步骤507、目标基站向终端发送连接恢复拒绝消息,终端接收来自目标基站的连接恢复拒绝消息。Step 507: The target base station sends a connection recovery reject message to the terminal, where the terminal receives a connection recovery reject message from the target base station.
该步骤507与上述步骤304相同,可参数前述描述。This step 507 is the same as step 304 above, and the foregoing description can be parameterized.
需要说明的是,上述步骤507与步骤504-步骤506之间没有顺序限定,即步骤507可以在步骤504之前执行,也可以在步骤506之后执行,还可以在步骤504-步骤506之间执行。It should be noted that there is no order limitation between the above steps 507 and 504-step 506, that is, step 507 may be performed before step 504, may be performed after step 506, and may also be performed between steps 504-506.
通过上述步骤504-步骤507,当目标基站决定拒绝终端的连接恢复请求时,一方面,目标基站通知终端拒绝连接恢复请求,另一方面,还通知源基站更新终端的上下文的密钥。从而使得终端与源基站之间的密钥保持一致。Through the above steps 504-507, when the target base station decides to reject the connection recovery request of the terminal, on the one hand, the target base station notifies the terminal to reject the connection recovery request, and on the other hand, notifies the source base station to update the key of the context of the terminal. Thereby the keys between the terminal and the source base station are kept consistent.
步骤508、目标基站向源基站发送上下文请求消息,源基站接收来自目标基站的上下文请求消息。Step 508: The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
上下文请求消息包括终端生成的消息认证码和恢复标识,上下文请求消息用于请求获取终端的上下文。The context request message includes a message authentication code and a recovery identifier generated by the terminal, and the context request message is used to request to acquire the context of the terminal.
该步骤与上述步骤305相同,可参考前述描述。This step is the same as step 305 above, and the foregoing description can be referred to.
步骤509、源基站若校验消息认证码正确,则获取终端的上下文。Step 509: The source base station acquires the context of the terminal if the verification message authentication code is correct.
其中,源基站校验消息认证码的具体方式,可参考上述步骤306中,当终端采用方式二生成消息认证码时,源基站所采用的消息认证码的校验方式。For the specific manner of the source base station verifying the message authentication code, reference may be made to the verification mode of the message authentication code used by the source base station when the terminal uses the mode 2 to generate the message authentication code in the foregoing step 306.
步骤510、源基站若校验消息认证码正确,则向目标基站发送上下文响应消息。Step 510: The source base station sends a context response message to the target base station if the verification message authentication code is correct.
上下文响应消息中可以包括终端的上下文,例如包括源基站的完整性保护算法、源基站的完整性保护密钥。可选地,还包括上述生成的KgNB*。The context response message may include a context of the terminal, for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station. Optionally, the generated KgNB* is also included.
步骤511、目标基站向终端发送连接恢复响应消息,终端接收来自目标基站的连接恢复响应消息。Step 511: The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
该连接恢复响应消息用于指示终端恢复RRC连接。可选地,该连接恢复响应消息可由目标基站根据源基站的完整性保护算法和KgNB*生成的完整性保护密钥和加密密钥,分别进行完整性保护和加密。具体实现过程可参考现有技术的相关方案,这里不再赘述。The connection recovery response message is used to instruct the terminal to resume the RRC connection. Optionally, the connection recovery response message may be integrity protected and encrypted by the target base station according to the integrity protection algorithm of the source base station and the integrity protection key and the encryption key generated by the KgNB*. For the specific implementation process, reference may be made to related solutions of the prior art, and details are not described herein again.
在步骤308之后,还包括终端从不活跃态进入连接态的后续流程,为现有技术内容,具体细节可参考相关文献的说明,这里不再赘述。After the step 308, the subsequent process of the terminal from the inactive state to the connected state is further included. For details, refer to the description of related documents, and details are not described herein again.
通过上述步骤501-步骤511所示的请求恢复连接的方法,可以有效解决上述步骤301中采用方式二生成消息认证码时所存在的问题,图5所示的方案中,当目标基站决定拒绝终端的请求连接恢复时,目标基站还通过步骤504,向源基站发送通知消息, 用于通知源基站更新密钥,从而使得终端与源基站之间始终保持密钥相同,因而可以有效解决终端与源基站之间的密钥不同步所带来的终端无法恢复连接的问题。The method for restoring the connection as shown in the above steps 501 to 511 can effectively solve the problem that occurs when the message authentication code is generated by the second method in the foregoing step 301. In the solution shown in FIG. 5, when the target base station decides to reject the terminal, When the request connection is restored, the target base station sends a notification message to the source base station to notify the source base station to update the key, so that the key is always the same between the terminal and the source base station, so that the terminal and the source can be effectively solved. The terminal that is not synchronized between the base stations cannot solve the problem of the connection being restored.
作为一种可替代的方法,在图5所示的流程中,在目标基站拒绝终端的连接恢复请求的场景中,还可以删除步骤504-步骤506,并在步骤507之后增加终端的操作:终端将终端的接入层密钥恢复为更新前的接入层密钥。As an alternative, in the scenario shown in FIG. 5, in the scenario where the target base station rejects the connection recovery request of the terminal, step 504-step 506 may also be deleted, and after step 507, the operation of the terminal is added: the terminal Restore the access layer key of the terminal to the access layer key before the update.
由于在目标基站拒绝终端的连接恢复请求的场景中,终端已经更新了接入层密钥,为了保持终端与源基站之间的密钥一致,也可以采用由终端回退密钥的方式,将终端的接入层密钥恢复为更新前的接入层密钥。因而,也可以达到使得终端与源基站之间始终保持密钥相同的目的,进而也可以有效解决终端与源基站之间的密钥不同步所带来的终端无法恢复连接的问题。In the scenario where the target base station rejects the connection recovery request of the terminal, the terminal has updated the access layer key. In order to keep the key between the terminal and the source base station consistent, the terminal may also use the method of backing off the key by the terminal. The access layer key of the terminal is restored to the access layer key before the update. Therefore, the purpose of maintaining the same key between the terminal and the source base station is also achieved, and the problem that the terminal cannot be restored due to the key synchronization between the terminal and the source base station can be effectively solved.
解决方案三Solution three
该解决方案三是将上述解决方案一和解决方案二相结合,而得到的一种解决方案。该解决方案三在解决上述密钥不一致的问题的同时,还可以有效抵抗攻击者的攻击。The solution three is a solution obtained by combining the above solution one and the solution two. The solution 3 can effectively resist the attacker's attack while solving the above problem of inconsistent key.
步骤601、终端生成消息认证码。Step 601: The terminal generates a message authentication code.
这里,是结合上述步骤401生成消息认证码的方式和步骤501生成消息认证码的方式,来生成消息认证码的。具体地,终端根据终端的完整性保护算法、终端的完整性保护密钥和新鲜性参数,生成消息认证码,其中,终端的完整性保护密钥为Krrc-int*,Krrc-int*是根据更新的接入层密钥KgNB*、终端的完整性保护算法的标识以及终端的完整性保护算法的类型生成的。Here, the message authentication code is generated by combining the manner in which the message authentication code is generated in the above step 401 and the manner in which the message authentication code is generated in step 501. Specifically, the terminal generates a message authentication code according to the integrity protection algorithm of the terminal, the integrity protection key of the terminal, and the freshness parameter, where the integrity protection key of the terminal is Krrc-int*, and the Krrc-int* is based on The updated access layer key KgNB*, the identity of the integrity protection algorithm of the terminal, and the type of integrity protection algorithm of the terminal are generated.
步骤602、终端向目标基站发送连接恢复请求消息,目标基站接收来自终端的连接恢复请求消息。Step 602: The terminal sends a connection recovery request message to the target base station, where the target base station receives a connection recovery request message from the terminal.
连接恢复请求消息包括消息认证码和恢复标识,可选地,连接恢复请求还包含指示参数,指示参数用于指示新鲜性参数。The connection recovery request message includes a message authentication code and a recovery identifier. Optionally, the connection recovery request further includes an indication parameter, and the indication parameter is used to indicate a freshness parameter.
步骤603、目标基站判断是否同意终端的恢复请求。Step 603: The target base station determines whether to approve the recovery request of the terminal.
目标基站基于负载能力,判断是否可以接入该终端。The target base station determines whether the terminal can be accessed based on the load capability.
一种情形是,目标基站的负载比较重,不能接入该终端,则目标基站可以拒绝该终端的恢复请求,即拒绝该终端接入目标基站。此时,则执行步骤604-步骤607。In one case, if the load of the target base station is relatively heavy and cannot access the terminal, the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, steps 604 to 607 are performed.
另一种情形是,目标基站的负载不是很重,还可以接入该终端,则目标基站可以同意该终端的恢复请求,即同意该终端接入目标基站。此时,则执行步骤608-步骤611。In another case, the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station. At this time, step 608-step 611 is performed.
步骤604、目标基站向源基站发送通知消息,源基站接收来自目标基站的通知消息。Step 604: The target base station sends a notification message to the source base station, where the source base station receives the notification message from the target base station.
其中,通知消息包括目标基站从连接恢复请求消息中获取的消息认证码和恢复标识,可选地,通知消息还可以包含指示参数。The notification message includes a message authentication code and a recovery identifier obtained by the target base station from the connection recovery request message. Optionally, the notification message may further include an indication parameter.
其中,通知消息具有以下功能中的一个或多个:Wherein, the notification message has one or more of the following functions:
通知消息用于通知更新源基站中的终端的上下文;The notification message is used to notify the update of the context of the terminal in the source base station;
通知消息用于通知目标基站将拒绝终端恢复连接;The notification message is used to notify the target base station that the terminal is refused to resume the connection;
通知消息用于通知更新源基站中的终端的上下文的新鲜性参数;The notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
通知消息用于通知更新源基站中的终端的上下文的密钥。The notification message is used to notify the key of the context of the terminal in the update source base station.
其中,该密钥可以是接入层密钥,和/或,完整性保护密钥。The key may be an access layer key, and/or an integrity protection key.
步骤605、源基站校验消息认证码,若校验消息认证码正确,则更新终端的上下 文的新鲜性参数和密钥。Step 605: The source base station checks the message authentication code. If the verification message authentication code is correct, the freshness parameter and the key of the context of the terminal are updated.
该步骤中,源基站首先根据通知消息中的恢复标识,确定源基站中的终端的上下文。In this step, the source base station first determines the context of the terminal in the source base station according to the recovery identifier in the notification message.
接着,源基站确定新鲜性参数。源基站可以根据通知消息中的指示参数确定新鲜性参数。例如,当新鲜性参数为PDCP COUNT时,则源基站根据指示参数确定指示参数指示的PDCP COUNT。源基站还可以直接确定新鲜性参数。例如,当新鲜性参数为拒绝次数时,则源基站将当前拒绝次数确定为拒绝次数。Next, the source base station determines the freshness parameter. The source base station may determine the freshness parameter according to the indication parameter in the notification message. For example, when the freshness parameter is PDCP COUNT, the source base station determines the PDCP COUNT indicating the parameter indication according to the indication parameter. The source base station can also directly determine the freshness parameters. For example, when the freshness parameter is the number of rejections, the source base station determines the current number of rejections as the number of rejections.
接着,源基站根据新鲜性参数、源基站的完整性保护密钥和源基站的完整性保护算法,生成消息认证码,若生成的消息认证码与通知消息中携带的终端生成的消息认证码相同,则校验正确,若不同,则校验失败。其中,源基站生成消息认证码所使用的源基站的完整性保护密钥,是源基站生成的新的完整性保护密钥Krrc-int*。Then, the source base station generates a message authentication code according to the freshness parameter, the integrity protection key of the source base station, and the integrity protection algorithm of the source base station, if the generated message authentication code is the same as the message authentication code generated by the terminal carried in the notification message. , the verification is correct, if it is different, the verification fails. The integrity protection key of the source base station used by the source base station to generate the message authentication code is a new integrity protection key Krrc-int* generated by the source base station.
其中,若源基站校验消息认证码正确,则根据新鲜性参数,更新终端的上下文中的新鲜性参数。具体可参考前述步骤405的相关描述。以及,源基站还更新终端的上下文中的密钥。例如,将源基站中的完整性保护密钥Krrc-int更新为Krrc-int*,和/或,将源基站中的接入层密钥KgNB更新为KgNB*。If the source base station check message authentication code is correct, the freshness parameter in the context of the terminal is updated according to the freshness parameter. For details, refer to the related description of the foregoing step 405. And, the source base station also updates the key in the context of the terminal. For example, the integrity protection key Krrc-int in the source base station is updated to Krrc-int*, and/or the access layer key KgNB in the source base station is updated to KgNB*.
步骤606、源基站向目标基站发送响应消息,目标基站接收来自源基站的响应消息。Step 606: The source base station sends a response message to the target base station, and the target base station receives the response message from the source base station.
该步骤606为可选步骤,响应消息用于源基站在终端的上下文更新完成后,通知目标基站。The step 606 is an optional step, and the response message is used by the source base station to notify the target base station after the context update of the terminal is completed.
步骤607、目标基站向终端发送连接恢复拒绝消息,终端接收来自目标基站的连接恢复拒绝消息。Step 607: The target base station sends a connection recovery reject message to the terminal, where the terminal receives a connection recovery reject message from the target base station.
该步骤607与上述步骤404相同,可参数前述描述。This step 607 is the same as step 404 above, and the foregoing description can be parameterized.
需要说明的是,上述步骤607与步骤604-步骤606之间没有顺序限定,即步骤607可以在步骤604之前执行,也可以在步骤606之后执行,还可以在步骤604-步骤606之间执行。It should be noted that there is no order limitation between the above steps 607 and 604-step 606, that is, step 607 may be performed before step 604, may be performed after step 606, and may also be performed between steps 604-606.
通过上述步骤604-步骤607,当目标基站决定拒绝终端的连接恢复请求时,一方面,目标基站通知终端拒绝连接恢复请求,另一方面,还通知源基站更新终端的上下文,具体地,更新源基站中存储的新鲜性参数和密钥。从而使得终端与源基站之间的新鲜性参数保持一致,且密钥保持一致。Through the above steps 604-step 607, when the target base station decides to reject the connection recovery request of the terminal, on the one hand, the target base station notifies the terminal to reject the connection recovery request, and on the other hand, notifies the source base station to update the context of the terminal, specifically, the update source. Freshness parameters and keys stored in the base station. Therefore, the freshness parameters between the terminal and the source base station are consistent, and the keys are consistent.
步骤608、目标基站向源基站发送上下文请求消息,源基站接收来自目标基站的上下文请求消息。Step 608: The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
上下文请求消息包括终端生成的消息认证码、新鲜性参数和恢复标识,上下文请求消息用于请求获取终端的上下文。The context request message includes a message authentication code generated by the terminal, a freshness parameter, and a recovery identifier, and the context request message is used to request to acquire the context of the terminal.
步骤609、源基站若校验消息认证码正确,则更新终端的上下文中的新鲜性参数和密钥。Step 609: If the source base station verifies that the message authentication code is correct, the freshness parameter and the key in the context of the terminal are updated.
其中,源基站校验消息认证码的方式,及源基站更新终端的上下文中的新鲜性参数和密钥的方式,可参考上述步骤605的描述,这里不再赘述。For the manner in which the source base station checks the message authentication code, and the manner in which the source base station updates the freshness parameter and the key in the context of the terminal, refer to the description of step 605 above, and details are not described herein again.
步骤610、源基站向目标基站发送上下文响应消息,目标基站接收来自源基站的上下文响应消息。Step 610: The source base station sends a context response message to the target base station, and the target base station receives a context response message from the source base station.
步骤611、目标基站向终端发送连接恢复响应消息,终端接收来自目标基站的连 接恢复响应消息。Step 611: The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
上述步骤610-步骤611,与上述步骤307-步骤308相同,可参数前述描述,这里不再赘述。The foregoing steps 610-611 are the same as the above steps 307-308, and the foregoing description may be omitted, and details are not described herein again.
通过上述步骤608-步骤611,当目标基站决定同意恢复终端的连接时,源基站根据新鲜性参数、源基站的完整性保护密钥和源基站的完整性保护算法,对终端的消息认证码进行校验,且在校验正确时,一方面,根据终端的新鲜性参数更新源基站的终端的上下文中的新鲜性参数,以及更新源基站的终端的上下文中的密钥,另一方面,将获取的终端的上下文发送给目标基站。Through the above steps 608-step 611, when the target base station decides to agree to restore the connection of the terminal, the source base station performs the message authentication code of the terminal according to the freshness parameter, the integrity protection key of the source base station, and the integrity protection algorithm of the source base station. Checking, and when the check is correct, on the one hand, updating the freshness parameter in the context of the terminal of the source base station according to the freshness parameter of the terminal, and updating the key in the context of the terminal of the source base station, on the other hand, The context of the acquired terminal is sent to the target base station.
通过上述步骤601-步骤611的方法,在终端生成消息认证码的输入参数中引入了新鲜性参数,相应地,在源基站校验消息认证码的输入参数中也引入了新鲜性参数。并且,生成消息认证码所使用的完整性保护密钥都是根据更新后的完整性保护密钥生成的。一方面,若目标基站拒绝了终端的连接恢复请求,则目标基站可以通过步骤604通知源基站更新终端的上下文中的新鲜性参数和密钥,从而保持终端与源基站的新鲜性参数和密钥的一致。另一方面,若目标基站同意了终端的连接恢复请求,则目标基站可以通过步骤608请求从源基站获取终端的上下文,同时,源基站还可在此过程中更新源基站的终端上下文中的新鲜性参数和密钥,从而保持终端与源基站的新鲜性参数和密钥的一致。The freshness parameter is introduced in the input parameter of the terminal to generate the message authentication code by the method in the above steps 601-step 611. Correspondingly, the freshness parameter is also introduced in the input parameter of the source base station verification message authentication code. Moreover, the integrity protection key used to generate the message authentication code is generated based on the updated integrity protection key. On the one hand, if the target base station rejects the connection recovery request of the terminal, the target base station may notify the source base station to update the freshness parameter and the key in the context of the terminal by step 604, thereby maintaining the freshness parameter and the key of the terminal and the source base station. Consistent. On the other hand, if the target base station agrees with the connection recovery request of the terminal, the target base station may request to acquire the context of the terminal from the source base station by using step 608, and the source base station may also update the source context of the source base station in the process. Sex parameters and keys, thereby maintaining the consistency of the terminal and the source station's freshness parameters and keys.
通过上述步骤601-步骤611的方法,一方面,可以保持终端和源基站的密钥同步,另一方面,可以有效抵抗攻击者的攻击,因而有助于终端顺利地从不活跃态进入连接态。Through the foregoing steps 601-611, on the one hand, the key synchronization between the terminal and the source base station can be maintained, and on the other hand, the attacker can be effectively resisted, thereby facilitating the terminal to smoothly enter the connected state from the inactive state. .
解决方案四,Solution four,
该解决方案四可用于解决上述步骤301采用方式二生成消息认证码时存在的问题。The solution 4 can be used to solve the problem that the foregoing step 301 adopts the second method to generate the message authentication code.
步骤701、终端生成消息认证码。Step 701: The terminal generates a message authentication code.
该步骤701与上述步骤301的方式二相同,可参考前述描述。This step 701 is the same as the second method of the foregoing step 301, and reference may be made to the foregoing description.
在该步骤701中,终端在生成消息认证码之前,会更新接入层密钥,即由KgNB更新为KgNB*,同时也会更新完整性保护密钥,即由Krrc-int更新为Krrc-int*。然后根据更新后的完整性保护密钥,生成消息认证码。In this step 701, the terminal updates the access layer key before the message authentication code is generated, that is, the KgNB is updated to KgNB*, and the integrity protection key is also updated, that is, updated by Krrc-int to Krrc-int. *. A message authentication code is then generated based on the updated integrity protection key.
步骤702、终端向目标基站发送连接恢复请求消息,目标基站接收来自终端的连接恢复请求消息。Step 702: The terminal sends a connection recovery request message to the target base station, where the target base station receives a connection recovery request message from the terminal.
该步骤702与前述步骤302相同,可参考前述描述。This step 702 is the same as the foregoing step 302, and can be referred to the foregoing description.
步骤703、目标基站判断是否同意终端的恢复请求。Step 703: The target base station determines whether to agree with the recovery request of the terminal.
目标基站基于负载能力,判断是否可以接入该终端。The target base station determines whether the terminal can be accessed based on the load capability.
一种情形是,目标基站的负载比较重,不能接入该终端,则目标基站可以拒绝该终端的恢复请求,即拒绝该终端接入目标基站。此时,则执行步骤704-步骤705。In one case, if the load of the target base station is relatively heavy and cannot access the terminal, the target base station may reject the recovery request of the terminal, that is, reject the terminal from accessing the target base station. At this time, steps 704-705 are performed.
另一种情形是,目标基站的负载不是很重,还可以接入该终端,则目标基站可以同意该终端的恢复请求,即同意该终端接入目标基站。此时,则执行步骤706-步骤709。In another case, the target base station is not heavily loaded and can access the terminal, and the target base station can agree to the terminal's recovery request, that is, the terminal is allowed to access the target base station. At this time, step 706-step 709 is performed.
步骤704、目标基站向终端发送连接恢复拒绝消息,终端接收来自目标基站的连接恢复拒绝消息。Step 704: The target base station sends a connection recovery reject message to the terminal, where the terminal receives a connection recovery reject message from the target base station.
该步骤704与上述步骤304相同,可参考前述描述。This step 704 is the same as step 304 above, and reference may be made to the foregoing description.
步骤705、终端将终端的接入层密钥恢复为更新前的接入层密钥。Step 705: The terminal restores the access layer key of the terminal to the access layer key before the update.
一种实现方式可以是,终端在未接收到拒绝消息前,保存更新前的接入层密钥,例如KgNB。终端在接收到拒绝消息后,终端将更新前的接入层密钥作为当前或存储的接入层密钥。可选地,终端在接收到拒绝消息后,还可以删除更新后的接入层密钥,例如KgNB*。One implementation may be that the terminal saves the access layer key before the update, such as KgNB, before receiving the reject message. After receiving the reject message, the terminal uses the access layer key before the update as the current or stored access layer key. Optionally, after receiving the reject message, the terminal may also delete the updated access layer key, such as KgNB*.
另一种实现方式可以是,终端在未接收到拒绝消息前,保存更新前的安全上下文,更新前的安全上下文包含更新前的接入层密钥,例如KgNB。终端在接收到拒绝消息后,将更新前的安全上下文作为当前或存储的安全上下文。可选地,终端在接收到拒绝消息后,还可以删除更新后的安全上下文。具体地,安全上下文可以是终端的AS安全上下文。Another implementation manner may be that the terminal saves the security context before the update before receiving the reject message, and the security context before the update includes the access layer key before the update, such as KgNB. After receiving the reject message, the terminal uses the pre-update security context as the current or stored security context. Optionally, after receiving the reject message, the terminal may also delete the updated security context. Specifically, the security context may be the AS security context of the terminal.
终端将终端的接入层密钥恢复为更新前的接入层密钥后,会保存更新前的接入层密钥,直到下次恢复连接时,终端再次执行步骤701中的方式二,生成消息认证码。After the terminal restores the access layer key of the terminal to the access layer key before the update, the access layer key before the update is saved, and the terminal performs the second mode in step 701 again after the next connection is restored. Message authentication code.
由于在目标基站拒绝终端的连接恢复请求的场景中,终端已经更新了接入层密钥,为了保持终端与源基站之间的密钥一致,可以采用由终端回退密钥的方式,将终端的接入层密钥恢复为更新前的接入层密钥。因而,也可以达到使得终端与源基站之间始终保持密钥相同的目的,进而也可以有效解决终端与源基站之间的密钥不同步所带来的终端无法恢复连接的问题。In the scenario that the target base station rejects the connection recovery request of the terminal, the terminal has updated the access layer key. In order to keep the key between the terminal and the source base station consistent, the terminal may use the method of backing off the key by the terminal. The access layer key is restored to the access layer key before the update. Therefore, the purpose of maintaining the same key between the terminal and the source base station is also achieved, and the problem that the terminal cannot be restored due to the key synchronization between the terminal and the source base station can be effectively solved.
步骤706、目标基站向源基站发送上下文请求消息,源基站接收来自目标基站的上下文请求消息。Step 706: The target base station sends a context request message to the source base station, where the source base station receives a context request message from the target base station.
上下文请求消息包括终端生成的消息认证码和恢复标识,上下文请求消息用于请求获取终端的上下文。The context request message includes a message authentication code and a recovery identifier generated by the terminal, and the context request message is used to request to acquire the context of the terminal.
该步骤与上述步骤305相同,可参考前述描述。This step is the same as step 305 above, and the foregoing description can be referred to.
步骤707、源基站若校验消息认证码正确,则获取终端的上下文。Step 707: The source base station acquires the context of the terminal if the verification message authentication code is correct.
其中,源基站校验消息认证码的具体方式,可参考上述步骤306中,当终端采用方式二生成消息认证码时,源基站所采用的消息认证码的校验方式。For the specific manner of the source base station verifying the message authentication code, reference may be made to the verification mode of the message authentication code used by the source base station when the terminal uses the mode 2 to generate the message authentication code in the foregoing step 306.
步骤708、源基站若校验消息认证码正确,则向目标基站发送上下文响应消息。Step 708: The source base station sends a context response message to the target base station if the verification message authentication code is correct.
上下文响应消息中可以包括终端的上下文,例如包括源基站的完整性保护算法、源基站的完整性保护密钥。可选地,还包括上述生成的KgNB*。The context response message may include a context of the terminal, for example, an integrity protection algorithm of the source base station, and an integrity protection key of the source base station. Optionally, the generated KgNB* is also included.
步骤709、目标基站向终端发送连接恢复响应消息,终端接收来自目标基站的连接恢复响应消息。Step 709: The target base station sends a connection recovery response message to the terminal, where the terminal receives a connection recovery response message from the target base station.
该连接恢复响应消息用于指示终端恢复RRC连接。可选地,该连接恢复响应消息可由目标基站根据源基站的完整性保护算法和KgNB*生成的完整性保护密钥和加密密钥,分别进行完整性保护和加密。具体实现过程可参考现有技术的相关方案,这里不再赘述。The connection recovery response message is used to instruct the terminal to resume the RRC connection. Optionally, the connection recovery response message may be integrity protected and encrypted by the target base station according to the integrity protection algorithm of the source base station and the integrity protection key and the encryption key generated by the KgNB*. For the specific implementation process, reference may be made to related solutions of the prior art, and details are not described herein again.
在步骤709之后,还包括终端从不活跃态进入连接态的后续流程,为现有技术内容,具体细节可参考相关文献的说明,这里不再赘述。After the step 709, the subsequent process of the terminal from the inactive state to the connected state is further included. For details, refer to the description of related documents, and details are not described herein again.
通过上述步骤701-步骤709所示的请求恢复连接的方法,可以有效解决上述步骤301中采用方式二生成消息认证码时所存在的问题,图7所示的方案中,当目标基站决定拒绝终端的请求连接恢复时,目标基站还通过步骤704,向终端发送连接恢复拒绝消息,终端通过步骤705,将终端的接入层密钥恢复为更新前的接入层密钥,从而使得终端与源基站之间始终保持密钥相同,因而可以有效解决终端与源基站之间的密 钥不同步所带来的终端无法恢复连接的问题。The method for restoring the connection as shown in the foregoing steps 701 to 709 can effectively solve the problem that occurs when the message authentication code is generated by the second method in the foregoing step 301. In the solution shown in FIG. 7, when the target base station decides to reject the terminal, When the request connection is restored, the target base station sends a connection recovery reject message to the terminal through step 704, and the terminal restores the access layer key of the terminal to the access layer key before the update by step 705, thereby causing the terminal and the source. The keys are always the same between the base stations, so that the problem that the terminal cannot be restored due to the key synchronization between the terminal and the source base station can be effectively solved.
需要说明的是,上述实施例中的连接恢复请求消息、连接恢复响应消息、连接恢复完成消息、上下文请求消息、上下文响应消息等仅是一个名字,名字对消息本身不构成限定。在5G网络以及未来其它的网络中,连接恢复请求消息、连接恢复响应消息、连接恢复完成消息、上下文请求消息、上下文响应消息也可以是其他的名字,本申请实施例对此不作具体限定。例如,连接恢复请求消息还有可能被替换为请求消息、恢复请求消息、连接请求消息等,该连接恢复响应消息还有可能被替换为响应消息、恢复响应消息、连接响应消息等,该连接恢复完成消息还有可能被替换为完成消息、恢复完成消息、连接完成消息等,该上下文请求消息还有可能被替换为请求消息等,该上下文响应消息还有可能被替换为响应消息等。It should be noted that the connection recovery request message, the connection recovery response message, the connection recovery completion message, the context request message, the context response message, and the like in the foregoing embodiment are only one name, and the name does not limit the message itself. In the 5G network and other networks in the future, the connection recovery request message, the connection recovery response message, the connection recovery completion message, the context request message, and the context response message may be other names, which are not specifically limited in the embodiment of the present application. For example, the connection recovery request message may also be replaced with a request message, a recovery request message, a connection request message, etc., and the connection recovery response message may be replaced with a response message, a recovery response message, a connection response message, etc., and the connection is restored. The completion message may also be replaced with a completion message, a recovery completion message, a connection completion message, etc., and the context request message may also be replaced with a request message or the like, and the context response message may also be replaced with a response message or the like.
上述主要从各个网元之间交互的角度对本申请提供的方案进行了介绍。可以理解的是,上述实现各网元为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,本发明能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本发明的范围。The foregoing provides a description of the solution provided by the present application from the perspective of interaction between the various network elements. It can be understood that, in order to implement the above functions, each of the foregoing network elements includes a hardware structure and/or a software module corresponding to each function. Those skilled in the art will readily appreciate that the present invention can be implemented in a combination of hardware or hardware and computer software in combination with the elements and algorithm steps of the various examples described in the embodiments disclosed herein. Whether a function is implemented in hardware or computer software to drive hardware depends on the specific application and design constraints of the solution. A person skilled in the art can use different methods for implementing the described functions for each particular application, but such implementation should not be considered to be beyond the scope of the present invention.
基于相同的发明构思,如图8所示,为本申请提供的一种装置示意图,该装置可以是终端、目标基站或源基站,可执行上述任一实施例中由终端、目标基站或源基站执行的方法。Based on the same inventive concept, as shown in FIG. 8 , a schematic diagram of a device provided by the present application, which may be a terminal, a target base station, or a source base station, may be implemented by the terminal, the target base station, or the source base station in any of the foregoing embodiments. The method of execution.
该装置800包括至少一个处理器801,发送器802,接收器803,可选地,还包括存储器804。所述处理器801,发送器802,接收器803,存储器804通过通信线路连接。The apparatus 800 includes at least one processor 801, a transmitter 802, a receiver 803, and optionally a memory 804. The processor 801, the transmitter 802, the receiver 803, and the memory 804 are connected by a communication line.
处理器801可以是一个通用中央处理器(CPU),微处理器,特定应用集成电路(application-specific integrated circuit,ASIC),或一个或多个用于控制本发明方案程序执行的集成电路。 Processor 801 can be a general purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of the program of the present invention.
通信线路可包括一通路,在上述单元之间传送信息。The communication line can include a path for communicating information between the units.
所述发送器802和接收器803,用于与其他设备或通信网络通信。发送器和接收器包括射频电路。The transmitter 802 and the receiver 803 are configured to communicate with other devices or communication networks. The transmitter and receiver include radio frequency circuits.
存储器804可以是只读存储器(read-only memory,ROM)或可存储静态信息和指令的其他类型的静态存储设备,随机存取存储器(random access memory,RAM)或者可存储信息和指令的其他类型的动态存储设备,也可以是电可擦可编程只读存储器(Electrically erasable programmabler-only memory,EEPROM)、只读光盘(compact disc read-only memory,CD-ROM)或其他光盘存储、光碟存储(包括压缩光碟、激光碟、光碟、数字通用光碟、蓝光光碟等)、磁盘存储介质或者其他磁存储设备、或者能够用于携带或存储具有指令或数据结构形式的期望的程序代码并能够由计算机存取的任何其他介质,但不限于此。存储器804可以是独立存在,通过通信线路与处理器801相连接。存储器804也可以和处理器集成在一起。其中,所述存储器804用于存储执行本发明方案的应用程序代码,并由处理器801来控制执行。所述处理器801用于执 行存储器804中存储的应用程序代码。The memory 804 can be a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a random access memory (RAM) or other type that can store information and instructions. The dynamic storage device may also be an electrically erasable programmabler-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, or a disc storage ( Including compressed optical discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or can be used to carry or store desired program code in the form of instructions or data structures and can be stored by a computer Any other media taken, but not limited to this. The memory 804 may be independent and connected to the processor 801 via a communication line. Memory 804 can also be integrated with the processor. The memory 804 is used to store application code for executing the solution of the present invention, and is controlled by the processor 801 for execution. The processor 801 is configured to execute application code stored in the memory 804.
在具体实现中,作为一种实施例,处理器801可以包括一个或多个CPU,例如图8中的CPU0和CPU1。In a specific implementation, as an embodiment, the processor 801 may include one or more CPUs, such as CPU0 and CPU1 in FIG.
在具体实现中,作为一种实施例,装置800可以包括多个处理器,例如图8中的处理器801和处理器808。这些处理器中的每一个可以是一个单核(single-CPU)处理器,也可以是一个多核(multi-CPU)处理器,这里的处理器可以指一个或多个设备、电路、和/或用于处理数据(例如计算机程序指令)的处理核。In a particular implementation, as an embodiment, apparatus 800 can include multiple processors, such as processor 801 and processor 808 in FIG. Each of these processors may be a single-CPU processor or a multi-core processor, where the processor may refer to one or more devices, circuits, and/or A processing core for processing data, such as computer program instructions.
应理解,当该装置800是终端时,该装置800可以用于实现本发明实施例的方法中由终端执行的步骤,例如,装置800可以执行图3中的步骤301、步骤302、步骤304和步骤308,还可以执行图4中的步骤401、步骤402、步骤407和步骤411,还可以执行图5中的步骤501、步骤502、步骤507和步骤511,还可以执行图6中的步骤601、步骤602、步骤607和步骤611,还可以执行图7中的步骤701、步骤702、步骤704和步骤709。相关特征可以参照上文,此处不再赘述。It should be understood that when the device 800 is a terminal, the device 800 can be used to implement the steps performed by the terminal in the method of the embodiment of the present invention. For example, the device 800 can perform step 301, step 302, step 304 in FIG. 3 and Step 308, step 401, step 402, step 407, and step 411 in FIG. 4 may also be performed. Step 501, step 502, step 507, and step 511 in FIG. 5 may also be performed, and step 601 in FIG. 6 may also be performed. Step 602, step 607, and step 611, step 701, step 702, step 704, and step 709 in FIG. 7 can also be performed. Related features can be referred to above, and will not be described again here.
当该装置800是目标基站时,该装置800可以用于实现本发明实施例的方法中由目标基站执行的步骤,例如,装置800可以执行图3中的步骤302、步骤303、步骤304、步骤305、步骤307和步骤308,还可以执行图4中的步骤402、步骤403、步骤404、步骤406步骤407、步骤408、步骤410和步骤411,还可以执行图5中的步骤502、步骤503、步骤504、步骤506、步骤507、步骤508、步骤510和步骤511,还可以执行图6中的步骤602、步骤603、步骤604、步骤606、步骤607、步骤608、步骤610和步骤611,还可以执行图7中的步骤702、步骤703、步骤704、步骤706、步骤708和步骤709。相关特征可以参照上文,此处不再赘述。When the device 800 is a target base station, the device 800 can be used to implement the steps performed by the target base station in the method of the embodiment of the present invention. For example, the device 800 can perform step 302, step 303, step 304, and step in FIG. 305, step 307 and step 308, step 402, step 403, step 404, step 406, step 407, step 408, step 410 and step 411 in FIG. 4 may also be performed, and step 502 and step 503 in FIG. 5 may also be performed. Step 504, step 506, step 507, step 508, step 510, and step 511, step 602, step 603, step 604, step 606, step 607, step 608, step 610, and step 611 in FIG. 6 may also be performed. Step 702, step 703, step 704, step 706, step 708, and step 709 in FIG. 7 can also be performed. Related features can be referred to above, and will not be described again here.
当该装置800是源基站时,该装置800可以用于实现本发明实施例的方法中由源基站执行的步骤,例如,装置800可以执行图3中的步骤步骤305、步骤306和步骤307,还可以执行图4中的步骤404、步骤405、步骤406、步骤408、步骤409和步骤410,还可以执行图5中的步骤504、步骤505、步骤506、步骤508、步骤509和步骤510,,还可以执行图6中的步骤604、步骤605、步骤606、步骤608、步骤609和步骤610,还可以还行图7中的步骤706、步骤707和步骤708,相关特征可以参照上文,此处不再赘述。When the device 800 is a source base station, the device 800 can be used to implement the steps performed by the source base station in the method of the embodiment of the present invention. For example, the device 800 can perform step 305, step 306, and step 307 in FIG. 3, Step 404, step 405, step 406, step 408, step 409, and step 410 in FIG. 4 may also be performed, and step 504, step 505, step 506, step 508, step 509, and step 510 in FIG. 5 may also be performed. Step 604, step 605, step 606, step 608, step 609, and step 610 in FIG. 6 may also be performed, and step 706, step 707, and step 708 in FIG. 7 may also be performed, and related features may be referred to above. I will not repeat them here.
本申请可以根据上述方法示例对终端进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本申请中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。比如,在采用对应各个功能划分各个功能模块的情况下,图9示出了一种装置示意图,该装置900可以是上述实施例中所涉及的终端,该装置900包括处理单元901和发送单元903。可选地,还包括接收单元902。The application may divide the function module into the terminal according to the above method example. For example, each function module may be divided according to each function, or two or more functions may be integrated into one processing module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the present application is schematic, and is only a logical function division, and may be further divided in actual implementation. For example, in the case of dividing each functional module by corresponding functions, FIG. 9 shows a schematic diagram of a device, which may be the terminal involved in the above embodiment, and the device 900 includes a processing unit 901 and a transmitting unit 903. . Optionally, a receiving unit 902 is further included.
在一种请求恢复连接的方法的实现中:In an implementation of a method of requesting a restore connection:
所述处理单元901,用于根据新鲜性参数和所述装置的完整性保护密钥,生成消息认证码,其中,相邻两次生成消息认证码所使用的新鲜性参数不同;The processing unit 901 is configured to generate a message authentication code according to the freshness parameter and the integrity protection key of the device, where the freshness parameter used in generating the message authentication code twice is different;
所述发送单元903,用于向目标基站发送连接恢复请求消息,所述连接恢复请求消息包括所述消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连 接。The sending unit 903 is configured to send a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, and the connection recovery request message is used to request to resume the radio resource control RRC connection.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述装置尝试恢复所述RRC连接时被拒绝的次数。In a possible implementation manner, the freshness parameter includes a number of rejections, the number of rejections being used to indicate the number of times the device is rejected when attempting to resume the RRC connection.
在一种可能的实现方式中,所述接收单元902,用于接收来自所述目标基站的连接恢复响应消息,所述连接恢复响应消息用于指示所述终端恢复所述RRC连接。In a possible implementation, the receiving unit 902 is configured to receive a connection recovery response message from the target base station, where the connection recovery response message is used to instruct the terminal to resume the RRC connection.
在一种可能的实现方式中,所述连接恢复请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数。In a possible implementation manner, the connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
在一种可能的实现方式中,所述新鲜性参数包括分组数据汇聚协议计数PDCPCOUNT,所述指示参数包括所述PDCP COUNT的部分或全部比特位。In a possible implementation manner, the freshness parameter includes a packet data convergence protocol count PDCPCOUNT, and the indication parameter includes part or all of the bits of the PDCP COUNT.
应理解,该终端可以用于实现本发明实施例的方法中由终端执行的步骤,相关特征可以参照上文,此处不再赘述。It should be understood that the terminal may be used to implement the steps performed by the terminal in the method of the embodiment of the present invention. For related features, reference may be made to the above, and details are not described herein again.
本申请可以根据上述方法示例对目标基站进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本申请中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。比如,在采用对应各个功能划分各个功能模块的情况下,图10示出了一种装置示意图,该装置1000可以是上述实施例中所涉及的目标基站,该装置1000包括接收单元1001和发送单元1002。The application may perform the division of the function modules on the target base station according to the foregoing method example. For example, each function module may be divided according to each function, or two or more functions may be integrated into one processing module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the present application is schematic, and is only a logical function division, and may be further divided in actual implementation. For example, in the case of dividing each functional module by corresponding functions, FIG. 10 shows a schematic diagram of a device, which may be the target base station involved in the above embodiment, and the device 1000 includes a receiving unit 1001 and a transmitting unit. 1002.
在一种请求恢复连接的方法的实现中:In an implementation of a method of requesting a restore connection:
所述接收单元1001,用于接收来自终端的连接恢复请求消息,所述连接恢复请求消息包括消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接,所述消息认证码是根据所述终端的完整性保护密钥生成的;The receiving unit 1001 is configured to receive a connection recovery request message from a terminal, where the connection recovery request message includes a message authentication code, where the connection recovery request message is used to request to restore a radio resource control RRC connection, where the message authentication code is Generating according to the integrity protection key of the terminal;
所述发送单元1002,用于若拒绝恢复所述RRC连接,则向源基站发送通知消息,所述通知消息包括所述消息认证码。The sending unit 1002 is configured to: if the RRC connection is refused to be restored, send a notification message to the source base station, where the notification message includes the message authentication code.
其中,通知消息具有以下功能中的一个或多个:Wherein, the notification message has one or more of the following functions:
通知消息用于通知更新源基站中的终端的上下文;The notification message is used to notify the update of the context of the terminal in the source base station;
通知消息用于通知目标基站将拒绝终端恢复连接;The notification message is used to notify the target base station that the terminal is refused to resume the connection;
通知消息用于通知更新源基站中的终端的上下文的新鲜性参数;The notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
通知消息用于通知更新源基站中的终端的上下文的密钥。The notification message is used to notify the key of the context of the terminal in the update source base station.
在一种可能的实现方式中,所述通知消息通知更新的所述终端的上下文包括接入层密钥。In a possible implementation manner, the notification message notifies that the updated context of the terminal includes an access layer key.
在一种可能的实现方式中,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,所述通知消息通知更新的所述终端的上下文包括所述新鲜性参数,其中,相邻两次生成消息认证码所使用的新鲜性参数不同。In a possible implementation manner, the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where the notification message notifies that the updated context of the terminal includes the freshness parameter Wherein, the freshness parameters used to generate the message authentication code two times are different.
在一种可能的实现方式中,所述连接恢复请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数,所述通知消息还包括所述指示参数。In a possible implementation manner, the connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, and the notification message further includes the indication parameter.
在一种可能的实现方式中,所述新鲜性参数包括PDCP COUNT,所述指示参数包括所述PDCP COUNT的部分或全部比特位。In a possible implementation manner, the freshness parameter includes a PDCP COUNT, and the indication parameter includes part or all of the bits of the PDCP COUNT.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表 示所述装置尝试恢复所述RRC连接时被拒绝的次数。In a possible implementation, the freshness parameter includes a number of rejections, the number of rejections being used to indicate the number of times the device is rejected when attempting to resume the RRC connection.
在另一种请求恢复连接的方法的实现中:In another implementation of a method that requests a restore connection:
所述接收单元1001,用于接收来自终端的连接恢复请求消息,所述连接恢复请求消息包括消息认证码,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;The receiving unit 1001 is configured to receive a connection recovery request message from a terminal, where the connection recovery request message includes a message authentication code, where the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal. The freshness parameter used in generating the message authentication code twice is different, and the connection recovery request message is used to request to resume the radio resource control RRC connection;
所述发送单元1002,用于若恢复所述RRC连接,则向源基站发送上下文请求消息,所述上下文请求消息包括所述消息认证码,所述上下文请求消息用于请求获取所述终端的上下文。The sending unit 1002 is configured to: if the RRC connection is restored, send a context request message to the source base station, where the context request message includes the message authentication code, where the context request message is used to request to acquire the context of the terminal. .
在一种可能的实现方式中,所述连接恢复请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数,所述上下文请求消息还包括所述指示参数。In a possible implementation manner, the connection recovery request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, and the context request message further includes the indication parameter.
在一种可能的实现方式中,所述新鲜性参数包括分组数据汇聚协议PDCP计数COUNT,所述指示参数包括所述PDCP COUNT的部分或全部比特位。In a possible implementation manner, the freshness parameter includes a packet data convergence protocol PDCP count COUNT, and the indication parameter includes part or all of the bits of the PDCP COUNT.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述装置尝试恢复所述RRC连接时被拒绝的次数。In a possible implementation manner, the freshness parameter includes a number of rejections, the number of rejections being used to indicate the number of times the device is rejected when attempting to resume the RRC connection.
应理解,该目标基站可以用于实现本发明实施例的方法中由目标基站执行的步骤,相关特征可以参照上文,此处不再赘述。It should be understood that the target base station may be used to implement the steps performed by the target base station in the method of the embodiment of the present invention. For related features, reference may be made to the above, and details are not described herein again.
本申请可以根据上述方法示例对源基站进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本申请中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。比如,在采用对应各个功能划分各个功能模块的情况下,图11示出了一种装置示意图,该装置1100可以是上述实施例中所涉及的源基站,该装置1100包括处理单元1101、接收单元1102和发送单元1103。The application may divide the function modules of the source base station according to the foregoing method example. For example, each function module may be divided according to each function, or two or more functions may be integrated into one processing module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the present application is schematic, and is only a logical function division, and may be further divided in actual implementation. For example, in the case of dividing each functional module by corresponding functions, FIG. 11 shows a schematic diagram of a device, which may be the source base station involved in the above embodiment, and the device 1100 includes a processing unit 1101 and a receiving unit. 1102 and a transmitting unit 1103.
在一种请求恢复连接的方法的实现中:In an implementation of a method of requesting a restore connection:
所述接收单元1102,用于接收来自目标基站的通知消息,所述通知消息包括消息认证码所述消息认证码是根据所述终端的完整性保护密钥生成的;The receiving unit 1102 is configured to receive a notification message from a target base station, where the notification message includes a message authentication code, where the message authentication code is generated according to an integrity protection key of the terminal;
所述处理单元1101,用于根据所述源基站的完整性保护密钥,校验所述消息认证码;以及,用于若校验所述消息认证码正确,则更新所述源基站中的所述终端的上下文。The processing unit 1101 is configured to check the message authentication code according to the integrity protection key of the source base station, and to update the source base station if the message authentication code is correct The context of the terminal.
其中,通知消息具有以下功能中的一个或多个:Wherein, the notification message has one or more of the following functions:
通知消息用于通知更新源基站中的终端的上下文;The notification message is used to notify the update of the context of the terminal in the source base station;
通知消息用于通知目标基站将拒绝终端恢复连接;The notification message is used to notify the target base station that the terminal is refused to resume the connection;
通知消息用于通知更新源基站中的终端的上下文的新鲜性参数;The notification message is used to notify the update of the freshness parameter of the context of the terminal in the source base station;
通知消息用于通知更新源基站中的终端的上下文的密钥。The notification message is used to notify the key of the context of the terminal in the update source base station.
在一种可能的实现方式中,所述处理单元1101,具体用于更新所述源基站中的所述终端的上下文中的接入层密钥。In a possible implementation manner, the processing unit 1101 is specifically configured to update an access layer key in a context of the terminal in the source base station.
在一种可能的实现方式中,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同;In a possible implementation manner, the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where a freshness parameter used by generating a message authentication code twice is different;
所述处理单元1101,具体用于根据所述新鲜性参数和所述源基站的完整性保护密钥,校验所述消息认证码。The processing unit 1101 is specifically configured to check the message authentication code according to the freshness parameter and an integrity protection key of the source base station.
在一种可能的实现方式中,所述通知消息还包括指示参数,所述指示参数用于指示所述新鲜性参数。In a possible implementation manner, the notification message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter.
在一种可能的实现方式中,所述新鲜性参数包括分组数据汇聚协议计数PDCP COUNT,所述处理单元1101,用于更新所述源基站中的所述终端的上下文,具体包括:In a possible implementation, the freshness parameter includes a packet data convergence protocol, which is a PDCP COUNT, and the processing unit 1101 is configured to update a context of the terminal in the source base station, and specifically includes:
若所述PDCP COUNT的数值大于所述终端的上下文中的PDCP COUNT的数值,则将所述终端的上下文中的PDCP COUNT的数值更新为所述指示参数指示的PDCP COUNT的数值。If the value of the PDCP COUNT is greater than the value of the PDCP COUNT in the context of the terminal, the value of the PDCP COUNT in the context of the terminal is updated to the value of the PDCP COUNT indicated by the indication parameter.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述装置尝试恢复所述RRC连接时被拒绝的次数。In a possible implementation manner, the freshness parameter includes a number of rejections, the number of rejections being used to indicate the number of times the device is rejected when attempting to resume the RRC connection.
在一种可能的实现方式中,所述处理单元1101,具体用于将所述终端的上下文的拒绝次数加1。In a possible implementation, the processing unit 1101 is specifically configured to increase the number of rejections of the context of the terminal by one.
在另一种请求恢复连接的方法的实现中:In another implementation of a method that requests a restore connection:
所述接收单元1102,用于接收来自目标基站的上下文请求消息,所述上下文请求消息包括消息认证码,所述消息认证码是根据所述新鲜性参数和所述终端的完整性保护密钥生成的,其中,邻两次生成消息认证码所使用的新鲜性参数不同,所述上下文请求消息用于请求获取所述终端的上下文;The receiving unit 1102 is configured to receive a context request message from a target base station, where the context request message includes a message authentication code, where the message authentication code is generated according to the freshness parameter and an integrity protection key of the terminal. The freshness parameter used by the neighboring two generation message authentication codes is different, and the context request message is used to request to acquire the context of the terminal;
所述处理单元1101,用于根据所述新鲜性参数和所述源基站的完整性保护密钥,校验所述消息认证码;以及,用于若校验所述消息认证码正确,则更新所述终端的上下文中的新鲜性参数;The processing unit 1101 is configured to check the message authentication code according to the freshness parameter and the integrity protection key of the source base station; and, if used to verify that the message authentication code is correct, update Freshness parameters in the context of the terminal;
所述发送单元1103,用于向所述目标基站发送上下文响应消息,所述上下文响应消息包括所述终端的上下文。The sending unit 1103 is configured to send a context response message to the target base station, where the context response message includes a context of the terminal.
在一种可能的实现方式中,所述上下文请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数,所述新鲜性参数包括PDCP COUNT;所述处理单元1101根据更新所述源基站中的所述终端的上下文,具体包括:In a possible implementation manner, the context request message further includes an indication parameter, where the indication parameter is used to indicate the freshness parameter, and the freshness parameter includes a PDCP COUNT; the processing unit 1101 is configured according to the update. The context of the terminal in the source base station specifically includes:
若所述PDCP COUNT的数值大于所述终端的上下文中的PDCP COUNT的数值,则将所述终端的上下文中的PDCP COUNT的数值更新为所述指示参数指示的PDCP COUNT的数值。If the value of the PDCP COUNT is greater than the value of the PDCP COUNT in the context of the terminal, the value of the PDCP COUNT in the context of the terminal is updated to the value of the PDCP COUNT indicated by the indication parameter.
在一种可能的实现方式中,所述指示参数包括所述PDCP COUNT的部分比特位;所述处理单元1101还用于:根据所述指示参数,确定所述指示参数指示的所述PDCP COUNT。In a possible implementation, the indication parameter includes a partial bit of the PDCP COUNT; the processing unit 1101 is further configured to: determine, according to the indication parameter, the PDCP COUNT indicated by the indication parameter.
在一种可能的实现方式中,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述装置尝试恢复所述RRC连接时被拒绝的次数;所述处理单元1101,用于根据更新所述源基站中的所述终端的上下文,包括:将所述终端的上下文中的拒绝次数重置为零。In a possible implementation manner, the freshness parameter includes a number of rejections, the number of rejections is used to indicate a number of times the device attempts to recover the RRC connection, and the processing unit 1101 is configured to update according to the update. The context of the terminal in the source base station includes: resetting the number of rejections in the context of the terminal to zero.
应理解,该源基站可以用于实现本发明实施例的方法中由源基站执行的步骤,相关特征可以参照上文,此处不再赘述。It should be understood that the source base station may be used to implement the steps performed by the source base station in the method of the embodiment of the present invention. For related features, reference may be made to the above, and details are not described herein again.
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实 现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。所述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行所述计算机程序指令时,全部或部分地产生按照本发明实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。所述计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。所述计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。所述可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如固态硬盘(Solid State Disk,SSD))等。In the above embodiments, it may be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented in software, it may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in accordance with embodiments of the present invention are generated in whole or in part. The computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer readable storage medium or transferred from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions can be from a website site, computer, server or data center Transfer to another website site, computer, server, or data center by wire (eg, coaxial cable, fiber optic, digital subscriber line (DSL), or wireless (eg, infrared, wireless, microwave, etc.). The computer readable storage medium can be any available media that can be accessed by a computer or a data storage device such as a server, data center, or the like that includes one or more available media. The usable medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a DVD), or a semiconductor medium (such as a Solid State Disk (SSD)) or the like.
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。所述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行所述计算机程序指令时,全部或部分地产生按照本发明实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。所述计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。所述计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。所述可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如固态硬盘(Solid State Disk,SSD))等。In the above embodiments, it may be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented in software, it may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in accordance with embodiments of the present invention are generated in whole or in part. The computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer readable storage medium or transferred from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions can be from a website site, computer, server or data center Transfer to another website site, computer, server, or data center by wire (eg, coaxial cable, fiber optic, digital subscriber line (DSL), or wireless (eg, infrared, wireless, microwave, etc.). The computer readable storage medium can be any available media that can be accessed by a computer or a data storage device such as a server, data center, or the like that includes one or more available media. The usable medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a DVD), or a semiconductor medium (such as a Solid State Disk (SSD)) or the like.
尽管在此结合各实施例对本发明进行了描述,然而,在实施所要求保护的本发明过程中,本领域技术人员通过查看所述附图、公开内容、以及所附权利要求书,可理解并实现所述公开实施例的其他变化。在权利要求中,“包括”(comprising)一词不排除其他组成部分或步骤,“一”或“一个”不排除多个的情况。单个处理器或其他单元可以实现权利要求中列举的若干项功能。相互不同的从属权利要求中记载了某些措施,但这并不表示这些措施不能组合起来产生良好的效果。Although the present invention has been described herein in connection with the embodiments of the present invention, it will be understood by those skilled in the <RTIgt; Other variations of the disclosed embodiments are achieved. In the claims, the word "comprising" does not exclude other components or steps, and "a" or "an" does not exclude a plurality. A single processor or other unit may fulfill several of the functions recited in the claims. Certain measures are recited in mutually different dependent claims, but this does not mean that the measures are not combined to produce a good effect.
本领域技术人员应明白,本申请的实施例可提供为方法、装置(设备)、计算机可读存储介质或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式,这里将它们都统称为“模块”或“系统”。Those skilled in the art will appreciate that embodiments of the present application can be provided as a method, apparatus (device), computer readable storage medium, or computer program product. Thus, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or a combination of software and hardware aspects, which are collectively referred to herein as "module" or "system."
本领域技术人员还可以了解到本申请实施例列出的各种说明性逻辑块(illustrative logical block)和步骤(step)可以通过电子硬件、电脑软件,或两者的结合进行实现。这样的功能是通过硬件还是软件来实现取决于特定的应用和整个系统的设计要求。本领域技术人员可以对于每种特定的应用,可以使用各种方法实现所述的功能,但这种实现不应被理解为超出本申请实施例保护的范围。Those skilled in the art can also understand that the various illustrative logical blocks and steps listed in the embodiments of the present application can be implemented by electronic hardware, computer software, or a combination of the two. Whether such functionality is implemented by hardware or software depends on the design requirements of the particular application and the overall system. Those skilled in the art can implement the described functions using various methods for each specific application, but such implementation should not be construed as being beyond the scope of the embodiments of the present application.
尽管结合具体特征及其实施例对本发明进行了描述,显而易见的,在不脱离本发明的精神和范围的情况下,可对其进行各种修改和组合。相应地,本说明书和附图仅仅是所附权利要求所界定的本发明的示例性说明,且视为已覆盖本发明范围内的任意和所有修改、变化、组合或等同物。显然,本领域的技术人员可以对本发明进行各种改动和变型而不脱离本发明的精神和范围。这样,倘若本发明的这些修改和变型属于本发明权利要求及其等同技术的范围之内,则本发明也意图包含这些改动和变型在内。While the invention has been described with respect to the specific embodiments and embodiments thereof, various modifications and combinations may be made without departing from the spirit and scope of the invention. Accordingly, the specification and drawings are to be construed as the It is apparent that those skilled in the art can make various modifications and variations to the invention without departing from the spirit and scope of the invention. Thus, it is intended that the present invention cover the modifications and modifications of the invention

Claims (43)

  1. 一种请求恢复连接的方法,其特征在于,包括:A method for requesting a connection to restore, characterized in that it comprises:
    终端根据新鲜性参数和所述终端的完整性保护密钥,生成消息认证码,其中,相邻两次生成消息认证码所使用的新鲜性参数不同;The terminal generates a message authentication code according to the freshness parameter and the integrity protection key of the terminal, where the freshness parameter used in generating the message authentication code twice is different;
    所述终端向目标基站发送连接恢复请求消息,所述连接恢复请求消息包括所述消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接。The terminal sends a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, and the connection recovery request message is used to request to resume the radio resource control RRC connection.
  2. 根据权利要求1所述的方法,其特征在于,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述终端尝试恢复所述RRC连接时被拒绝的次数。The method of claim 1, wherein the freshness parameter comprises a number of rejections, the number of rejections being used to indicate a number of times the terminal is rejected when attempting to resume the RRC connection.
  3. 根据权利要求1所述的方法,其特征在于,所述连接恢复请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数。The method of claim 1, wherein the connection recovery request message further comprises an indication parameter, the indication parameter being used to indicate the freshness parameter.
  4. 根据权利要求3所述的方法,其特征在于,所述新鲜性参数包括分组数据汇聚协议计数PDCP COUNT,所述指示参数包括所述PDCP COUNT的部分或全部比特位。The method of claim 3, wherein the freshness parameter comprises a packet data convergence protocol count PDCP COUNT, the indication parameter comprising part or all of the bits of the PDCP COUNT.
  5. 一种请求恢复连接的方法,其特征在于,包括:A method for requesting a connection to restore, characterized in that it comprises:
    目标基站接收来自终端的连接恢复请求消息,所述连接恢复请求消息包括消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接,所述消息认证码是根据所述终端的完整性保护密钥生成的;The target base station receives a connection recovery request message from the terminal, where the connection recovery request message includes a message authentication code, and the connection recovery request message is used to request to restore the radio resource control RRC connection, where the message authentication code is complete according to the terminal Sexual protection key generation;
    所述目标基站若拒绝恢复所述RRC连接,则向源基站发送通知消息,所述通知消息包括所述消息认证码。And if the target base station refuses to restore the RRC connection, sending a notification message to the source base station, where the notification message includes the message authentication code.
  6. 根据权利要求5所述的方法,其特征在于,所述通知消息用于通知更新所述源基站中的所述终端的上下文,所述通知消息通知更新的所述终端的上下文包括接入层密钥。The method according to claim 5, wherein the notification message is used to notify update of a context of the terminal in the source base station, and the notification message notifies that the updated context of the terminal includes an access layer dense key.
  7. 根据权利要求5或6所述的方法,其特征在于,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,所述通知消息用于通知更新所述源基站中的所述终端的上下文,所述通知消息通知更新的所述终端的上下文包括所述新鲜性参数,其中,相邻两次生成消息认证码所使用的新鲜性参数不同。The method according to claim 5 or 6, wherein the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, and the notification message is used to notify the update of the source base station. The context of the terminal in the notification message notifying that the updated context of the terminal includes the freshness parameter, wherein the freshness parameter used by the two adjacent generation message authentication codes is different.
  8. 一种请求恢复连接的方法,其特征在于,包括:A method for requesting a connection to restore, characterized in that it comprises:
    目标基站接收来自终端的连接恢复请求消息,所述连接恢复请求消息包括消息认证码,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;The target base station receives a connection recovery request message from the terminal, where the connection recovery request message includes a message authentication code, and the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where two adjacent The freshness parameter used by the secondary generation message authentication code is different, and the connection recovery request message is used to request to restore the radio resource control RRC connection;
    所述目标基站若恢复所述RRC连接,则向源基站发送上下文请求消息,所述上下文请求消息包括所述消息认证码,所述上下文请求消息用于请求获取所述终端的上下文。And if the target base station restores the RRC connection, sending a context request message to the source base station, where the context request message includes the message authentication code, where the context request message is used to request to acquire a context of the terminal.
  9. 一种请求恢复连接的方法,其特征在于,包括:A method for requesting a connection to restore, characterized in that it comprises:
    源基站接收来自目标基站的通知消息,所述通知消息包括消息认证码,所述消息认证码是根据所述终端的完整性保护密钥生成的;The source base station receives a notification message from the target base station, where the notification message includes a message authentication code, and the message authentication code is generated according to the integrity protection key of the terminal;
    所述源基站根据所述源基站的完整性保护密钥,校验所述消息认证码;The source base station verifies the message authentication code according to the integrity protection key of the source base station;
    所述源基站若校验所述消息认证码正确,则更新所述源基站中的所述终端的上下 文。And if the source base station verifies that the message authentication code is correct, updating the context of the terminal in the source base station.
  10. 根据权利要求9所述的方法,其特征在于,所述源基站更新所述源基站中的所述终端的上下文,包括:The method according to claim 9, wherein the source base station updates a context of the terminal in the source base station, including:
    所述源基站更新所述终端的上下文中的接入层密钥。The source base station updates an access stratum key in the context of the terminal.
  11. 根据权利要求9所述的方法,其特征在于,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同;The method according to claim 9, wherein the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, wherein the message used by the message authentication code is generated twice adjacently Different sex parameters;
    所述源基站根据所述源基站的完整性保护密钥,校验所述消息认证码,包括:The source base station verifies the message authentication code according to the integrity protection key of the source base station, and includes:
    所述源基站根据所述新鲜性参数和所述源基站的完整性保护密钥,校验所述消息认证码。The source base station verifies the message authentication code according to the freshness parameter and the integrity protection key of the source base station.
  12. 根据权利要求11所述的方法,其特征在于,所述通知消息还包括指示参数,所述指示参数用于指示所述新鲜性参数。The method according to claim 11, wherein the notification message further comprises an indication parameter, the indication parameter being used to indicate the freshness parameter.
  13. 根据权利要求12所述的方法,其特征在于,所述新鲜性参数包括分组数据汇聚协议计数PDCP COUNT,所述源基站更新所述源基站中的所述终端的上下文,包括:The method according to claim 12, wherein the freshness parameter comprises a packet data convergence protocol count PDCP COUNT, and the source base station updates a context of the terminal in the source base station, including:
    若所述PDCP COUNT的数值大于所述终端的上下文中的PDCP COUNT的数值,则所述源基站将所述终端的上下文中的PDCP COUNT的数值更新为所述指示参数指示的PDCP COUNT的数值。If the value of the PDCP COUNT is greater than the value of the PDCP COUNT in the context of the terminal, the source base station updates the value of the PDCP COUNT in the context of the terminal to the value of the PDCP COUNT indicated by the indication parameter.
  14. 根据权利要求11所述的方法,其特征在于,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述终端尝试恢复所述RRC连接时被拒绝的次数。The method of claim 11 wherein said freshness parameter comprises a number of rejections, said number of rejections being used to indicate a number of times said terminal is rejected when attempting to resume said RRC connection.
  15. 一种请求恢复连接的方法,其特征在于,包括:A method for requesting a connection to restore, characterized in that it comprises:
    源基站接收来自目标基站的上下文请求消息,所述上下文请求消息包括消息认证码,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同,所述上下文请求消息用于请求获取所述终端的上下文;The source base station receives a context request message from the target base station, where the context request message includes a message authentication code, and the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, where The freshness parameter used to generate the message authentication code is different, and the context request message is used to request to acquire the context of the terminal;
    所述源基站根据所述新鲜性参数和所述源基站的完整性保护密钥,校验所述消息认证码;The source base station verifies the message authentication code according to the freshness parameter and the integrity protection key of the source base station;
    所述源基站若校验所述消息认证码正确,则更新所述终端的上下文中的新鲜性参数,以及向所述目标基站发送上下文响应消息,所述上下文响应消息包括所述终端的上下文。And if the source base station verifies that the message authentication code is correct, updating a freshness parameter in a context of the terminal, and sending a context response message to the target base station, where the context response message includes a context of the terminal.
  16. 一种请求恢复连接的方法,其特征在于,包括:A method for requesting a connection to restore, characterized in that it comprises:
    终端更新接入层密钥,得到更新后的接入层密钥;The terminal updates the access layer key to obtain an updated access layer key;
    所述终端根据更新后的接入层密钥,生成更新后的完整性保护密钥;The terminal generates an updated integrity protection key according to the updated access layer key;
    所述终端根据更新后的完整性保护密钥,生成消息认证码;The terminal generates a message authentication code according to the updated integrity protection key;
    所述终端向目标基站发送连接恢复请求消息,所述连接恢复请求消息包括所述消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;The terminal sends a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, and the connection recovery request message is used to request to resume the radio resource control RRC connection;
    所述终端接收来自所述目标基站的连接恢复拒绝消息,所述连接恢复拒绝消息用于指示拒绝所述终端恢复所述RRC连接;Receiving, by the terminal, a connection recovery reject message from the target base station, where the connection recovery reject message is used to indicate that the terminal is denied to restore the RRC connection;
    所述终端将所述终端的接入层密钥恢复为更新前的接入层密钥。The terminal restores the access layer key of the terminal to an access layer key before the update.
  17. 一种装置,其特征在于,包括处理单元和发送单元;An apparatus, comprising: a processing unit and a transmitting unit;
    所述处理单元,用于根据新鲜性参数和所述装置的完整性保护密钥,生成消息认 证码,其中,相邻两次生成消息认证码所使用的新鲜性参数不同;The processing unit is configured to generate a message authentication code according to the freshness parameter and the integrity protection key of the device, where the freshness parameter used in generating the message authentication code twice is different;
    所述发送单元,用于向目标基站发送连接恢复请求消息,所述连接恢复请求消息包括所述消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接。The sending unit is configured to send a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, and the connection recovery request message is used to request to resume the radio resource control RRC connection.
  18. 根据权利要求17所述的装置,其特征在于,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述装置尝试恢复所述RRC连接时被拒绝的次数。The apparatus of claim 17, wherein the freshness parameter comprises a number of rejections, the number of rejections being used to indicate the number of times the device was rejected when attempting to resume the RRC connection.
  19. 根据权利要求17所述的装置,其特征在于,所述连接恢复请求消息还包括指示参数,所述指示参数用于指示所述新鲜性参数。The apparatus of claim 17, wherein the connection recovery request message further comprises an indication parameter, the indication parameter being used to indicate the freshness parameter.
  20. 根据权利要求19所述的装置,其特征在于,所述新鲜性参数包括分组数据汇聚协议计数PDCP COUNT,所述指示参数包括所述PDCP COUNT的部分或全部比特位。The apparatus of claim 19, wherein the freshness parameter comprises a packet data convergence protocol count PDCP COUNT, the indication parameter comprising part or all of the bits of the PDCP COUNT.
  21. 一种装置,其特征在于,包括接收单元和发送单元;A device, comprising: a receiving unit and a transmitting unit;
    所述接收单元,用于接收来自终端的连接恢复请求消息,所述连接恢复请求消息包括消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接,所述消息认证码是根据所述终端的完整性保护密钥生成的;The receiving unit is configured to receive a connection recovery request message from the terminal, where the connection recovery request message includes a message authentication code, where the connection recovery request message is used to request to restore a radio resource control RRC connection, where the message authentication code is based on The integrity protection key of the terminal is generated;
    所述发送单元,用于若拒绝恢复所述RRC连接,则向源基站发送通知消息,所述通知消息包括所述消息认证码。The sending unit is configured to: if the RRC connection is refused to be restored, send a notification message to the source base station, where the notification message includes the message authentication code.
  22. 根据权利要求21所述的装置,其特征在于,所述通知消息用于通知更新所述源基站中的所述终端的上下文,所述通知消息通知更新的所述终端的上下文包括接入层密钥。The apparatus according to claim 21, wherein the notification message is used to notify update of a context of the terminal in the source base station, and the notification message notifies that the updated context of the terminal includes an access layer dense key.
  23. 根据权利要求21或22所述的装置,其特征在于,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,所述通知消息用于通知更新所述源基站中的所述终端的上下文,所述通知消息通知更新的所述终端的上下文包括所述新鲜性参数,其中,相邻两次生成消息认证码所使用的新鲜性参数不同。The apparatus according to claim 21 or 22, wherein the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, the notification message being used to notify the update of the source base station The context of the terminal in the notification message notifying that the updated context of the terminal includes the freshness parameter, wherein the freshness parameter used by the two adjacent generation message authentication codes is different.
  24. 一种装置,其特征在于,包括接收单元和发送单元;A device, comprising: a receiving unit and a transmitting unit;
    所述接收单元,用于接收来自终端的连接恢复请求消息,所述连接恢复请求消息包括消息认证码,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新鲜性参数不同,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;The receiving unit is configured to receive a connection recovery request message from the terminal, where the connection recovery request message includes a message authentication code, where the message authentication code is generated according to a freshness parameter and an integrity protection key of the terminal, The freshness parameter used in generating the message authentication code is different, and the connection recovery request message is used to request to resume the radio resource control RRC connection;
    所述发送单元,用于若恢复所述RRC连接,则向源基站发送上下文请求消息,所述上下文请求消息包括所述消息认证码,所述上下文请求消息用于请求获取所述终端的上下文。The sending unit is configured to: if the RRC connection is restored, send a context request message to the source base station, where the context request message includes the message authentication code, where the context request message is used to request to acquire a context of the terminal.
  25. 一种装置,其特征在于,包括接收单元和处理单元;A device comprising a receiving unit and a processing unit;
    所述接收单元,用于接收来自目标基站的通知消息,所述通知消息包括消息认证码,所述消息认证码是根据所述终端的完整性保护密钥生成的;The receiving unit is configured to receive a notification message from a target base station, where the notification message includes a message authentication code, and the message authentication code is generated according to an integrity protection key of the terminal;
    所述处理单元,用于根据所述源基站的完整性保护密钥,校验所述消息认证码;以及用于若校验所述消息认证码正确,则更新所述源基站中的所述终端的上下文。The processing unit is configured to check the message authentication code according to an integrity protection key of the source base station, and to update the source base station if the message authentication code is correct The context of the terminal.
  26. 根据权利要求25所述的装置,其特征在于,所述处理单元,具体用于更新所述源基站中的所述终端的上下文中的接入层密钥。The apparatus according to claim 25, wherein the processing unit is specifically configured to update an access layer key in a context of the terminal in the source base station.
  27. 根据权利要求25所述的装置,其特征在于,所述消息认证码是根据新鲜性参数和所述终端的完整性保护密钥生成的,其中,相邻两次生成消息认证码所使用的新 鲜性参数不同;The apparatus according to claim 25, wherein said message authentication code is generated based on a freshness parameter and an integrity protection key of said terminal, wherein freshly used two adjacent message generation code generation codes are used Different sex parameters;
    所述处理单元,具体用于根据所述新鲜性参数和所述源基站的完整性保护密钥,校验所述消息认证码。The processing unit is specifically configured to check the message authentication code according to the freshness parameter and an integrity protection key of the source base station.
  28. 根据权利要求27所述的装置,其特征在于,所述通知消息还包括指示参数,所述指示参数用于指示所述新鲜性参数。The apparatus according to claim 27, wherein the notification message further comprises an indication parameter, the indication parameter being used to indicate the freshness parameter.
  29. 根据权利要求28所述的装置,其特征在于,所述新鲜性参数包括分组数据汇聚协议计数PDCP COUNT,所述处理单元,具体用于若所述PDCP COUNT的数值大于所述终端的上下文中的PDCP COUNT的数值,则将所述终端的上下文中的PDCP COUNT的数值更新为所述指示参数指示的PDCP COUNT的数值。The device according to claim 28, wherein the freshness parameter comprises a packet data convergence protocol count PDCP COUNT, and the processing unit is configured to: if the value of the PDCP COUNT is greater than a context of the terminal The value of PDCP COUNT updates the value of PDCP COUNT in the context of the terminal to the value of PDCP COUNT indicated by the indication parameter.
  30. 根据权利要求27所述的装置,其特征在于,所述新鲜性参数包括拒绝次数,所述拒绝次数用于表示所述装置尝试恢复所述RRC连接时被拒绝的次数。The apparatus of claim 27, wherein the freshness parameter comprises a number of rejections, the number of rejections being used to indicate a number of times the device was rejected when attempting to resume the RRC connection.
  31. 一种装置,其特征在于,包括接收单元、发送单元和处理单元;An apparatus, comprising: a receiving unit, a transmitting unit, and a processing unit;
    所述接收单元,用于接收来自目标基站的上下文请求消息,所述上下文请求消息包括消息认证码,相所述消息认证码是根据所述新鲜性参数和所述终端的完整性保护密钥生成的,其中,邻两次生成消息认证码所使用的新鲜性参数不同,所述上下文请求消息用于请求获取所述终端的上下文;The receiving unit is configured to receive a context request message from a target base station, where the context request message includes a message authentication code, where the message authentication code is generated according to the freshness parameter and an integrity protection key of the terminal The freshness parameter used by the neighboring two generation message authentication codes is different, and the context request message is used to request to acquire the context of the terminal;
    所述处理单元,用于根据所述新鲜性参数和所述源基站的完整性保护密钥,校验所述消息认证码;以及用于,若校验所述消息认证码正确,则更新所述终端的上下文中的新鲜性参数;The processing unit is configured to check the message authentication code according to the freshness parameter and the integrity protection key of the source base station, and to update the location if the message authentication code is verified to be correct a freshness parameter in the context of the terminal;
    所述发送单元,用于向所述目标基站发送上下文响应消息,所述上下文响应消息包括所述终端的上下文。The sending unit is configured to send a context response message to the target base station, where the context response message includes a context of the terminal.
  32. 一种装置,应用于终端,其特征在于,包括:接收单元、发送单元和处理单元;An apparatus is applied to a terminal, comprising: a receiving unit, a sending unit, and a processing unit;
    所述处理单元,用于更新接入层密钥,得到更新后的接入层密钥;根据更新后的接入层密钥,生成更新后的完整性保护密钥;以及,根据更新后的完整性保护密钥,生成消息认证码;The processing unit is configured to update an access layer key to obtain an updated access layer key; generate an updated integrity protection key according to the updated access layer key; and, according to the updated Integrity protection key, generating a message authentication code;
    所述发送单元,用于向目标基站发送连接恢复请求消息,所述连接恢复请求消息包括所述消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;The sending unit is configured to send a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, where the connection recovery request message is used to request to resume the radio resource control RRC connection;
    所述接收单元,用于接收来自所述目标基站的连接恢复拒绝消息,所述连接恢复拒绝消息用于指示拒绝所述终端恢复所述RRC连接;The receiving unit is configured to receive a connection recovery reject message from the target base station, where the connection recovery reject message is used to indicate that the terminal is denied to restore the RRC connection;
    所述处理单元,还用于将所述终端的接入层密钥恢复为更新前的接入层密钥。The processing unit is further configured to restore an access layer key of the terminal to an access layer key before the update.
  33. 一种终端,其特征在于,包括如权利要求17-20或32中任一项所述的装置。A terminal characterized by comprising the apparatus of any one of claims 17-20 or 32.
  34. 一种计算机存储介质,其特征在于,所述计算机可读存储介质中存储有指令,当其在计算机上运行时,使得计算机执行所述权利要求1-16中任意一项所述的方法。A computer storage medium, characterized in that the computer readable storage medium stores instructions that, when run on a computer, cause the computer to perform the method of any of claims 1-16.
  35. 一种装置,其特征在于,包括:包括存储器以及与该存储器耦合的处理器;An apparatus, comprising: a memory and a processor coupled to the memory;
    所述存储器中保存有程序指令,当所述处理器执行所述程序指令时,使得所述装置执行上述权利要求1-16任一所述的方法。Program instructions are stored in the memory, and when the processor executes the program instructions, cause the apparatus to perform the method of any of the preceding claims 1-16.
  36. 一种请求恢复连接的方法,其特征在于,所述方法应用于终端从不活跃态恢复到连接态的场景下,包括:A method for requesting a connection to restore, wherein the method is applied to a scenario in which a terminal is restored from an inactive state to a connected state, including:
    终端更新接入层密钥,得到更新后的接入层密钥;The terminal updates the access layer key to obtain an updated access layer key;
    所述终端向目标基站发送连接恢复请求消息,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;Sending, by the terminal, a connection recovery request message to the target base station, where the connection recovery request message is used to request to resume the radio resource control RRC connection;
    所述终端接收来自所述目标基站的连接恢复拒绝消息,所述连接恢复拒绝消息用于指示拒绝所述终端恢复所述RRC连接;Receiving, by the terminal, a connection recovery reject message from the target base station, where the connection recovery reject message is used to indicate that the terminal is denied to restore the RRC connection;
    所述终端将所述更新后的接入层密钥恢复为更新前的接入层密钥;其中,所述更新前的接入层密钥为所述终端进入不活跃态之前,所述终端和自身所连接的基站所使用接入层密钥。Recovering, by the terminal, the updated access layer key to an access layer key before the update; wherein the access layer key before the update is before the terminal enters an inactive state, the terminal The access stratum key used by the base station to which it is connected.
  37. 根据权利要求36所述的方法,其特征在于,在所述终端向目标基站发送连接恢复请求消息之前,所述方法还包括:The method according to claim 36, wherein before the terminal sends a connection recovery request message to the target base station, the method further includes:
    终端根据完整性保护密钥和完整性保护算法,生成消息认证码;其中,所述完整性密钥和所述完整性保护算法为所述终端进入不活跃态之前,所述终端和自身所连接的基站所使用的完整性保护密钥和完整性保护算法;The terminal generates a message authentication code according to the integrity protection key and the integrity protection algorithm, where the integrity key and the integrity protection algorithm are connected to the terminal before the terminal enters an inactive state. Integrity protection key and integrity protection algorithm used by the base station;
    其中,所述连接恢复请求消息中还包括所述消息认证码。The connection recovery request message further includes the message authentication code.
  38. 根据权利要求36或37所述的方法,其特征在于,所述终端将所述更新后的接入层密钥恢复为更新前的接入层密钥,包含:The method according to claim 36 or 37, wherein the terminal restores the updated access layer key to an access layer key before the update, comprising:
    所述终端将更新前的安全上下文设置为当前安全上下文,所述更新前的安全上文包含所述更新前的接入层密钥。The terminal sets the pre-update security context to the current security context, and the pre-update security includes the pre-update access layer key.
  39. 一种终端,其特征在于,包括:接收单元、发送单元和处理单元;A terminal, comprising: a receiving unit, a sending unit, and a processing unit;
    所述处理单元,用于更新接入层密钥,得到更新后的接入层密钥;The processing unit is configured to update an access layer key to obtain an updated access layer key;
    所述发送单元,用于向目标基站发送连接恢复请求消息,所述连接恢复请求消息包括所述消息认证码,所述连接恢复请求消息用于请求恢复无线资源控制RRC连接;The sending unit is configured to send a connection recovery request message to the target base station, where the connection recovery request message includes the message authentication code, where the connection recovery request message is used to request to resume the radio resource control RRC connection;
    所述接收单元,用于接收来自所述目标基站的连接恢复拒绝消息,所述连接恢复拒绝消息用于指示拒绝所述终端恢复所述RRC连接;The receiving unit is configured to receive a connection recovery reject message from the target base station, where the connection recovery reject message is used to indicate that the terminal is denied to restore the RRC connection;
    所述处理单元,还用于将所述终端的接入层密钥恢复为更新前的接入层密钥;其中,所述更新前的接入层密钥为所述终端进入不活跃态之前,所述终端和自身所连接的基站所使用接入层密钥。The processing unit is further configured to restore the access layer key of the terminal to an access layer key before the update; where the pre-update access layer key is before the terminal enters an inactive state The access layer key used by the terminal and the base station to which the terminal is connected.
  40. 根据权利要求39所述的终端,其特征在于,所述处理单元,还用于根据完整性保护密钥和完整性保护算法,生成消息认证码;其中,所述完整性密钥和所述完整性保护算法为所述终端进入不活跃态之前,所述终端和自身所连接的基站所使用的完整性保护密钥和完整性保护算法;The terminal according to claim 39, wherein the processing unit is further configured to generate a message authentication code according to an integrity protection key and an integrity protection algorithm; wherein the integrity key and the complete The integrity protection algorithm is an integrity protection key and an integrity protection algorithm used by the terminal and the base station to which the terminal is connected before the terminal enters an inactive state;
    其中,所述连接恢复请求消息中还包括所述消息认证码。The connection recovery request message further includes the message authentication code.
  41. 根据权利要求39或40所述的终端,其特征在于,所述处理单元,具体用于将更新前的安全上下文设置为当前安全上下文,所述更新前的安全上文包含所述更新前的接入层密钥。The terminal according to claim 39 or 40, wherein the processing unit is specifically configured to set a pre-update security context as a current security context, and the pre-update security includes the pre-update connection Incoming layer key.
  42. 一种计算机存储介质,其特征在于,所述计算机可读存储介质中存储有指令,当其在计算机上运行时,使得计算机执行所述权利要求36-38中任意一项所述的方法。A computer storage medium, characterized in that the computer readable storage medium stores instructions that, when executed on a computer, cause the computer to perform the method of any one of claims 36-38.
  43. 一种装置,其特征在于,包括:包括存储器以及与该存储器耦合的处理器;An apparatus, comprising: a memory and a processor coupled to the memory;
    所述存储器中保存有程序指令,当所述处理器执行所述程序指令时,使得所述装置执行上述权利要求36-38任一所述的方法。Program instructions are stored in the memory, and when the processor executes the program instructions, cause the apparatus to perform the method of any of the preceding claims 36-38.
PCT/CN2018/116000 2017-11-16 2018-11-16 Method and device for requesting connection recovery WO2019096265A1 (en)

Priority Applications (9)

Application Number Priority Date Filing Date Title
ES18879002T ES2928106T3 (en) 2017-11-16 2018-11-16 Method and device to request connection recovery
KR1020207017141A KR102354626B1 (en) 2017-11-16 2018-11-16 Connection resume request method and device
EP18879002.6A EP3713271B1 (en) 2017-11-16 2018-11-16 Method and device for requesting connection recovery
RU2020119591A RU2772617C2 (en) 2017-11-16 2018-11-16 Method and apparatus for requesting reconnection
EP22186005.9A EP4152790A1 (en) 2017-11-16 2018-11-16 Connection resume request method and apparatus
BR112020009673-3A BR112020009673A2 (en) 2017-11-16 2018-11-16 connection reconnection request method and apparatus
AU2018366755A AU2018366755B2 (en) 2017-11-16 2018-11-16 Connection resume request method and apparatus
US16/874,117 US11627623B2 (en) 2017-11-16 2020-05-14 Connection resume request method and apparatus
US18/185,762 US20230292388A1 (en) 2017-11-16 2023-03-17 Connection Resume Request Method and Apparatus

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN201711138495 2017-11-16
CN201711138495.4 2017-11-16
CN201810149050.4A CN109803258B (en) 2017-11-16 2018-02-13 Method and device for requesting to recover connection
CN201810149050.4 2018-02-13

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US16/874,117 Continuation US11627623B2 (en) 2017-11-16 2020-05-14 Connection resume request method and apparatus

Publications (1)

Publication Number Publication Date
WO2019096265A1 true WO2019096265A1 (en) 2019-05-23

Family

ID=66538927

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/116000 WO2019096265A1 (en) 2017-11-16 2018-11-16 Method and device for requesting connection recovery

Country Status (1)

Country Link
WO (1) WO2019096265A1 (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106961712A (en) * 2016-01-12 2017-07-18 展讯通信(上海)有限公司 Cell accessing method and base station
CN107046735A (en) * 2016-02-05 2017-08-15 中兴通讯股份有限公司 Connection processing method and device between terminal and network
CN107294723A (en) * 2016-03-31 2017-10-24 中兴通讯股份有限公司 The generation of message integrity authentication information and verification method, device and checking system
CN107318176A (en) * 2016-04-26 2017-11-03 中兴通讯股份有限公司 Recover acquisition, sending method and the device, UE, access network equipment of mark

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106961712A (en) * 2016-01-12 2017-07-18 展讯通信(上海)有限公司 Cell accessing method and base station
CN107046735A (en) * 2016-02-05 2017-08-15 中兴通讯股份有限公司 Connection processing method and device between terminal and network
CN107294723A (en) * 2016-03-31 2017-10-24 中兴通讯股份有限公司 The generation of message integrity authentication information and verification method, device and checking system
CN107318176A (en) * 2016-04-26 2017-11-03 中兴通讯股份有限公司 Recover acquisition, sending method and the device, UE, access network equipment of mark

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3713271A4 *

Similar Documents

Publication Publication Date Title
AU2018366755B2 (en) Connection resume request method and apparatus
CN109729524B (en) RRC (radio resource control) connection recovery method and device
JP2020504559A (en) PDU session management
EP3713372A1 (en) Method and device for creating user group
CN110383868B (en) Inactive state security support in a wireless communication system
WO2019096171A1 (en) Method and apparatus for requesting recovery of connection
WO2009152759A1 (en) Method and device for preventing loss of network security synchronization
CN110731091B (en) Method, element, medium and user equipment for facilitating radio link recovery for user equipment
WO2019062374A1 (en) Key derivation algorithm negotiation method and apparatus
CN111886885B (en) Secure authentication when recovering an RRC connection
US20220303763A1 (en) Communication method, apparatus, and system
CN111836263A (en) Communication processing method and communication processing device
CN110545253B (en) Information processing method, device, equipment and computer readable storage medium
CN109842484B (en) Method, device and equipment for updating next-hop chain counter
WO2019096265A1 (en) Method and device for requesting connection recovery
RU2772617C2 (en) Method and apparatus for requesting reconnection
CN116783986A (en) Method and device for data transmission processing
WO2023072271A1 (en) Method and apparatus for managing security context
CN116634426A (en) Communication method and device
KR20230076258A (en) Method and apparatus for security settings in communication system
CN116530119A (en) Method, device and system for protecting serial numbers in wireless network
CN113810903A (en) Communication method and device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18879002

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 20207017141

Country of ref document: KR

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2018879002

Country of ref document: EP

Effective date: 20200616

ENP Entry into the national phase

Ref document number: 2018366755

Country of ref document: AU

Date of ref document: 20181116

Kind code of ref document: A

REG Reference to national code

Ref country code: BR

Ref legal event code: B01A

Ref document number: 112020009673

Country of ref document: BR

ENP Entry into the national phase

Ref document number: 112020009673

Country of ref document: BR

Kind code of ref document: A2

Effective date: 20200514