Method for ensuring IoT communication security based on dynamic creation of device shadows

By dynamically creating device shadows and using device fingerprints to generate unique trust codes and signature protocols, the problem of IoT device shadows being easily tampered with is solved, trusted connections and information synchronization between device shadows and IoT devices are achieved, and communication security is improved.

CN115987556BActive Publication Date: 2025-09-16CHONGQING TELECOM SYST INTEGRATION CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211501286.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-28
Publication Date
2025-09-16
Estimated Expiration
2042-11-28

AI Technical Summary

Technical Problem

The device shadow of IoT devices can be easily tampered with or hijacked maliciously, resulting in the issuance of illegal instructions and poor security.

Method used

By dynamically creating a device shadow, using the device fingerprint to generate a unique trust code, and combining signature protocols and authentication, we ensure the trusted connection and information synchronization between the device shadow and the IoT device.

Benefits of technology

It effectively prevents device shadows from being tampered with, ensures the security and reliability of information transmission, avoids the issuance of illegal instructions, and improves the security of IoT communications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115987556B_ABST
    Figure CN115987556B_ABST
Patent Text Reader

Abstract

The present application provides a method for ensuring the security of IoT communications based on the dynamic creation of shadow devices, including three steps: dynamic creation of device shadows, interconnection between IoT devices and device shadows, and information synchronization; dynamic creation of device shadows includes: step A1: uploading necessary device fingerprints; step A2: obtaining a unique first authorization code for the IoT device; step A3: obtaining a second authorization code; step A4: feedback to the IoT device as a unique credential; step A5: establishing a trusted connection based on the second authorization code. This method ensures the security and reliability of device shadow documents by dynamically creating device shadows, making them difficult to tamper with; at the same time, through authentication and verification, it ensures that IoT devices and device shadows are trustworthy, thereby strengthening the security of device shadows.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of Internet of Things, and in particular to a method for ensuring Internet of Things communication security based on dynamically creating device shadows. Background Art

[0002] The combination of the new generation of Internet of Things, wireless broadband networks, the Internet, telecommunications networks and other networks, accompanied by the high integration of information technology and the comprehensive application of information resources, has become an important factor in solving key urban social, economic, cultural, and environmental issues, and is a new direction for future urban development.

[0003] Among the many IoT devices, device shadows, as the projection of IoT devices in the digital world, greatly facilitate the management and monitoring of IoT devices. Especially in scenarios where the edge network is unstable, they play an important role in improving the stability, availability, and reliability of devices and reducing network and device pressure.

[0004] Essentially, a device shadow is a JSON document used to store information about the device's reported status and the application's expected status. Each device has one and only one device shadow. If the device is offline or in an abnormal state, the IoT service cannot send configurations to the device through commands. In this case, the configuration to be sent can be set to the device shadow. When the device comes back online, the device shadow will send the configuration to the device, allowing the device to receive IoT service commands. In addition, the IoT service can also call this interface to modify the configuration information that needs to be sent to the device on the device shadow. However, when an attacker maliciously simulates or hijacks the device shadow, there is a possibility of tampering with or sending illegal commands to the physical device, causing the physical device to receive tampered information or illegal commands, making it unable to truly and effectively receive and execute IoT service commands, resulting in poor security. Summary of the Invention

[0005] In response to the problems existing in the above-mentioned prior art, the purpose of the present invention is to provide a method for ensuring the security of IoT communications based on dynamically creating device shadows. This method ensures the security and reliability of device shadow documents by dynamically creating device shadows, and prevents them from being tampered with. At the same time, through authentication and certification, it ensures that IoT devices and device shadows are trustworthy, thereby strengthening the security of device shadows.

[0006] The purpose of the present invention is achieved through the following technical solutions:

[0007] A method for ensuring Internet of Things communication security based on dynamically creating shadow devices, characterized by:

[0008] It includes three steps: dynamically creating device shadows, interconnecting IoT devices with device shadows, and synchronizing information;

[0009] The method for dynamically creating a device shadow is as follows:

[0010] Step A1: When an IoT device registers to the IoT platform for the first time, upload the necessary device fingerprint;

[0011] Step A2: The IoT platform's credit service uses the device fingerprint of the IoT device and a credit algorithm to obtain the unique first credit code of the IoT device.

[0012] Step A3: Create a device shadow corresponding to the IoT device based on the first authorization code, and obtain a second authorization code for the new device shadow;

[0013] Step A4: The IoT platform's trust service feeds the second trust code of the device shadow back to the IoT device, which serves as the only credential for connection and bidirectional information synchronization between the IoT device and the device shadow.

[0014] Step A5: The IoT device establishes a trusted connection with the device shadow based on the second trust code.

