A method for generating a key and a method for transmitting information
By performing target detection and grayscale processing on images to generate complex keys, and then using a satellite navigation and positioning system to transmit the keys, the problem of keys being easily cracked is solved, thus improving the security and accuracy of data transmission.
Patent Information
- Application Number
- CN202210550649.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-18
- Publication Date
- 2024-11-26
- Estimated Expiration
- 2042-05-18
Smart Images

Figure CN115051794B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of data encryption technology, and in particular to a key generation method and an information transmission method. Background Art
[0002] With the development of science and technology and the enhancement of network security awareness, the security of data transmission has become an important concern in today's data transmission field.
[0003] At present, a more conventional way to improve the security of data transmission is to encrypt the original data with a key to form ciphertext data, transmit the ciphertext data to the receiver, and the receiver decrypts the received ciphertext data according to the key to obtain the corresponding original data.
[0004] In the above process, the complexity of key setting is closely related to the security performance of data transmission. If the key setting is relatively simple, the key can be easily cracked. After the illegal user cracks the key, he will decrypt the ciphertext data according to the cracked key and steal the original data, resulting in low security performance of data transmission. Summary of the invention
[0005] The embodiments of the present application provide a key generation method and an information transmission method, which can solve the problem that the key is easily cracked and improve the security of data transmission.
[0006] In a first aspect, an embodiment of the present application provides a key generation method, comprising:
[0007] Receiving a first image captured by a transmitting end;
[0008] Performing target detection on the first image, and if the first image is detected to be a target image, feeding back a judgment instruction to the sending end, wherein the judgment instruction includes an image size standard;
[0009] Receiving a second image that meets the image size standard and is taken by the transmitting end based on the judgment instruction;
[0010] Dividing the second image into a plurality of sub-images according to a preset division rule, and obtaining a target grayscale value corresponding to each sub-image according to a maximum pooling value of the pixel grayscale values in each sub-image;
[0011] A plurality of target grayscale values corresponding to the plurality of sub-images are obtained, and the plurality of target grayscale values are combined with a plurality of random digital password values to generate a key.
[0012] Furthermore, dividing the second image into a plurality of sub-images according to a preset division rule includes:
[0013] Divide the second image into multiple sub-images of the same image size according to a preset division rule
[0014] Furthermore, the target detection includes portrait detection, and the target image includes a portrait image.
[0015] In a second aspect, an embodiment of the present application provides an information transmission method, including:
[0016] Encrypting the second image according to the key generated by the method described above to obtain a ciphertext image;
[0017] The ciphertext image is sent to a receiving end through a core network, and the key is sent to the receiving end through a satellite navigation positioning system, so that the receiving end decrypts the ciphertext image according to the key to obtain the second image.
[0018] Furthermore, the satellite navigation and positioning system includes a Beidou satellite navigation and positioning system.
[0019] Furthermore, the sending of the key to the receiving end via a satellite navigation positioning system includes:
[0020] Processing the key to obtain a corresponding short message;
[0021] The short message is sent to a receiving end via a satellite navigation and positioning system.
[0022] Further, the second image is encrypted according to the key to obtain a ciphertext image, including:
[0023] The second image is encrypted according to the key and the digital image encryption algorithm of the chaotic system to obtain a ciphertext image.
[0024] In a third aspect, an embodiment of the present application provides a key generation device, including:
[0025] A first receiving unit, configured to receive a first image captured by a transmitting end;
[0026] A detection module, configured to perform target detection on the first image, and if the first image is detected to be a target image, feed back a judgment instruction to the sending end, wherein the judgment instruction includes an image size standard;
[0027] A second receiving unit, configured to receive a second image that meets the image size standard and is taken by the sending end based on the judgment instruction;
[0028] a target grayscale value acquisition unit, configured to divide the second image into a plurality of sub-images according to a preset division rule, and obtain a target grayscale value corresponding to each sub-image according to a maximum pooling value of the pixel grayscale values in each sub-image;
[0029] The key generation unit is used to obtain multiple target grayscale values corresponding to multiple sub-images, and combine the multiple target grayscale values with multiple random digital password values to generate a key.
[0030] Furthermore, the target gray value acquisition unit is further configured to divide the second image into a plurality of sub-images of the same image size according to a preset division rule.
[0031] Furthermore, the target detection includes portrait detection, and the target image includes a portrait image.
[0032] In a fourth aspect, an embodiment of the present application provides an information transmission device, including:
[0033] An encryption unit, used to encrypt the second image according to the key generated by the method described above to obtain a ciphertext image;
[0034] The data sending unit is used to send the ciphertext image to the receiving end through the core network, and send the key to the receiving end through the satellite navigation positioning system, so that the receiving end decrypts the ciphertext image according to the key to obtain the second image.
[0035] Furthermore, the satellite navigation and positioning system includes a Beidou satellite navigation and positioning system.
[0036] Furthermore, the data sending unit is further used to process the key to obtain a corresponding short message;
[0037] The short message is sent to a receiving end via a satellite navigation and positioning system.
[0038] Furthermore, the encryption unit is also used to encrypt the second image according to the key and the digital image encryption algorithm of the chaotic system to obtain a ciphertext image.
[0039] In a fifth aspect, an embodiment of the present application provides a key generation device, including:
[0040] memory and one or more processors;
[0041] The memory is used to store one or more programs;
[0042] When the one or more programs are executed by the one or more processors, the one or more processors implement the key generation method as described in the first aspect.
[0043] In a sixth aspect, an embodiment of the present application provides an information transmission device, including:
[0044] memory and one or more processors;
[0045] The memory is used to store one or more programs;
[0046] When the one or more programs are executed by the one or more processors, the one or more processors implement the information transmission method as described in the second aspect.
[0047] In a seventh aspect, an embodiment of the present application provides a storage medium storing computer executable instructions, which, when executed by a computer processor, are used to execute the key generation method as described in the first aspect or the information transmission method as described in the second aspect.
[0048] The embodiment of the present application performs target detection on the first image by receiving the first image captured by the transmitting end. If the first image is detected as a target image, a feedback judgment instruction including the image size standard is given to the transmitting end. The receiving end captures a second image of the corresponding size based on the image size standard in the judgment instruction, and divides the second image into multiple sub-images according to a preset division rule. The target grayscale value corresponding to each sub-image is obtained according to the maximum pooling value of the image grayscale value in each sub-image, and multiple target grayscale values corresponding to multiple sub-images are obtained. The multiple target grayscale values are combined with multiple random digital password values to generate a key. By adopting the above-mentioned technical means, a key can be generated by combining multiple random digital passwords with multiple target grayscale values corresponding to multiple sub-images, thereby increasing the complexity of the key, thereby increasing the difficulty of cracking the key, thereby improving the security of the key, and further improving the security of data transmission. In addition, by generating a key according to the pixel grayscale value of the captured image, a one-time one-key is achieved, which improves the security of the key and further improves the security of data transmission. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] Figure 1 is a flow chart of a key generation method provided in an embodiment of the present application;
[0050] Figure 2 is a flow chart of an information transmission method provided by an embodiment of the present application;
[0051] Figure 3 This is a schematic diagram of an information transmission process provided by an embodiment of the present application;
[0052] Figure 4 is a flow chart of another information transmission method provided in an embodiment of the present application;
[0053] Figure 5 It is a structural schematic diagram of a key generation device provided in an embodiment of the present application;
[0054] Figure 6 is a structural schematic diagram of an information transmission device provided in an embodiment of the present application;
[0055] Figure 7 It is a structural diagram of a key generation device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0056] In order to make the purpose, technical scheme and advantages of the present application clearer, the specific embodiments of the present application are further described in detail below in conjunction with the accompanying drawings. It is understood that the specific embodiments described herein are only used to explain the present application, rather than to limit the present application. It should also be noted that, for the convenience of description, only the part related to the present application but not all the contents are shown in the accompanying drawings. Before discussing the exemplary embodiments in more detail, it should be mentioned that some exemplary embodiments are described as processes or methods depicted as flow charts. Although the flow chart describes each operation (or step) as a sequential process, many of the operations therein can be implemented in parallel, concurrently or simultaneously. In addition, the order of each operation can be rearranged. The process can be terminated when its operation is completed, but it can also have additional steps not included in the accompanying drawings. The process can correspond to a method, a function, a procedure, a subroutine, a subprogram, etc.
[0057] The key generation method and device provided by the present application are intended to generate a key by combining multiple random digital passwords with multiple target grayscale values corresponding to multiple sub-images when generating a key, thereby increasing the complexity of the key, thereby increasing the difficulty of the key being cracked, improving the security of the key, and improving the security of data transmission. In addition, by generating a key according to the pixel grayscale value of the captured image, a one-time one-password is achieved to improve the security of the key and the security of data transmission. Compared with the traditional key generation method, the key setting is usually simple and easy to be cracked. After the illegal user cracks the key, the ciphertext data will be decrypted according to the cracked key to steal the original data, resulting in low security performance of data transmission. Secondly, the traditional key is that multiple pictures or files share one key, resulting in multiple pictures or files being able to obtain after a key is cracked, and the security performance is not high. Based on this, a key generation method of an embodiment of the present application is provided. To solve the problem that the existing key is easy to crack.
[0058] Figure 1 A flowchart of a key generation method provided in an embodiment of the present application is given. The key generation method provided in this embodiment can be executed by a key generation device, which can be implemented by software and / or hardware. The key generation device can be composed of two or more physical entities or one physical entity. Generally speaking, the key generation device can be a terminal device or a terminal system, such as an edge computer system.
[0059] The following description is made by taking the edge computer system as an example of the subject of the key generation method. Figure 1 , the key generation method specifically includes:
[0060] S101: Receive a first image captured by a transmitting end.
[0061] In some confidential units or key places, if there is access permission for the entrants, it is necessary to perform portrait detection on the entrants to verify whether the persons have access permission, so as to determine whether to release them. A transmitting camera is set at the entrance of these confidential units or key places. When the transmitting camera detects that a biological body appears within the field of view of the camera, it shoots the image to obtain a first image, so that the edge computer system can perform subsequent processing and judgment on the first image after receiving the first image shot by the transmitting end. The first image includes a portrait image, an environmental image, or an animal image, etc. It should be noted that there is no uniform restriction on the pixels or image size of the first image here, as long as it can be identified. The pixels or image size of the first image can also be limited to a fixed value according to actual needs.
[0062] S102: Perform target detection on the first image. If the first image is detected as a target image, a judgment instruction is fed back to the sending end, where the judgment instruction includes an image size standard.
[0063] The first image includes a portrait image, an environment image, or an animal image, etc., so it is necessary to perform target detection on the first image to detect and obtain the corresponding target image. Take the case where the target detection is a portrait detection and the target image is a portrait image as an example for illustration. Portrait detection is performed on the first image. If it is detected that the first image is not a portrait image, such as an animal image, no feedback processing is performed. If the first image is detected to be a portrait image, a judgment instruction is fed back to the sending end, wherein the judgment instruction includes an image size standard. The image size standard can be set according to actual conditions. In this embodiment, the image size standard is 1000×1000 pixels as an example for illustration.
[0064] In one embodiment, a first image captured by a transmitting end is received, the first image is input into a preset portrait detection model for portrait detection, and a corresponding detection result is output. If the detection result is not a portrait image, the first image newly captured by the transmitting end is received again, and the newly captured first image is input into a preset portrait detection model for a new round of portrait detection. If the detection result is a portrait image, a judgment instruction is fed back to the transmitting end so that the transmitting end captures a second image of a size corresponding to the image size standard according to the judgment instruction. Among them, the portrait detection model can be preset according to actual conditions, and is not limited in this embodiment.
[0065] S103: Receive a second image that meets the image size standard and is taken by the transmitting end based on the judgment instruction.
[0066] In order to save resources, the first image can only identify the corresponding target and does not need to meet the image size standard. Therefore, after detecting that the first image is the target image, the sender needs to provide a second image that meets the image size standard for subsequent key generation. The sender shoots according to the image size standard in the judgment instruction to obtain the corresponding second image. The size of the obtained second image is the size corresponding to the image size standard, so that the image can be divided according to the size later.
[0067] S104: Divide the second image into a plurality of sub-images according to a preset division rule, and obtain a target grayscale value corresponding to each sub-image according to a maximum pooling value of the pixel grayscale values in each sub-image.
[0068] The preset division rule can be set according to the actual situation. For example, the division rule can be preset according to the number of pixels, or according to the image size. In this embodiment, the preset division rule is used as an example to illustrate the division according to the preset rule based on the image size. The second image is divided into multiple sub-images of the same image size according to the preset division rule, and the target grayscale value corresponding to each image is obtained according to the maximum pooling value of the pixel grayscale value in each image. The target grayscale value is used for the subsequent generation of the key.
[0069] In one embodiment, the image size is divided according to the preset division rule as an example. Taking the image size standard of 1000×1000 pixels as an example, the second image with the standard image size of 1000×1000 pixels is received, wherein when the received second image is a color image, the second image is converted into a grayscale image before the division process; when the received second image is a grayscale image, the second image is directly divided. According to the preset division rule, the second image is divided into a plurality of identical 25×25 pixel sub-images, and the pixel grayscale value in each 25×25 pixel sub-image is obtained, wherein the pixel grayscale value is an integer between 0-255, and the maximum pooling value of the pixel grayscale value is obtained, and the target grayscale value corresponding to each 25×25 pixel sub-image is obtained. Therefore, the target grayscale value of the 40×40 matrix can be obtained. The target grayscale value corresponding to each 25×25 pixel sub-image obtained is used for subsequent key generation.
[0070] S105 , obtaining a plurality of target grayscale values corresponding to a plurality of sub-images, and combining the plurality of target grayscale values with a plurality of random digital password values to generate a key.
[0071] In one embodiment, taking the image size standard of 1000×1000 pixels as an example, the target grayscale value of a 40×40 matrix is obtained through the above implementation process. The target grayscale values of the 40×40 matrix corresponding to the multiple sub-images are obtained to obtain a first key composed of 1600 target grayscale values. In order to improve the security of the key, a final second key can be generated by combining multiple random digital passwords. Taking the random digital password as an 8-digit digital password as an example, the 8-digit digital password is combined with the 1600-digit first key to obtain a final key composed of 1608 digits. The 1608-digit key obtained by the above implementation method is extremely unlikely to be cracked, thereby improving the security of the key.
[0072] In one embodiment, a first image captured by a transmitting end is received, and the first image is input into a preset portrait detection model. The process of performing portrait detection in the portrait detection model includes: extracting 2000 region proposals where objects may exist from the input first image according to a region proposal algorithm, packaging the image regions of different shapes and sizes corresponding to the extracted region proposals into a fixed-size convolutional neural network (CNN) input, extracting features from these packaged inputs using a convolutional neural network, and performing corresponding label marking to obtain "feature-label" data, and sending the "feature-label" data to a support vector machine (SVM) specified by the corresponding category for recognition, thereby outputting a judgment result. When the judgment result is that it is not a portrait image, the first image newly captured by the transmitting end is received again, and the first image is input into the above-mentioned portrait detection model for a new round of portrait detection. When the judgment result is that it is a portrait image, a judgment instruction is fed back to the transmitting end, wherein the judgment instruction includes an image size standard of 1000×1000 pixels. The size of 1000×1000 pixels indicates that there are 1000 rows of pixels in the image, and each row has 1000 pixels. After the sending end receives the judgment instruction, the sending end captures the portrait image in the camera field of view according to the image size standard in the judgment instruction, and forms a second image of a standard size of 1000×1000 pixels. The sending end sends the second image to the edge computer system. After receiving the second image, the edge computer system converts the second image into a grayscale image, divides the second image into multiple identical 25×25 pixel sub-images according to the preset division rule, obtains the pixel grayscale value in each 25×25 pixel sub-image, where the pixel grayscale value is an integer between 0-255, and obtains the maximum pooling value of the pixel grayscale value to obtain the target grayscale value corresponding to each 25×25 pixel sub-image. Therefore, the target grayscale value of the 40×40 matrix can be obtained. According to the target grayscale values of the 40×40 matrix corresponding to the obtained multiple sub-images, the first key consisting of 1600 target grayscale values is obtained. In order to improve the security of the key, the final second key can be generated by combining multiple random digital passwords. Taking the random digital password as an 8-digit password as an example, the 8-digit password is combined with the 1600-digit first key to obtain a final key composed of 1608 digits. The 1608-digit key obtained by the above implementation method has a very low possibility of being cracked, thereby improving the security of the key.
[0073] In the above, by receiving the first image captured by the transmitting end, target detection is performed on the first image. If the first image is detected as a target image, a feedback judgment instruction including the image size standard is given to the transmitting end. The receiving end captures a second image of the corresponding size based on the image size standard in the judgment instruction. The second image is divided into multiple sub-images according to a preset division rule. The target grayscale value corresponding to each sub-image is obtained according to the maximum pooling value of the image grayscale value in each sub-image, and multiple target grayscale values corresponding to multiple sub-images are obtained. The multiple target grayscale values are combined with multiple random digital password values to generate a key. By adopting the above technical means, a key can be generated by combining multiple random digital passwords with multiple target grayscale values corresponding to multiple sub-images, thereby increasing the complexity of the key, thereby increasing the difficulty of cracking the key, thereby improving the security of the key, and further improving the security of data transmission. In addition, by generating a key according to the pixel grayscale value of the captured image, a one-time one-key is achieved, which improves the security of the key and further improves the security of data transmission.
[0074] On the other hand, refer to Figure 2 , provides an information transmission method according to an embodiment of the present application, the information transmission method is executed by the above-mentioned edge computer system, and the information transmission method includes:
[0075] S201. Encrypt the second image according to the key generated by the key generation method described above to obtain a ciphertext image.
[0076] In order to keep the transmission data information confidential, the original image or original data can be encrypted to obtain the corresponding ciphertext data for transmission. After being illegally obtained, the illegal user will not be able to directly steal the original data or original image because the data has been encrypted. In this embodiment, the second image to be transmitted can be encrypted according to the key generated by the key generation method described above and the digital image encryption algorithm of the chaotic system to obtain a ciphertext image, so as to encrypt the second image and improve the security of information transmission.
[0077] S202: Send the ciphertext image to a receiving end through a core network, and send the key to the receiving end through a satellite navigation positioning system, so that the receiving end decrypts the ciphertext image according to the key to obtain the second image.
[0078] Based on the encryption of the second image to be transmitted to obtain the ciphertext image, the corresponding ciphertext image can be transmitted to the receiving end through the public channel of the core network. Although the data transmitted through the public channel in the core network is relatively easy to be intercepted, the ciphertext image based on the transmission is encrypted, so after the ciphertext image is stolen, the original image cannot be stolen due to the lack of the key, thereby ensuring the security of the transmission. As for the transmission of the key, it is transmitted through a satellite navigation and positioning system that is difficult to intercept, so as to improve the security of information transmission. At the same time, because the satellite navigation and positioning system has the advantages of wide coverage and accurate positioning, the key is transmitted through the satellite navigation and positioning system, which improves the accuracy of data transmission. After the receiving end receives the ciphertext image through the core network and the key through the satellite navigation and positioning system, it decrypts the ciphertext data through the key to obtain the corresponding second image.
[0079] In one embodiment, in the early 1960s, researchers proposed the Doppler effect, which can be used to determine the position of a point on the earth's surface through the position of the satellite. Based on this, researchers developed a "naval satellite navigation system" for warship navigation based on the principle of the Doppler effect. The system is also called the meridian satellite navigation system. Afterwards, with the rapid development of satellite navigation and positioning systems, there are four major satellite navigation and positioning systems in the world, namely the GPS system of the United States, the GLONASS system of Russia, the Galileo system of Europe, and the Beidou satellite navigation and positioning system of China. Among the four major satellite navigation and positioning systems, the Beidou satellite navigation and positioning system has a unique short message communication service function compared with the other three satellite navigation and positioning systems. The short message communication service function can provide a short message communication service with a single communication capacity of 1,000 Chinese characters or 14,000 bits for China and the surrounding areas, or can provide a global short message communication service with a single communication capacity of 40 Chinese characters or 560 bits for the global region. Therefore, the Beidou satellite navigation and positioning system has become a more important satellite navigation and positioning system in the world. Therefore, in this embodiment, the satellite navigation and positioning system adopted is the Beidou satellite navigation and positioning system.
[0080] In one embodiment, the key transmission is performed through the Beidou satellite navigation and positioning system as an example. The key is processed to obtain a corresponding short message. The key is sent to the receiving end through the satellite navigation and positioning system in the form of a short message. The 1608-digit key data volume obtained by the above-mentioned key generation method is 12864 bits, which is less than the 14000 bits of data volume of the Beidou short message communication service, thereby achieving the goal of increasing the length of the key generation as much as possible while improving the security of the key and reducing the possibility of the key being cracked.
[0081] Figure 3 This is a schematic diagram of an information transmission process provided by an embodiment of the present application, referring to Figure 3, the equipment in the transmission process includes: a sending end 11, a wireless router 12 (5G CPE), a 5G base station 13, an edge computing system 14 (MEC), a Beidou satellite 15 (GEO satellite), a ground central station 16 (MCC) and a receiving end 17. Among them, the edge computing system 14 includes a portrait judgment server 141. Among them, the sending end 11 is connected to the wireless router 12 and the Beidou satellite 15, the wireless router 12 is connected to the 5G base station 13, the 5G base station 13 is connected to the portrait judgment server 141, and the edge computing system 14 is connected to the receiving end 17. It can be selected that the edge computing system 14 is connected to the receiving end 17 by wire through an optical fiber. The Beidou satellite 15 is connected to the ground central station 16 and the receiving end 17. The sending end 11 is a short message sending end 11, and the sending end 11 includes a camera device, such as a camera. The transmitting end 11, the wireless router 12, the 5G base station 13, and the edge computing system 14 form a directional transmission, and other third-party devices cannot obtain the information that the edge computing system 14 forms 5G transmission to the transmitting end 11. The key is generated by the edge computing system 14, and after the key is generated, the key is transmitted to the transmitting end 11 through the 5G base station 13 and the wireless router 12. The key is transmitted to the Beidou satellite 15 in the form of a short message through the transmitting end 11, and the key is transmitted to the receiving end 17 through the Beidou satellite 15. Since the transmission through 5G wireless communication is carried out through the public network, it is easy to be stolen. Therefore, the edge computing system 14 cannot directly transmit the key to the receiving end 17 through 5G wireless communication. The edge computing system 14 transmits the key to the receiving end 17 through the Beidou satellite 15, which has higher security performance than optical fiber transmission or 5G wireless communication transmission, which improves the security of key transmission, thereby reducing the possibility of key theft, and thus improving the security of information transmission. In addition, Beidou satellite 15 also has a point-to-point transmission feature. The transmission of keys through Beidou satellite 15 realizes point-to-point transmission of keys and improves the accuracy of data transmission.
[0082] Figure 4 is a flowchart of another information transmission method provided in an embodiment of the present application, referring to Figure 3 and Figure 4, the information transmission method includes: S401, when the camera of the sending end 11 captures an image, a first image is captured and the first image is sent to the wireless router 12. S402, the wireless router 12 transmits the received first image to the 5G base station 13. S403, the 5G base station transmits the received first image to the portrait judgment server 141 deployed in the edge computing system 14. S404, the portrait judgment server 141 performs portrait detection on the first image, and after detecting the portrait, sends a judgment instruction to the 5G base station, wherein the judgment instruction includes an image size standard. S405, the 5G base station transmits the judgment instruction to the wireless router 12. S406, the wireless router 12 sends the judgment instruction to the sending end 11, so that the sending end 11 controls the camera to capture the corresponding second image according to the image size standard in the judgment instruction. S407, the edge computing system 14 receives the second image captured by the camera of the sending end 11, and generates a corresponding key according to the above steps S101-S105. S408, the edge computing system 14 transmits the key to the sending end 11, the sending end 11 processes the received key to obtain the corresponding Beidou short message, and the sending end 11 sends the Beidou short message to the Beidou satellite 15. The edge computing system 14 encrypts the second image with the key to obtain a ciphertext image, and transmits the ciphertext image to the receiving end 17 through the optical fiber. S409, the Beidou satellite 15 sends the Beidou short message corresponding to the key to the ground center station 16, so that the ground center station 16 can check the user legitimacy of the sending end 11. S410, after the ground center station 16 determines that the sending end 11 is a legitimate user, the Beidou short message is broadcasted to the receiving end 17 by satellite through the Beidou satellite 15. S411, after the receiving end 17 receives the short message broadcast by the Beidou satellite 15, it obtains the corresponding key, and uses the key to decrypt the received ciphertext image to obtain a plaintext image, which is the second image. After the plaintext image is decrypted at the receiving end 17, it is displayed on the corresponding display so that the auditor can check whether the plaintext image is an authorized person image. The above information transmission method uses the key generated by the image features to encrypt and decrypt the image, which has the characteristic of one-time one-key. Using the timestamp of the Beidou satellite 15 navigation and positioning system, the key generation time and the ciphertext image generation time are almost synchronized, further improving the security of the transmitted data.
[0083] In one embodiment, the above-mentioned key generation method and information transmission method can be used in access scenarios of certain highly confidential units. For example, the data room of a highly confidential unit is only accessible to limited personnel. In the deep mountains and old forests built by the unit, an edge computing system (MEC) is correspondingly configured to execute the above-mentioned key generation method or the above-mentioned information transmission method. The edge computing system can enable personnel in the area to communicate using confidential terminals. The edge computing system of the unit accesses the core network through a 5G base station or a priority optical fiber and is connected to the receiving end through the core network. The unit has set up a portrait judgment server in the core computer room, and a transmitting end is set at the personnel channel, and a camera device is correspondingly set at the transmitting end. Among them, the edge computing system includes a portrait judgment server. In the unit, the edge computing system and the transmitting end realize directional communication transmission, and other third-party devices cannot obtain the information transmitted to the transmitting end by the edge computing system. The transmitting end can communicate directly with the Beidou satellite, and the transmitting end forms a directional communication with the edge computing system through a router and a 5G base station. The camera device of the transmitting end set at the personnel channel captures the image to obtain the first image, and the first image is subjected to portrait detection through the implementation process of the above steps S101-S102. When a person needs to visit the data room, the camera device set at the personnel channel captures the first image of the person to be visited, and through the implementation process of the above steps S101-S102, the first image can be detected as a portrait image, and it is judged to meet the preset target image, and the corresponding key is generated through the implementation process of the above steps S103-S105. The edge computing system encrypts the second image with the key to obtain a ciphertext image, and sends the ciphertext image to the receiving end through the core network. The edge computing system transmits the key to the transmitting end through the router and the 5G base station, and the transmitting end sends the key to the receiving end in the form of a short message through the Beidou satellite. The receiving end decrypts the ciphertext image according to the received key to obtain a plaintext image, that is, the second image, so that the corresponding reviewer of the receiving end can decide whether to authorize the person requesting to access the data room to allow access. In this embodiment, the portrait judgment server only determines whether it is a portrait detection, and does not store portrait information. The camera device at the sending end is only responsible for collecting and sending data, and does not retain portrait information. Through the above implementation process, the highly confidential unit can achieve personnel control and meet the requirements of personnel information confidentiality.
[0084] In the above, by receiving the first image captured by the transmitting end, target detection is performed on the first image. If the first image is detected as a target image, a feedback judgment instruction including the image size standard is given to the transmitting end. The receiving end captures a second image of the corresponding size based on the image size standard in the judgment instruction. The second image is divided into multiple sub-images according to a preset division rule. The target grayscale value corresponding to each sub-image is obtained according to the maximum pooling value of the image grayscale value in each sub-image, and multiple target grayscale values corresponding to multiple sub-images are obtained. The multiple target grayscale values are combined with multiple random digital password values to generate a key. By adopting the above technical means, a key can be generated by combining multiple random digital passwords with multiple target grayscale values corresponding to multiple sub-images, thereby increasing the complexity of the key, thereby increasing the difficulty of cracking the key, thereby improving the security of the key, and further improving the security of data transmission. In addition, by generating a key according to the pixel grayscale value of the captured image, a one-time one-key is achieved, which improves the security of the key and further improves the security of data transmission.
[0085] Based on the above embodiments, Figure 5 A schematic diagram of the structure of a key generation device provided in an embodiment of the present application. Figure 5 The key generation device provided in this embodiment specifically includes: a first receiving unit 21, a detection module 22, a second receiving unit 23, a target gray value acquisition unit 24 and a key generation unit 25.
[0086] The first receiving unit 21 is used to receive a first image captured by a transmitting end;
[0087] The detection module 22 is used to perform target detection on the first image, and if the first image is detected to be a target image, a judgment instruction is fed back to the sending end, wherein the judgment instruction includes an image size standard;
[0088] A second receiving unit 23, configured to receive a second image that meets the image size standard and is taken by the sending end based on the judgment instruction;
[0089] The target gray value acquisition unit 24 is used to divide the second image into a plurality of sub-images according to a preset division rule, and obtain a target gray value corresponding to each sub-image according to a maximum pooling value of the pixel gray values in each sub-image;
[0090] The key generation unit 25 is used to obtain a plurality of target grayscale values corresponding to a plurality of sub-images, and combine the plurality of target grayscale values with a plurality of random digital password values to generate a key.
[0091] Furthermore, the target gray value acquisition unit 24 is further configured to divide the second image into a plurality of sub-images of the same image size according to a preset division rule.
[0092] Furthermore, the target detection includes portrait detection, and the target image includes a portrait image.
[0093] The key generation device provided in the embodiment of the present application can be used to execute the key generation method provided in the above embodiment, and has corresponding functions and beneficial effects.
[0094] Based on the above embodiments, Figure 6 This is a schematic diagram of the structure of an information transmission device provided in an embodiment of the present application. Figure 6 The information transmission device provided in this embodiment specifically includes: an encryption unit 31 and a data sending unit 32.
[0095] An encryption unit 31 is used to encrypt the second image according to the key generated by the method described above to obtain a ciphertext image;
[0096] The data sending unit 32 is used to send the encrypted image to the receiving end through the core network, and send the key to the receiving end through the satellite navigation positioning system, so that the receiving end decrypts the encrypted image according to the key to obtain the second image.
[0097] Furthermore, the satellite navigation and positioning system includes a Beidou satellite navigation and positioning system.
[0098] Furthermore, the data sending unit is further used to process the key to obtain a corresponding short message;
[0099] The short message is sent to a receiving end via a satellite navigation and positioning system.
[0100] Furthermore, the encryption unit 31 is also used to encrypt the second image according to the key and the digital image encryption algorithm of the chaotic system to obtain a ciphertext image.
[0101] In the above, by receiving the first image captured by the transmitting end, target detection is performed on the first image. If the first image is detected as a target image, a feedback judgment instruction including the image size standard is given to the transmitting end. The receiving end captures a second image of the corresponding size based on the image size standard in the judgment instruction. The second image is divided into multiple sub-images according to a preset division rule. The target grayscale value corresponding to each sub-image is obtained according to the maximum pooling value of the image grayscale value in each sub-image, and multiple target grayscale values corresponding to multiple sub-images are obtained. The multiple target grayscale values are combined with multiple random digital password values to generate a key. By adopting the above technical means, a key can be generated by combining multiple random digital passwords with multiple target grayscale values corresponding to multiple sub-images, thereby increasing the complexity of the key, thereby increasing the difficulty of cracking the key, thereby improving the security of the key, and further improving the security of data transmission. In addition, by generating a key according to the pixel grayscale value of the captured image, a one-time one-key is achieved, which improves the security of the key and further improves the security of data transmission.
[0102] The information transmission device provided in the embodiment of the present application can be used to execute the information transmission method provided in the above embodiment, and has corresponding functions and beneficial effects.
[0103] The present application embodiment provides a key generation device, referring to Figure 7 , the key generation device includes: a processor 41, a memory 42, a communication module 43, an input device 44 and an output device 45. The number of processors in the key generation device can be one or more, and the number of memories in the key generation device can be one or more. The processor, memory, communication module, input device and output device of the key generation device can be connected through a bus or other means.
[0104] The memory 42, as a computer-readable storage medium, can be used to store software programs, computer executable programs and modules, such as program instructions / modules corresponding to the key generation method described in any embodiment of the present application (for example, the first receiving unit, the detection module, the second receiving unit, the target gray value acquisition unit and the key generation unit in the key generation device, or the encryption unit and the data sending unit in the information transmission device). The memory may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function; the storage data area may store data created according to the use of the device, etc. In addition, the memory may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some instances, the memory may further include a memory remotely arranged relative to the processor, and these remote memories may be connected to the device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network and a combination thereof.
[0105] The communication module 43 is used for data transmission.
[0106] The processor 41 executes various functional applications and data processing of the device by running software programs, instructions and modules stored in the memory, that is, implements the above-mentioned key generation method.
[0107] The input device 44 may be used to receive input digital or character information and generate key signal input related to user settings and function control of the device. The output device 45 may include a display device such as a display screen.
[0108] The key generation device provided above can be used to execute the key generation method provided in the above embodiment, and has corresponding functions and beneficial effects.
[0109] An embodiment of the present application also provides a storage medium storing computer executable instructions, which are used to execute a key generation method when executed by a computer processor. The key generation method includes: receiving a first image taken by a sending end; performing target detection on the first image, and if the first image is detected to be a target image, feeding back a judgment instruction to the sending end, wherein the judgment instruction includes an image size standard; receiving a second image that meets the image size standard and is taken by the sending end based on the judgment instruction; dividing the second image into multiple sub-images according to a preset division rule, and obtaining a target grayscale value corresponding to each sub-image according to the maximum pooling value of the pixel grayscale values in each sub-image; obtaining multiple target grayscale values corresponding to the multiple sub-images, and combining the multiple target grayscale values with multiple random digital password values to generate a key.
[0110] An embodiment of the present application also provides a storage medium storing computer executable instructions, which, when executed by a computer processor, are used to execute an information transmission method, the information transmission method comprising: encrypting a second image according to a key generated by the key generation method described above to obtain a ciphertext image; sending the ciphertext image to a receiving end through a core network, and sending the key to the receiving end through a satellite navigation positioning system, so that the receiving end decrypts the ciphertext image according to the key to obtain the second image.
[0111] Storage medium - any of various types of memory devices or storage devices. The term "storage medium" is intended to include: installation media, such as CD-ROM, floppy disk or tape device; computer system memory or random access memory, such as DRAM, DDR RAM, SRAM, EDO RAM, Rambus RAM, etc.; non-volatile memory, such as flash memory, magnetic media (such as hard disk or optical storage); registers or other similar types of memory elements, etc. Storage media may also include other types of memory or combinations thereof. In addition, the storage medium may be located in the first computer system in which the program is executed, or may be located in a different second computer system, which is connected to the first computer system via a network (such as the Internet). The second computer system can provide program instructions to the first computer for execution. The term "storage medium" may include two or more storage media residing in different locations (for example, in different computer systems connected by a network). The storage medium may store program instructions (for example, embodied as a computer program) that can be executed by one or more processors.
[0112] Of course, the computer executable instructions of a storage medium storing computer executable instructions provided in an embodiment of the present application are not limited to the key generation method described above, and can also execute related operations in the key generation method provided in any embodiment of the present application.
[0113] The key generation apparatus, storage medium and key generation device provided in the above embodiments can execute the key generation method provided in any embodiment of the present application. For technical details not described in detail in the above embodiments, please refer to the key generation method provided in any embodiment of the present application.
[0114] The above are only preferred embodiments of the present application and the technical principles used. The present application is not limited to the specific embodiments described herein, and various obvious changes, readjustments and substitutions that can be made by those skilled in the art will not deviate from the scope of protection of the present application. Therefore, although the present application is described in more detail through the above embodiments, the present application is not limited to the above embodiments, and may include more other equivalent embodiments without departing from the concept of the present application, and the scope of the present application is determined by the scope of the claims.
Claims
1. A key generation method, characterized in that: For edge computing systems, including: receiving a first image captured by a transmitting end; Performing target detection on the first image, and if the first image is detected to be a target image, feeding back a judgment instruction to the sending end, wherein the judgment instruction includes an image size standard; receiving a second image that meets the image size standard and is captured by the transmitting end based on the judgment instruction; Dividing the second image into a plurality of sub-images according to a preset division rule, and obtaining a target grayscale value corresponding to each sub-image according to a maximum pooling value of pixel grayscale values in each sub-image; A plurality of target grayscale values corresponding to the plurality of sub-images are obtained, and the plurality of target grayscale values are combined with a plurality of random digital password values to generate a key.
2. The key generation method according to claim 1, wherein: The step of dividing the second image into a plurality of sub-images according to a preset division rule includes: The second image is divided into a plurality of sub-images of the same image size according to a preset division rule.
3. The key generation method according to claim 1, wherein: The target detection includes portrait detection, and the target image includes a portrait image.
4. An information transmission method, characterized in that: For edge computing systems, including: encrypting the second image using the key generated by the method according to any one of claims 1 to 3 to obtain a ciphertext image; The ciphertext image is sent to a receiving end through a core network, and the key is sent to the receiving end through a satellite navigation positioning system, so that the receiving end decrypts the ciphertext image according to the key to obtain the second image.
5. The information transmission method according to claim 4, characterized in that: The satellite navigation and positioning system includes the Beidou satellite navigation and positioning system.
6. The information transmission method according to claim 5, characterized in that: The step of sending the key to a receiving end via a satellite navigation and positioning system includes: Processing the key to obtain a corresponding short message; The short message is sent to a receiving end via a satellite navigation and positioning system.
7. The information transmission method according to claim 4, characterized in that: The second image is encrypted according to the key to obtain a ciphertext image, including: The second image is encrypted according to the key and the digital image encryption algorithm of the chaotic system to obtain a ciphertext image.
8. A key generation device, characterized in that: include: A first receiving unit, configured to receive a first image captured by a transmitting end; a detection module, configured to perform target detection on the first image, and if the first image is detected to be a target image, feed back a judgment instruction to the transmitting end, wherein the judgment instruction includes an image size standard; A second receiving unit is configured to receive a second image that meets the image size standard and is taken by the transmitting end based on the judgment instruction; a target grayscale value acquisition unit, configured to divide the second image into a plurality of sub-images according to a preset division rule, and obtain a target grayscale value corresponding to each sub-image according to a maximum pooling value of pixel grayscale values in each sub-image; The key generation unit is used to obtain multiple target grayscale values corresponding to multiple sub-images, and combine the multiple target grayscale values with multiple random digital password values to generate a key.
9. A key generation device, characterized in that: include: memory and one or more processors; The memory is used to store one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 3.
10. A storage medium storing computer executable instructions, characterized in that: When the computer executable instructions are executed by a processor, the computer executable instructions are used to perform the method according to any one of claims 1 to 7.
