Terminal key management method, device, equipment and storage medium
By generating and managing channel keys and business channel keys on the Internet of Things terminal key management server, the problem of easy stolen communication keys between the terminal and the business platform is solved, and communication security and data transmission reliability are improved .
Patent Information
- Application Number
- CN202411083840.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-08
- Publication Date
- 2024-11-26
- Estimated Expiration
- 2044-08-08
AI Technical Summary
In the prior art, the communication keys between the Internet of Things terminals and the business platform are easily stolen, resulting in low security of data communication and risk of tampering and forging.
By generating and issuing management channel keys and business channel keys on the terminal key management server, the initial management channel based on the preset key is terminated, a new secret key channel generated based on the HASH algorithm is established, and monitoring The module monitors the usage status of the key in real time, abolishes and regenerates the key in a timely manner, and ensures communication security.
It improves the communication security between the terminal and the service platform, reduces the risk of secret keys being stolen, and enhances the reliability and security of data transmission.
Smart Images

Figure CN118611995B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of Internet of Things, and in particular to a terminal key management method, device, equipment and storage medium. Background Art
[0002] With the development of the Internet of Things, the use of IoT terminals is constantly expanding, and a large number of terminals are interacting with data through various communication protocols and various business platforms. Therefore, how to ensure that the data between the terminal and the business platform can be interacted safely and accurately without being forged, tampered with, or intercepted has become a problem that needs to be solved urgently. In the prior art, when the terminal conducts encrypted communication with the business platform, it usually uses a preset / manually configured key to establish a data connection. If the communication key between the terminal and the business platform is stolen by other devices, there is a possibility that the data communication between the devices will be tampered with or forged, and the communication security is low. Summary of the invention
[0003] The embodiments of the present invention provide a terminal key management method, apparatus, device and storage medium, aiming to improve the communication security between a terminal and a service platform.
[0004] In a first aspect, an embodiment of the present invention provides a terminal key management method, which is applied to a terminal key management server, wherein the terminal key management server includes a key management service module, and the method includes:
[0005] If the key management service module receives an initialization request sent by the terminal, it sends the management channel key generated according to the initialization request and the allocated authorized terminal identifier to the terminal;
[0006] If the key management service module receives a key confirmation response sent by the terminal, the initial management channel established with the terminal is terminated, wherein the initial management channel is a connection channel established based on a preset key;
[0007] If the key management service module receives a service channel establishment request sent by the terminal, it will send the service channel key generated according to the service channel establishment request to the terminal and the service platform, so that a data channel is established between the terminal and the service platform according to the service channel.
[0008] In a second aspect, an embodiment of the present invention further provides a terminal key management device, which is applied to a terminal key management server, wherein the terminal key management server includes a key management service module, and the method includes:
[0009] A generating and issuing unit, configured to issue the management channel key generated according to the initialization request and the assigned authorized terminal identifier to the terminal if the key management service module receives an initialization request sent by the terminal;
[0010] a receiving and terminating unit, configured to terminate the initial management channel established with the terminal if the key management service module receives a key confirmation response sent by the terminal, wherein the initial management channel is a connection channel established based on a preset key;
[0011] A generating and establishing unit is used for the key management service module to send the business channel key generated according to the business channel establishment request to the terminal and the business platform if it receives the business channel establishment request sent by the terminal, so that a data channel is established between the terminal and the business platform according to the business channel.
[0012] In a third aspect, an embodiment of the present invention further provides a computer device, wherein the computer device is equipped with a terminal key management server, the computer device comprises a memory and a processor, a computer program is stored in the memory, and the above method is implemented when the processor executes the computer program.
[0013] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein the storage medium stores a computer program, and the computer program can implement the above method when executed by a processor.
[0014] The embodiment of the present invention provides a terminal key management method, device, equipment and storage medium. The method is applied to a terminal key management service end, and the terminal key management service end includes a key management service module. The method includes: if the key management service module receives an initialization request sent by the terminal, the management channel key generated according to the initialization request and the assigned authorized terminal identifier are sent to the terminal; if the key management service module receives a confirmation key response sent by the terminal, the initial management channel established with the terminal is terminated, wherein the initial management channel is a connection channel established based on a preset key; if the key management service module receives a service channel establishment request sent by the terminal, the service channel key generated according to the service channel establishment request is sent to the terminal and the service platform, so that the terminal and the service platform establish a data channel according to the service channel. The technical solution of the embodiment of the present invention generates and sends the management channel key and the service channel key uniformly through the key management module in the terminal key management service end, without manual participation, reducing the risk of key theft, thereby improving the communication security between the terminal and the service platform. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying any creative work.
[0016] Figure 1 A schematic diagram of a process flow of a terminal key management method provided by an embodiment of the present invention;
[0017] Figure 2 A schematic diagram of an application scenario of a terminal key management method provided by an embodiment of the present invention;
[0018] Figure 3 A schematic diagram of a key service management module issuing a management channel key and a business channel key according to an embodiment of the present invention;
[0019] Figure 4 A schematic diagram of a process flow of a terminal key management method provided by another embodiment of the present invention;
[0020] Figure 5 A schematic diagram of a process flow of a terminal key management method provided by another embodiment of the present invention;
[0021] Figure 6 A schematic block diagram of a terminal key management device provided by an embodiment of the present invention; and
[0022] Figure 7 A schematic block diagram of a computer device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0023] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0024] It should be understood that when used in this specification and the appended claims, the terms "include" and "comprises" indicate the presence of described features, integers, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.
[0025] It should also be understood that the terms used in this specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the specification of the present invention and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.
[0026] It should be further understood that the term "and / or" used in the present description and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
[0027] As used in this specification and the appended claims, the term "if" may be interpreted as "when" or "upon" or "in response to determining" or "in response to detecting," depending on the context. Similarly, the phrases "if it is determined" or "if [described condition or event] is detected" may be interpreted as meaning "upon determination" or "in response to determining" or "upon detection of [described condition or event]" or "in response to detecting [described condition or event]," depending on the context.
[0028] See also Figure 1 , Figure 1 is a flow chart of a terminal key management method provided by an embodiment of the present invention. The terminal key management method of the embodiment of the present invention can be applied to a terminal key management server. For example, the terminal key management method can be implemented by a software program configured on the terminal key management server. It should be noted that in this embodiment, Figure 2 As shown, the terminal key management service end includes a key management service module, a monitoring module and an authentication module, wherein the key management service module can generate management channel keys and business channel keys according to different key usage scenarios; the monitoring module is used to monitor whether the management channel keys and business channel keys are used normally; the authentication module is used to authenticate whether the management channel established between the terminal and the key management service module and the data channel established between the terminal and the business platform are legal. Figure 1 As shown, the method includes the following steps S100-S120.
[0029] S100: If the key management service module receives an initialization request sent by a terminal, it sends the management channel key generated according to the initialization request and the allocated authorized terminal identifier to the terminal.
[0030] In an embodiment of the present invention, the terminal uses a preset key to establish an initial management channel with a key management service module. After the initial management channel is established, the terminal actively sends an initialization request. The key management service module receives the initialization request sent by the terminal, and sends the management channel key generated according to the initialization request and the assigned authorized terminal identifier to the terminal. Specifically, the initialization request carries the IMEI number corresponding to the terminal. If the key management service module receives the initialization request sent by the terminal, it detects whether the IMEI number is in the device whitelist; if the IMEI number is in the device whitelist, the authorized terminal identifier corresponding to the IMEI number is assigned to the terminal; understandably, if the IMEI number is not in the device whitelist, the authorized terminal identifier corresponding to the IMEI number is not assigned to the terminal; after the authorized terminal identifier is assigned to the terminal, the current time and the generated random number are obtained, and the management channel key is generated through the HASH algorithm according to the current time, the random number and the authorized terminal identifier, such as Figure 3 As shown, the management channel key and the authorized terminal identifier are sent to the terminal. It should be noted that, in this embodiment, the management channel key is the first type of key, and the authorized terminal is represented by DeviceId.
[0031] S110. If the key management service module receives a key confirmation response sent by the terminal, it terminates the initial management channel established with the terminal, wherein the initial management channel is a connection channel established based on a preset key.
[0032] In the embodiment of the present invention, after the terminal receives the management channel key issued by the key management service module, it will send a confirmation key response to the key management service module. If the key management service module receives the confirmation key response sent by the terminal, it will terminate the initial management channel established with the terminal, wherein the initial management channel is a connection channel established based on a preset key. It is understandable that the terminal can subsequently use the management channel key to establish a management channel with the key management service module.
[0033] S120. If the key management service module receives a service channel establishment request sent by the terminal, it will send the service channel key generated according to the service channel establishment request to the terminal and the service platform, so that a data channel is established between the terminal and the service platform according to the service channel.
[0034] In an embodiment of the present invention, after the terminal uses the management channel key to establish a management channel with the key management service module, the key management service module receives a service channel establishment request sent by the terminal based on the management channel, and sends the service channel key generated according to the service channel establishment request to the terminal and the service platform, so that a data channel is established between the terminal and the service platform according to the service channel. Specifically, the service channel request carries an application protocol type, and sending the service channel key generated according to the service channel establishment request to the terminal and the service platform includes: obtaining the current time and a generated random number; generating the service channel key through a HASH algorithm according to the current time, the random number, the application protocol type, and the authorized terminal identifier, such as Figure 3 As shown, the business channel key is sent to the terminal and the business platform. It should be noted that, in this embodiment, the application protocol types include TLS, SSL and other protocol types. It should also be noted that, in this embodiment, the business channel key is the second type of key. It is understandable that the business channel key and the management channel key have their own validity period and can be used within the validity period. If the validity period exceeds the validity period, the key management module needs to regenerate and distribute the regenerated business channel key and the management channel key to the specified terminal.
[0035] Figure 4 FIG. 1 is a flow chart of a terminal key management method provided by another embodiment of the present invention. Figure 4 As shown, the terminal key management method of this embodiment includes steps S200-S240. Steps S200-S220 are the same as steps S100-S120 in the above embodiment, and are not repeated here. The following is a detailed description of steps S230 and S240 added in this embodiment.
[0036] S230. If the monitoring module receives an authentication result from the authentication module that the authentication is illegal, wherein the authentication result is to authenticate whether the management channel established between the terminal and the key management service module and the data channel established between the terminal and the business platform are legal.
[0037] S240. Process the management channel key and the business channel key according to the current usage terminal and current usage status of the management channel key and the business channel key through the monitoring module, and re-establish the management channel between the terminal and the key management service module and / or the data channel between the terminal and the business platform.
[0038] In an embodiment of the present invention, if the authentication module authenticates that the management channel established between the terminal and the key management service module or the data channel established between the terminal and the business platform is illegal, the authentication result is illegal, and the monitoring module performs corresponding processing on the management channel key and the business channel key according to the current using terminal and current using status of the management channel key and the business channel key, and re-establishes the management channel between the terminal and the key management service module and / or the data channel between the terminal and the business platform. Specifically, if the monitoring module detects that the currently used terminal is not the belonging terminal corresponding to the management channel key or the current usage status of the management channel key is already used, the belonging terminal is notified to abolish the management channel key, and a new management channel key is sent to the belonging terminal through the key management service module, so that the terminal re-establishes the management channel with the key management service module based on the new management channel key; if the monitoring module detects that the currently used terminal is not the belonging terminal corresponding to the service channel key or the current usage status of the service channel key is already used, the belonging terminal and the service platform are notified to abolish the service channel key, and the belonging terminal terminates the connection channel with the service platform, and a new service channel key is sent to the belonging terminal and the service platform through the key management service module, so that the terminal re-establishes the data channel with the key management service module and the service platform based on the new service channel key. It should be noted that, in this embodiment, if the monitoring module detects that the currently used terminal is not the home terminal corresponding to the management channel key or the current use status of the management channel key is already used, it indicates that the management channel key has been leaked, and a new management channel key needs to be regenerated to ensure the security of data transmission. Understandably, if the monitoring module detects that the currently used terminal is not the home terminal corresponding to the service channel key or the current use status of the service channel key is already used, it indicates that the service channel key has been leaked, and a new service channel key also needs to be regenerated to ensure the security of data transmission.
[0039] Figure 5 FIG. 1 is a flow chart of a terminal key management method provided by another embodiment of the present invention. Figure 5 As shown, the terminal key management method of this embodiment includes steps S300-S380. Steps S300-S340 are the same as steps S200-S240 in the above embodiment, and are not repeated here. The following is a detailed description of steps S350-S380 added in this embodiment.
[0040] S350: If the key management service module receives a management key update request sent by the terminal, it sends the generated new management channel key to the terminal, and after receiving a new management key response sent by the terminal, it annuls the management channel key, closes the management channel established between the key management service module and the terminal based on the management channel key, and establishes a new management channel with the terminal based on the new management channel key;
[0041] S360: If the key management service module receives a service key update request sent by the terminal, the service channel key is revoked, and a generated new service channel key is sent to the terminal and the service platform, so that the terminal re-establishes a data channel with the service platform according to the new service channel key;
[0042] S370: If the key management service module receives a management key revocation request sent by the terminal, it will reversely confirm the key revocation to the terminal. After receiving the key revocation response from the terminal, it will notify the terminal that the management channel key is revoked and disconnect the management channel with the terminal.
[0043] S380: If the key management service module receives a service key revocation request sent by the terminal, it will revoke the service channel key and disconnect the data channel between the terminal and the service platform.
[0044] In an embodiment of the present invention, a business module and a management module are configured in the terminal. The business module mainly uses the business channel key issued by the key management service module to establish a data channel with the business platform; the management module is used to interact with the key management service module and manage the use cycle of the business channel key and the management channel key received by the terminal, and can also actively request the key management service module to update the key, cancel the key, and apply for the key when necessary. After receiving the request of the terminal, the key management service module shall perform the corresponding operation according to the content of the user terminal request. The key update is specifically shown in steps S350 and S360, which is divided into the management channel key update and the business channel key update. The specific update process is different for the update of different keys. The second key cancellation is specifically shown in steps S370 and S380, which is divided into the management channel key cancellation and the business channel key cancellation. The specific cancellation process is different for the cancellation of different keys. The process of applying for a key is that after the key management service module receives the management key application request or business key application request sent by the terminal, it will send the generated management channel key or business channel key to the terminal; then the terminal uses the new management channel key to establish a management channel or uses the new business channel key to establish a data channel with the business platform.
[0045] For ease of understanding, the process of establishing a data channel between the terminal and the business platform is described in detail as follows:
[0046] (1) Assume that there are two terminals (A1 and A2), which process two different services respectively and need to access two different service platforms (B1 and B2). A1 uses the DTLS protocol to access service platform B1, and A2 uses the TLS protocol to access service platform B2.
[0047] (2) After the initialization process, terminal A1 applies for the DTLS key from the key management service module; the key management service module generates the PSK and PSKID applicable to the DTLS protocol, and sends the PSK and PSKID to terminal A1 and business platform B1; terminal A1 and business platform B1 establish the corresponding data channel and conduct data communication;
[0048] (3) After the initialization process, terminal A2 applies for the TLS key from the key management service module. The key management service module generates the public key and private key applicable to the TLS protocol, and sends the public key and private key applicable to the TLS protocol to terminal A2 and business platform B2; terminal A2 and business platform B2 establish the corresponding data channel and conduct data communication;
[0049] (4) After terminal A1 connects to service platform B1, terminal A1' uses the PSK and PSKID of terminal A1 to log in to service platform B1; after the monitoring module finds that the PSK and PSKID are reused and used by unauthorized terminals, it notifies the key management service module to generate new PSK and PSKID and sends them to the authorized terminal, and at the same time notifies service platform B1 to cancel the original PSK and PSKID, and cuts off the data channel established using the original PSK and PSKID;
[0050] (5) When terminal A2 encounters an exception while connecting to business platform B2, it requests the key management service module to update the key. The key management service module generates new public and private keys applicable to the TLS protocol based on the key application type originally used by A2, and sends the public and private keys to terminal A2. Terminal A2 uses the new public and private keys to establish a data channel with business platform B2.
[0051] To sum up, when the terminal establishes a secure data channel with the business platform, the key management service module generates a business channel key and sends it to the business platform and the terminal through a secure management channel, wherein the management channel is a connection channel established between the key management module and the terminal based on the management channel key. At the same time, the monitoring module monitors the use of the business channel key and the management channel key in real time. If an abnormality is found, the business channel key and / or the management channel key will be abolished in real time, and a new business channel key and / or management channel key will be generated and issued for use by the terminal and the business platform. While ensuring real-time data interaction between the terminal and the business platform as much as possible, the safe use of the business channel key and the management channel key is guaranteed. The terminal can also apply for a key, and can also perform key abolition and key update operations on the business channel key and the management channel key when there is an abnormality. It can be seen that in this embodiment, the key management module in the terminal key management server uniformly generates and issues management channel keys and business channel keys without human intervention, reducing the risk of key theft, thereby improving the communication security between the terminal and the business platform; the monitoring module can promptly detect communication anomalies and handle them in a timely manner, further improving the communication security between the terminal and the business platform, not only that, but also improving the customizability and scalability of terminal key management.
[0052] Figure 6 is a schematic block diagram of a terminal key management device 200 provided in an embodiment of the present invention. Figure 6 As shown, corresponding to the above terminal key management method, the present invention also provides a terminal key management device 200. The terminal key management device 200 includes a unit for executing the above terminal key management method. Figure 6 The terminal key management device 200 includes a generating and sending unit 201, a receiving and terminating unit 202, and a generating and establishing unit 203.
[0053] Among them, the generating and sending unit 201 is used for the key management service module to send the management channel key generated according to the initialization request and the assigned authorized terminal identifier to the terminal if the key management service module receives an initialization request sent by the terminal; the receiving and terminating unit 202 is used for the key management service module to terminate the initial management channel established with the terminal if it receives a confirmation key response sent by the terminal, wherein the initial management channel is a connection channel established based on a preset key; the generating and establishing unit 203 is used for the key management service module to send the business channel key generated according to the business channel establishment request to the terminal and the business platform if it receives a business channel establishment request sent by the terminal, so that a data channel is established between the terminal and the business platform according to the business channel.
[0054] In some embodiments, such as the present embodiment, the generating and issuing unit 201 includes a detecting unit, an allocating unit, and a first generating and issuing sub-unit.
[0055] Among them, the detection unit is used for the key management service module to detect whether the IMEI number is in the device whitelist if it receives an initialization request sent by the terminal; the allocation unit is used for allocating an authorized terminal identifier corresponding to the IMEI number to the terminal if the IMEI number exists in the device whitelist; the first generation subunit is used to obtain the current time and the generated random number, and generate the management channel key through the HASH algorithm according to the current time, the random number and the authorized terminal identifier, and send the management channel key and the authorized terminal identifier to the terminal.
[0056] In some embodiments, such as the present embodiment, the generation establishment unit 203 includes an acquisition unit and a second generation and sending sub-unit.
[0057] Among them, the acquisition unit is used to obtain the current time and the generated random number; the second generation and sending sub-unit is used to generate the business channel key through the HASH algorithm according to the current time, the random number, the application protocol type and the authorized terminal identifier, and send the business channel key to the terminal and the business platform.
[0058] In some embodiments, such as the present embodiment, the terminal key management device 200 further includes a receiving unit, a processing establishment unit, a sending and closing unit, a receiving and sending unit, a confirming and disconnecting unit, and a receiving and revoking unit.
[0059] Among them, the receiving unit is used for the monitoring module to detect if the authentication result sent by the authentication module is illegal, wherein the authentication result is to authenticate whether the management channel established between the terminal and the key management service module and the data channel established between the terminal and the business platform are legal; the processing and establishment unit is used to process the management channel key and the business channel key according to the current using terminal and current using status of the management channel key and the business channel key through the monitoring module, and re-establish the management channel between the terminal and the key management service module and / or the data channel between the terminal and the business platform; the sending and closing unit is used for the key management service module to send the generated new management channel key to the terminal if it receives a management key update request sent by the terminal, and after receiving the new management key response sent by the terminal, abolish the management channel key, close the key management service module and the terminal. The terminal establishes a management channel based on the management channel key, and establishes a new management channel with the terminal according to the new management channel key; the receiving and sending unit is used for the key management service module to cancel the business channel key if it receives a business key update request sent by the terminal, and send the generated new business channel key to the terminal and the business platform, so that the terminal re-establishes the data channel with the business platform according to the new business channel key; the confirmation and disconnection unit is used for the key management service module to reversely confirm the key revocation to the terminal if it receives a management key revocation request sent by the terminal, and after receiving the key revocation response from the terminal, notify the terminal that the management channel key is revoked and disconnect the management channel with the terminal; the receiving and revocation unit is used for the key management service module to cancel the business channel key if it receives a business key revocation request sent by the terminal, and disconnect the terminal from the data channel between the business platform.
[0060] In some embodiments, such as the present embodiment, the processing establishment unit includes a detection sending unit and a detection terminating unit.
[0061] Among them, the detection and sending unit is used to notify the belonging terminal to abolish the management channel key if the monitoring module detects that the currently used terminal is not the belonging terminal corresponding to the management channel key or the current usage status of the management channel key is already used, and send a new management channel key to the belonging terminal through the key management service module, so that the terminal re-establishes the management channel with the key management service module according to the new management channel key; the detection termination unit is used to notify the belonging terminal and the service platform to abolish the service channel key if the monitoring module detects that the currently used terminal is not the belonging terminal corresponding to the service channel key or the current usage status of the service channel key is already used, and the belonging terminal terminates the connection channel with the service platform, and sends a new service channel key to the belonging terminal and the service platform through the key management service module, so that the terminal re-establishes the data channel with the key management service module and the service platform according to the new service channel key.
[0062] It should be noted that technicians in the relevant field can clearly understand that the specific implementation process of the above-mentioned terminal key management device 200 and each unit can refer to the corresponding description in the aforementioned method embodiment, and for the convenience and brevity of description, it will not be repeated here.
[0063] The terminal key management device can be implemented in the form of a computer program. Figure 7 Runs on the computer device shown.
[0064] See also Figure 7 , Figure 7 900 is a schematic block diagram of a computer device provided in an embodiment of the present application. The computer device 900 is a device with a terminal key management server.
[0065] See also Figure 7 The computer device 900 includes a processor 902 , a memory and an interface 905 connected via a system bus 901 , wherein the memory may include a storage medium 903 and an internal memory 904 .
[0066] The storage medium 903 may store an operating system 9031 and a computer program 9032. When the computer program 9032 is executed, the processor 902 may execute the terminal key management method.
[0067] The processor 902 is used to provide computing and control capabilities to support the operation of the entire computer device 900 .
[0068] The internal memory 904 provides an environment for the operation of the computer program 9032 in the storage medium 903. When the computer program 9032 is executed by the processor 902, the processor 902 can execute a terminal key management method.
[0069] The interface 905 is used to communicate with other devices. Those skilled in the art will appreciate that Figure 7 The structure shown in the figure is merely a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer device 900 to which the solution of the present application is applied. The specific computer device 900 may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0070] The processor 902 is used to run a computer program 9032 stored in the memory to implement the process steps of the embodiment of the above method.
[0071] It should be understood that in the embodiment of the present application, the processor 902 may be a central processing unit (CPU), and the processor 902 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0072] It can be understood by those skilled in the art that all or part of the processes in the method for implementing the above embodiment can be completed by instructing related hardware through a computer program. The computer program can be stored in a storage medium, which is a computer-readable storage medium. The computer program is executed by at least one processor in the wireless communication system to implement the process steps of the embodiment of the above method.
[0073] Therefore, the present invention also provides a storage medium. The storage medium may be a computer-readable storage medium. The storage medium stores a computer program. When the computer program is executed by a processor, the processor executes any embodiment of the terminal key management method.
[0074] The storage medium may be a USB flash drive, a mobile hard disk, a read-only memory (ROM), a magnetic disk, or an optical disk, etc., which are computer-readable storage media that can store program codes.
[0075] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, wireless communication software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in terms of function in the above description. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0076] In the several embodiments provided by the present invention, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of each unit is only a logical function division, and there may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed.
[0077] The steps in the method of the embodiment of the present invention can be adjusted in order, combined and deleted according to actual needs. The units in the device of the embodiment of the present invention can be combined, divided and deleted according to actual needs. In addition, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0078] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The wireless communication software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal wireless communication, terminal, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention.
[0079] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0080] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
[0081] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed by the present invention, and these modifications or replacements should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.
Claims
1. A terminal key management method, applied to a terminal key management server, characterized in that: The terminal key management server includes a key management service module, and the method includes: If the key management service module receives an initialization request sent by the terminal, it sends the management channel key generated according to the initialization request and the allocated authorized terminal identifier to the terminal; If the key management service module receives a key confirmation response sent by the terminal, the initial management channel established with the terminal is terminated, wherein the initial management channel is a connection channel established based on a preset key; The key management service module receives a service channel establishment request sent by the terminal based on the management channel, and sends the service channel key generated according to the service channel establishment request to the terminal and the service platform, so that a data channel is established between the terminal and the service platform according to the service channel, wherein the management channel is a channel established between the terminal and the key management service module using the management channel key.
2. The terminal key management method according to claim 1, characterized in that: The initialization request carries the IMEI number corresponding to the terminal. If the key management service module receives the initialization request sent by the terminal, the management channel key generated according to the initialization request and the allocated authorized terminal identifier are sent to the terminal, including: If the key management service module receives the initialization request sent by the terminal, it detects whether the IMEI number is in the device whitelist; If the IMEI number exists in the device whitelist, assigning an authorized terminal identifier corresponding to the IMEI number to the terminal; The current time and the generated random number are obtained, and the management channel key is generated through a HASH algorithm according to the current time, the random number and the authorized terminal identifier, and the management channel key and the authorized terminal identifier are issued to the terminal.
3. The terminal key management method according to claim 1, characterized in that: The service channel request carries an application protocol type, and the service channel key generated according to the service channel establishment request is sent to the terminal and the service platform, including: Get the current time and the generated random number; The service channel key is generated by a HASH algorithm according to the current time, the random number, the application protocol type and the authorized terminal identifier, and the service channel key is issued to the terminal and the service platform.
4. The terminal key management method according to claim 3, characterized in that: The terminal key management server also includes a monitoring module and an authentication module, and the method also includes: If the monitoring module receives an authentication result sent by the authentication module indicating that the authentication is illegal, wherein the authentication result is to authenticate whether the management channel established between the terminal and the key management service module and the data channel established between the terminal and the business platform are legal; The monitoring module processes the management channel key and the business channel key according to their current usage terminals and current usage status, and re-establishes the management channel between the terminal and the key management service module and / or the data channel between the terminal and the business platform.
5. The terminal key management method according to claim 4, characterized in that: The processing of the management channel key and the service channel key by the monitoring module according to the current use terminal and current use status of the management channel key and the service channel key, and re-establishing the management channel between the terminal and the key management service module and / or the data channel between the terminal and the service platform includes: If the monitoring module detects that the currently used terminal is not the home terminal corresponding to the management channel key or the current use status of the management channel key is already used, the home terminal is notified to abolish the management channel key, and a new management channel key is sent to the home terminal through the key management service module, so that the terminal re-establishes a management channel with the key management service module according to the new management channel key; If the monitoring module detects that the currently used terminal is not the home terminal corresponding to the business channel key or the current usage status of the business channel key is already used, the home terminal and the business platform are notified to abolish the business channel key, and the home terminal terminates the connection channel with the business platform, and sends a new business channel key to the home terminal and the business platform through the key management service module, so that the terminal re-establishes the data channel with the key management service module and the business platform according to the new business channel key.
6. The terminal key management method according to claim 1, characterized in that: The method further comprises: If the key management service module receives the management key update request sent by the terminal, it sends the generated new management channel key to the terminal, and after receiving the new management key response sent by the terminal, it annuls the management channel key, closes the management channel established between the key management service module and the terminal based on the management channel key, and establishes a new management channel with the terminal based on the new management channel key; If the key management service module receives a business key update request sent by the terminal, it abolishes the business channel key and sends the generated new business channel key to the terminal and the business platform, so that the terminal re-establishes the data channel with the business platform based on the new business channel key.
7. The terminal key management method according to claim 1, characterized in that: The method further comprises: If the key management service module receives a management key revocation request sent by the terminal, it will reversely confirm the key revocation to the terminal. After receiving the key revocation response from the terminal, it will notify the terminal that the management channel key is revoked and disconnect the management channel with the terminal; If the key management service module receives the service key revocation request sent by the terminal, it will revoke the service channel key and disconnect the data channel between the terminal and the service platform.
8. A terminal key management device, applied to a terminal key management server, characterized in that: The terminal key management service end includes a key management service module, and the device includes: A generating and issuing unit, configured to issue the management channel key generated according to the initialization request and the assigned authorized terminal identifier to the terminal if the key management service module receives an initialization request sent by the terminal; a receiving and terminating unit, configured to terminate the initial management channel established with the terminal if the key management service module receives a key confirmation response sent by the terminal, wherein the initial management channel is a connection channel established based on a preset key; A generating and establishing unit is used for the key management service module to receive a business channel establishment request sent by the terminal based on a management channel, and to send the business channel key generated according to the business channel establishment request to the terminal and the business platform, so that a data channel is established between the terminal and the business platform according to the business channel, wherein the management channel is a channel between the terminal and the key management service module established by using the management channel key.
9. A computer device, characterized in that: The computer device is equipped with a terminal key management server, and the computer device includes a memory and a processor. The memory stores a computer program, and the processor implements the method according to any one of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 7 can be implemented.