[0015] For further optimization, the device fingerprint in step A1 includes a combination of a pre-programmed device ID and multiple attributes such as device model, device name, device shape and size, device color, and device function.

[0016] For further optimization, the first credit code in step A2 includes a credit ID, a signature protocol, and an IoT device fingerprint signature. The credit ID is generated by the IoT server and is unique across the entire network. The signature protocol is an agreed method for signing communication information. The IoT device signature is used to compare the authenticity of the device.

[0017] For further optimization, the specific steps of using the credit algorithm in step A2 to obtain the unique first credit code of the IoT device are as follows:

[0018] Step A21: First, the IoT platform trust service generates a trust ID for the IoT device, and then assembles the trust ID, signature agreement, and IoT fingerprint to obtain an assembled string.

[0019] Step A22: Then, two numbers are randomly generated in the assembled string using a random number generation function;

[0020] Step A23: Determine whether the two random numbers are both prime numbers. If so, generate two prime numbers p and q and execute step A24. If not, return to execute step A22.

[0021] Step A24: Under the premise of ensuring that the two prime numbers p and q are not equal, obtain the public key n, n = p * q;

[0022] Step A25: Calculate the Euler function φ(n) of n:

[0023] φ(n)=(p-1)(q-1);

[0024] Repeatedly generate an integer e randomly again, such that 1<e<φ(n) and e is relatively prime to φ(n);

[0025] Step A26: Based on e and φ(n), a private key d is generated by d·e=1modφ(n);

[0026] Step A27: Destroy p and q, and use (n, e) as the public key and d as the private key.

[0027] For further optimization, step A3 is specifically as follows: generate a new fingerprint signature of the device shadow based on the first trust code, append the uplink and downlink sequence numbers to form a second trust code; wherein, the uplink and downlink sequence numbers are used for information transaction control to ensure information synchronization consistency processing and replay attacks; the initial uplink sequence number and downlink sequence number are both set to 0; each time information is synchronized, the uplink sequence number or the downlink sequence number is increased by 1.

[0028] For further optimization, the specific steps for interconnecting the IoT devices and device shadows are as follows:

[0029] Step B1: The IoT device randomly connects and requests to upload the IoT device fingerprint, the second authorization code, and the device fingerprint signed by P;

[0030] Step B2: The device shadow server extracts the device fingerprint, fingerprint signature O, and signature protocol P of the device shadow from the second trust code;

[0031] Step B3: The IoT device signs and verifies the device fingerprint. If they match, the device shadow calls the IoT platform's credit service to obtain the first credit code again.

[0032] Step B4: Calculate the signature Q of the first trust code obtained in step B3 according to the signature protocol P, and then compare the signature Q with the signature O. If the signatures match, a connection is established and a one-time token is returned; otherwise, no connection is established.

[0033] For further optimization, the specific steps of information synchronization are:

[0034] Step C1: When the IoT device synchronizes information to the device shadow, it first establishes a connection with the device shadow and obtains a connection token;

[0035] Step C2: Sign the first authorization code using the signature protocol P to generate a signature Q;

[0036] Step C3: Send the token, signature Q and first authorization code obtained through the connection to the device shadow server;

[0037] Step C4: After the device shadow server determines that the token is valid, it cancels the token;

[0038] Step C5: Verify the uplink count, that is, verify the consistency between the token uplink count and the device shadow end data;

[0039] Step C6: The device shadow server updates the device shadow document according to the message;

[0040] Step C7: Update the uplink count, that is, add 1 to the uplink count.

[0041] Preferably, the device shadow server determines the validity of the Token by verifying the message body signature through the server.

[0042] The present invention has the following technical effects:

[0043] This application dynamically creates a device shadow online to avoid the risk of offline process information leakage; at the same time, it dynamically obtains the trust code through the device fingerprint to avoid the potential risk of device counterfeiting. In addition, the IoT server of this application does not store the trust code, effectively avoiding the risk of information leakage on the server side; through the cooperation of the first trust code and the second trust code, a dynamic connection is achieved to avoid the possibility of command tampering or issuing illegal commands to the physical device when the outside world maliciously simulates or hijacks the device shadow, effectively ensuring secure communication between the device shadow and the physical device. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] Figure 1 The figure is a schematic diagram of the process of dynamically creating a device shadow in an embodiment of the present invention.

[0045] Figure 2 The figure is a flow chart of the shadow interconnection between IoT devices and devices in an embodiment of the present invention.

[0046] Figure 3 Schematic diagram of the information synchronization process in an embodiment of the present invention. DETAILED DESCRIPTION

[0047] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only 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 making creative efforts are within the scope of protection of the present invention.

[0048] Example 1:

[0049] like Figures 1 to 3 As shown, a method for ensuring the security of Internet of Things communications based on dynamically creating shadow devices is characterized by:

[0050] It includes three steps: dynamically creating device shadows, interconnecting IoT devices with device shadows, and synchronizing information;

[0051] The method for dynamically creating a device shadow is as follows:

[0052] Step A1: When an IoT device first registers with the IoT platform, it uploads the necessary device fingerprint. The device fingerprint includes a combination of a pre-programmed device ID and multiple attributes, such as the device model, device name, device shape and size, device color, and device function (including at least the device model and device name, for example, a combination of the device model, device name, device shape and size, or a combination of the device model, device name, device color, and device function).

[0053] Step A2: The IoT platform's credit service uses the device fingerprint of the IoT device and a credit algorithm to obtain the unique first credit code of the IoT device.

[0054] The first trust code includes the trust ID, signature protocol and IoT device fingerprint signature. The trust ID is generated by the IoT server and is unique in the entire network; the signature protocol is the agreed communication information signature method; the IoT device signature is used to compare the device authenticity.

[0055] The specific steps to obtain the unique first credit code of the IoT device are:

[0056] Step A21: First, the IoT platform trust service generates a trust ID for the IoT device, and then assembles the trust ID, signature agreement, and IoT fingerprint to obtain an assembled string.

[0057] Step A22: Then, two numbers are randomly generated in the assembled character string using a random number generation function (the random number generation function can adopt an existing function, which can be understood by those skilled in the art);

[0058] Step A23: Determine whether the two random numbers are both prime numbers. If so, generate two prime numbers p and q and execute step A24. If not, return to execute step A22.

[0059] Step A24: Under the premise of ensuring that the two prime numbers p and q are not equal, obtain the public key n, where n = p * q;

[0060] Step A25: Calculate the Euler function φ(n) of n:

[0061] φ(n)=(p-1)(q-1);

[0062] Repeatedly generate an integer e randomly again, such that 1<e<φ(n) and e is relatively prime to φ(n);

[0063] Step A26: Based on e and φ(n), a private key d is generated by d·e=1modφ(n);

[0064] Step A27: Destroy p and q, and use (n, e) as the public key and d as the private key.

[0065] Step A3: Create a device shadow corresponding to the IoT device based on the first authorization code, and obtain a second authorization code for the new device shadow;

[0066] Specifically: a new fingerprint signature of the device shadow is generated based on the first trust code, and the uplink and downlink sequence numbers are appended to form a second trust code; among them, the uplink and downlink sequence numbers are used for information transaction control to ensure information synchronization consistency processing and replay attacks; the initial uplink sequence number and downlink sequence number are both set to 0; each time information is synchronized, the uplink sequence number or downlink sequence number is increased by 1.

[0067] Step A4: The IoT platform's trust service feeds the second trust code of the device shadow back to the IoT device, which serves as the only credential for connection and bidirectional information synchronization between the IoT device and the device shadow.

[0068] Step A5: The IoT device establishes a trusted connection with the device shadow based on the second trust code.

[0069] The specific steps for interconnecting IoT devices and device shadows are as follows:

[0070] Step B1: The IoT device randomly connects and requests to upload the IoT device fingerprint, the second authorization code, and the device fingerprint signed by P;

[0071] Step B2: The device shadow server extracts the device fingerprint, fingerprint signature O, and signature protocol P of the device shadow from the second trust code;

[0072] Step B3: The IoT device signs and verifies the device fingerprint. If they match, the device shadow calls the IoT platform's credit service to obtain the first credit code again.

[0073] Step B4: Calculate the signature Q of the first trust code obtained in step B3 according to the signature protocol P, and then compare the signature Q with the signature O. If the signatures match, a connection is established and a one-time token is returned; otherwise, no connection is established.

[0074] The specific steps for information synchronization are:

[0075] Step C1: When the IoT device synchronizes information to the device shadow, it first establishes a connection with the device shadow and obtains a connection token;

[0076] Step C2: Sign the first authorization code using the signature protocol P to generate a signature Q;

[0077] Step C3: Send the token, signature Q and first authorization code obtained through the connection to the device shadow server;

[0078] Step C4: After the device shadow server determines that the Token is valid, it cancels the Token; the device shadow server determines the validity of the Token by verifying the message body signature on the server.

[0079] Step C5: Verify the uplink count, that is, verify the consistency between the token uplink count and the device shadow end data;

[0080] Step C6: The device shadow server updates the device shadow document according to the message;

[0081] Step C7: Update the uplink count, that is, add 1 to the uplink count.

[0082] Example 2:

[0083] As a further optimization of the solution of the present application, based on Example 1, the authorization code (specifically the first authorization code and the second authorization code) can be burned into the device to improve security.

[0084] At the same time, in addition to the necessary fields, the physical device segment of the device fingerprint can freely extend the attributes to avoid the possibility of brute force enumeration.

[0085] While embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions, and variations may be made to these embodiments without departing from the principles and spirit of the invention, and that the scope of the invention is defined by the appended claims and their equivalents.

Claims

1. A method for ensuring Internet of Things communication security based on dynamically creating shadow devices, characterized by: It includes three steps: dynamically creating device shadows, interconnecting IoT devices with device shadows, and synchronizing information; The method for dynamically creating a device shadow is as follows: Step A1: When an IoT device registers to the IoT platform for the first time, upload the necessary device fingerprint; Step A2: The IoT platform's credit service uses the device fingerprint of the IoT device and a credit algorithm to obtain the unique first credit code of the IoT device. Step A3: Create a device shadow corresponding to the IoT device based on the first authorization code, and obtain a second authorization code for the new device shadow; Step A4: The IoT platform's trust service feeds the second trust code of the device shadow back to the IoT device, which serves as the only credential for connection and bidirectional information synchronization between the IoT device and the device shadow. Step A5: The IoT device establishes a trusted connection with the device shadow based on the second trust code.

2. A method for ensuring Internet of Things communication security based on dynamically creating shadow devices according to claim 1, characterized in that: The first credit code in step A2 includes a credit ID, a signature protocol, and an IoT device fingerprint signature. The credit ID is generated by the IoT server and is unique across the entire network. The signature protocol is an agreed method for signing communication information. The IoT device signature is used to compare device authenticity.

3. A method for ensuring Internet of Things communication security based on dynamically creating shadow devices according to claim 1 or 2, characterized in that: In step A2, the specific steps of obtaining the unique first credit code of the IoT device by using the credit algorithm are as follows: Step A21: First, the IoT platform trust service generates a trust ID for the IoT device, and then assembles the trust ID, signature agreement, and IoT fingerprint to obtain an assembled string. Step A22: Then, two numbers are randomly generated in the assembled string using a random number generation function; Step A23: Determine whether the two random numbers are both prime numbers. If so, generate two prime numbers p and q and execute step A24. If not, return to execute step A22. Step A24: Under the premise of ensuring that the two prime numbers p and q are not equal, obtain the public key n, n=p*q; Step A25: Calculate the Euler function of n : ; Repeatedly generate an integer e randomly so that And e and mutually prime; Step A26: Based on e and and through Generate private key d; Step A27: Destroy p and q, and use (n, e) as the public key and d as the private key.

4. The method for ensuring Internet of Things communication security based on dynamically creating shadow devices according to claim 3, characterized in that: The specific steps of step A3 are as follows: generating a new fingerprint signature of the device shadow based on the first credit code, appending the uplink and downlink sequence numbers to form a second credit code; wherein the uplink and downlink sequence numbers are used for information transaction control to ensure information synchronization consistency processing and replay attack protection; the initial uplink sequence number and downlink sequence number are both set to 0; each time information is synchronized, the uplink sequence number or the downlink sequence number is increased by 1.

5. The method for ensuring Internet of Things communication security based on dynamically creating shadow devices according to claim 1, characterized in that: The specific steps of interconnecting the IoT device and the device shadow are as follows: Step B1: The IoT device randomly connects and requests to upload the IoT device fingerprint, the second authorization code, and the device fingerprint signed by P; Step B2: The device shadow server extracts the device fingerprint, fingerprint signature O, and signature protocol P of the device shadow from the second trust code; Step B3: The IoT device signs and verifies the device fingerprint. If they match, the device shadow calls the IoT platform's credit service to obtain the first credit code again. Step B4: Calculate the signature Q of the first trust code obtained in step B3 according to the signature protocol P, and then compare the signature Q with the signature O. If the signatures match, a connection is established and a one-time token is returned; otherwise, no connection is established.

6. The method for ensuring Internet of Things communication security based on dynamically creating shadow devices according to claim 1, characterized in that: The specific steps of information synchronization are: Step C1: When the IoT device synchronizes information to the device shadow, it first establishes a connection with the device shadow and obtains a connection token; Step C2: Sign the first authorization code using the signature protocol P to generate a signature Q; Step C3: Send the token, signature Q and first authorization code obtained through the connection to the device shadow server; Step C4: After the device shadow server determines that the token is valid, it cancels the token; Step C5: Verify the uplink count, that is, verify the consistency between the token uplink count and the device shadow end data; Step C6: The device shadow server updates the device shadow document according to the message; Step C7: Update the uplink count, that is, add 1 to the uplink count.

Citation Information

Patent Citations

  • Enterprise innovation ability evaluation method and system based on artificial intelligence analysis

    CN114723272A

  • Cloud-based privileged access management

    US20210392142A1