CN115001864A - Communication authentication method and device for intelligent furniture, computer equipment and storage medium - Google Patents
Communication authentication method and device for intelligent furniture, computer equipment and storage medium Download PDFInfo
- Publication number
- CN115001864A CN115001864A CN202210888420.2A CN202210888420A CN115001864A CN 115001864 A CN115001864 A CN 115001864A CN 202210888420 A CN202210888420 A CN 202210888420A CN 115001864 A CN115001864 A CN 115001864A
- Authority
- CN
- China
- Prior art keywords
- hash
- data
- public key
- target data
- ciphertext
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/08—Network architectures or network communication protocols for network security for authentication of entities
- H04L63/0853—Network architectures or network communication protocols for network security for authentication of entities using an additional device, e.g. smartcard, SIM or a different communication terminal
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/04—Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
- H04L63/0428—Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/12—Applying verification of the received information
- H04L63/123—Applying verification of the received information received data contents, e.g. message integrity
Landscapes
- Engineering & Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Computer Hardware Design (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Storage Device Security (AREA)
- Computer And Data Communications (AREA)
Abstract
The application relates to a communication authentication method and device for intelligent furniture, computer equipment and a storage medium. The method comprises the following steps: sending an authentication request to the server so that the server returns combined data obtained by combining the public key and the ciphertext hash; the ciphertext hash is obtained by encrypting the hash of the public key; receiving the combined data, judging whether the public key in the combined data is matched with the ciphertext hash, if so, authenticating the public key in the combined data to obtain an authenticated public key; when data interaction is carried out, calculating the hash of target data, and encrypting the hash of the target data to obtain the ciphertext hash of the target data; encrypting the target data and the ciphertext hash of the target data through the authenticated public key to obtain communication authentication data; and sending the communication authentication data to a server to perform communication authentication on the intelligent furniture based on the communication authentication data. By adopting the method, the safe communication between the intelligent furniture and the cloud server can be ensured when the intelligent furniture is more and the computing power is limited.
Description
Technical Field
The present application relates to the field of digital information transmission technologies, and in particular, to a communication authentication method and apparatus for smart furniture, a computer device, a storage medium, and a computer program product.
Background
With the development of equipment intellectualization, the furniture is also intelligentized and networked. Data recorded by intelligent furniture such as an intelligent seat comprise information related to user privacy such as weight, sitting time and preference, channel safety and identity safety during communication are guaranteed, communication is not monitored by a third party, and the user privacy is prevented from being stolen.
Moreover, the number of devices under the intelligent furniture line is very large, and the requirement on cost control is high, so that the universality and the mass production performance of a safety communication scheme need to be considered during design, and intellectual property protection is performed. In the prior art, the communication safety of the intelligent furniture cannot be ensured completely and reliably while the mass production cost is controlled.
Disclosure of Invention
In view of the above, it is necessary to provide a communication authentication method, apparatus, computer device, computer readable storage medium, and computer program product for smart furniture, which can securely communicate with a cloud server with limited computing power.
In a first aspect, the present application provides a communication authentication method for smart furniture, which is executed by a security chip of the smart furniture, and the method includes:
sending an authentication request to a server so that the server returns combined data obtained by combining a public key and a ciphertext hash; the ciphertext hash is obtained by encrypting the hash of the public key;
receiving the combined data, judging whether a public key in the combined data is matched with a cipher text hash, and if so, authenticating the public key in the combined data to obtain an authenticated public key;
when data interaction is carried out, calculating the hash of target data, and encrypting the hash of the target data to obtain the ciphertext hash of the target data;
encrypting the target data and the ciphertext hash of the target data through the authenticated public key to obtain communication authentication data;
and sending the communication authentication data to the server to perform communication authentication on the intelligent furniture based on the communication authentication data.
In one embodiment, the calculating a hash of the target data and encrypting the hash of the target data to obtain a ciphertext hash of the target data includes:
receiving target data sent by a control unit of the intelligent furniture;
performing hash operation on the target data to obtain a hash of the target data;
and carrying out asymmetric encryption on the hash of the target data to obtain the ciphertext hash of the target data.
In one embodiment, the asymmetrically encrypting the hash of the target data to obtain the ciphertext hash of the target data includes:
carrying out asymmetric encryption on the hash of the target data through a private key of the security chip to obtain a ciphertext hash of the target data;
the private key of the security chip corresponds to the public key of the security chip, and the public key of the security chip is used for performing communication authentication on the intelligent furniture.
In one embodiment, the ciphertext hash in the combined data is obtained by encrypting the hash of the public key according to a private key of the server; the judging whether the public key and the ciphertext hash in the combined data are matched comprises:
splitting the combined data to obtain a public key in the combined data and a ciphertext hash in the combined data;
performing hash operation on the public key in the combined data to obtain a verification hash of the public key in the combined data;
decrypting the ciphertext hash in the combined data through the public key of the server to obtain a plaintext hash corresponding to the ciphertext hash;
and judging whether the verification hash of the public key in the combined data is consistent with the plaintext hash corresponding to the ciphertext hash.
The application also provides a communication authentication method of the intelligent furniture, which is executed by a server and comprises the following steps:
receiving an authentication request sent by a security chip;
in response to the authentication request, sending combined data obtained by combining public keys and ciphertext hashes to the security chip so that the security chip authenticates the public keys in the combined data; the ciphertext hash is obtained by encrypting the hash of the public key;
receiving communication authentication data sent by the security chip; the communication authentication data is obtained by the security chip through the authenticated public key to encrypt the target data and the ciphertext hash of the target data;
analyzing the communication authentication data through a private key matched with the authenticated public key to obtain ciphertext hash of the target data and the target data;
and judging whether the target data is matched with the ciphertext hash of the target data or not to obtain a communication authentication result of the intelligent furniture.
In one embodiment, the sending, to the secure chip in response to the authentication request, combined data obtained by combining a public key and a ciphertext hash includes:
generating a public key and a private key adapted to the public key in response to the authentication request;
carrying out hash operation on the public key to obtain the hash of the public key;
encrypting the hash of the public key based on the private key of the server to obtain a ciphertext hash;
and combining the public key and the ciphertext hash to obtain combined data corresponding to the authentication request.
In one embodiment, the ciphertext hash of the target data is obtained by encrypting the hash of the target data through a private key of the security chip; the determining whether the target data matches the ciphertext hash of the target data includes:
performing hash operation on the target data to obtain a verification hash of the target data;
decrypting the ciphertext hash of the target data based on the public key of the security chip to obtain the plaintext hash of the target data;
and judging whether the verification hash of the target data is matched with the plaintext hash of the target data.
In a second aspect, the present application provides a communication authentication device for smart furniture. The device comprises:
the authentication request sending module is used for sending an authentication request to the server so that the server returns combined data obtained by combining public key hashes and ciphertext hashes; the ciphertext hash is obtained by encrypting the hash of the public key;
the public key authentication module is used for receiving the combined data and judging whether a public key in the combined data is matched with a ciphertext hash or not, if so, the public key in the combined data passes authentication to obtain an authenticated public key;
the data encryption module is used for calculating the hash of target data and encrypting the hash of the target data to obtain the ciphertext hash of the target data when data interaction is carried out;
the communication authentication data generation module is used for encrypting the target data and the ciphertext hash of the target data through the authenticated public key to obtain communication authentication data;
and the communication authentication data sending module is used for sending the communication authentication data to the server so as to carry out communication authentication on the intelligent furniture based on the communication authentication data.
The application also provides a communication authentication device of the intelligent furniture. The device comprises:
the authentication request receiving module is used for receiving an authentication request sent by the security chip;
a public key returning module, configured to send, in response to the authentication request, combined data obtained by combining a public key and a ciphertext hash to the security chip, so that the security chip authenticates the public key in the combined data; the ciphertext hash is obtained by encrypting the hash of the public key;
the communication authentication data receiving module is used for receiving the communication authentication data sent by the security chip; the communication authentication data is obtained by the security chip through the authenticated public key to encrypt the target data and the ciphertext hash of the target data;
the communication authentication data analysis module is used for analyzing the communication authentication data through a private key matched with the authenticated public key to obtain a ciphertext hash of the target data and the target data;
and the communication authentication module is used for judging whether the target data is matched with the ciphertext hash of the target data to obtain a communication authentication result of the intelligent furniture.
In a third aspect, the application also provides a computer device. The computer equipment comprises a memory and a processor, wherein the memory stores a computer program, and the processor realizes the communication authentication of the intelligent furniture when executing the computer program.
In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium has stored thereon a computer program which, when executed by a processor, implements communication authentication of the smart furniture described above.
In a fifth aspect, the present application further provides a computer program product. The computer program product comprises a computer program which, when executed by a processor, implements the steps of communication authentication of the smart furniture described above.
The communication authentication method of the intelligent furniture comprises the steps of sending an authentication request to a server so that the server returns combined data obtained by combining public key and ciphertext hash; the ciphertext hash is obtained by encrypting the hash of the public key, and the request process of the combined data occupies less computing resources; and receiving the combined data, judging whether the public key in the combined data is matched with the ciphertext hash, if so, authenticating the public key in the combined data to obtain an authenticated public key, and judging whether the public key in the combined data is changed in the transmission process through less calculation so as to perform the safety authentication of the public key through less calculation resources. When data interaction is carried out, the hash of the target data is calculated, and the hash of the target data is encrypted to obtain the ciphertext hash of the target data; encrypting the target data and the ciphertext hash of the target data through the authenticated public key to obtain communication authentication data; the communication authentication data of the target data are obtained through less computing resources, the server can directly check through the communication authentication data, whether the target data are changed by a third party in the transmission process is detected, and the communication authentication data are sent to the server so as to carry out communication authentication on the intelligent furniture based on the communication authentication data.
Drawings
FIG. 1 is a diagram of an application environment of a communication authentication method for smart furniture in an embodiment;
FIG. 2 is a flow chart illustrating a communication authentication method for smart furniture according to an embodiment;
FIG. 3 is a flowchart illustrating a communication authentication method for smart furniture according to an embodiment;
FIG. 4 is a diagram of an application environment of communication authentication of smart furniture in another embodiment;
FIG. 5 is a schematic flow chart illustrating temporary storage of a public key for an intelligent furniture in an embodiment;
FIG. 6 is a schematic flow diagram that illustrates data interaction for smart furniture in one embodiment;
FIG. 7 is a block diagram showing the structure of a communication authentication apparatus for smart furniture according to an embodiment;
FIG. 8 is a block diagram showing the structure of a communication authentication apparatus for smart furniture according to an embodiment;
FIG. 9 is a diagram illustrating an internal structure of a computer device according to an embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more clearly understood, the present application is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of and not restrictive on the broad application. In the following description, "a and/or B" means "at least one of a and B".
The communication authentication method for the intelligent furniture provided by the embodiment of the application can be applied to the application environment shown in fig. 1. Wherein the terminal 102 communicates with the server 104 via a network. The data storage system may store data that the server 104 needs to process. The data storage system may be integrated on the server 104, or may be located on the cloud or other network server.
The terminal 102 may be, but is not limited to, various intelligent chairs with security chips installed therein, and intelligent furniture such as a control device externally connected to the intelligent chairs. The server 104 may be implemented as a stand-alone server or as a server cluster comprised of multiple servers. The scheme provided by the embodiment of the application is cooperatively realized by the terminal 102 and the server 104.
In one embodiment, the security chip is an embedded data security chip for intellectual property protection and data protection. The safety chip stores the secret key and the check information, and can store the user-defined data and operate the user-defined algorithm. In one embodiment, the custom data and algorithm stored in the security chip cannot be read and analyzed by the outside world, so as to ensure the data security. The security chip is a chip with a built-in smart card kernel, supports downloading and running of a custom algorithm, and has a function of resisting various attacks, such as differential attack, power consumption analysis and fragmentation attack, on a chip hardware level. When the security level of the chip is at the bank card level, the user-defined data and the user-defined algorithm stored in the chip can be regarded as a black box, the outside cannot acquire the information, and the analysis and the cloning of the internal algorithm cannot be further performed. It can be understood that the cost of the chip is not high, and the number of the domestic manufacturers of the chip is not small, so that the chip has obvious advantages in the aspect of supply chain safety, and is very suitable for the mass production requirements of intelligent furniture such as intelligent seats and the like. The secure chip may be specifically SMEC90ST of giant Weber in Shenzhen, LKT4306 of bengkean.
In an embodiment, under the condition of considering cost, the cost of part of security can be reduced, a special security chip is not arranged, an algorithm in the security chip is arranged in a control unit, and the control unit can be replaced by an element or a combination which can realize the same function, such as an MCU, an FPGA, a CPLD, a CPU, a DSP, a logic circuit, a memory chip and the like.
In one embodiment, as shown in fig. 2, a communication authentication method for smart furniture is provided, which is described by taking the method as an example applied to the terminal 102 in fig. 1, in which a security chip is installed, and the security chip performs the following steps:
step 202, sending an authentication request to a server so that the server returns combined data obtained by combining a public key and a ciphertext hash; the ciphertext hash is obtained by encrypting a hash of the public key.
The authentication request is a security authentication request for communication between the intelligent furniture and the server, and when the security authentication request passes the verification of the server, the server returns the combined data obtained by combining the public key and the ciphertext hash. The authentication request can be in a form of an authentication request plaintext or an authentication request ciphertext, and the server judges whether the authentication flow is terminated according to whether the authentication request in the form meets the corresponding condition. For example: sending an authentication request plaintext to a cloud server, and if the server determines that the authentication request plaintext is preset and fixed, returning combined data obtained by combining public key and ciphertext hash; otherwise, the authentication procedure is terminated.
In one embodiment, the secure chip sends an authentication request to the server, comprising: with the starting of the intelligent furniture, after the security chip generates an authentication request, the newly generated authentication request is sent to a certain server through the control unit MCE and the communication module, and the newly generated authentication request is used for informing the server to return a public key of the communication after the intelligent furniture is started.
Correspondingly, after the server receives the authentication request, the server verifies the authentication request; if the verification of the authentication request is passed, generating a hash of the public key and the public key, combining a ciphertext hash obtained by asymmetrically encrypting the hash of the public key and the public key, and transmitting the combined data to a security chip sending the authentication request. Therefore, after the intelligent furniture is started every time, the public key of the communication used by the starting is obtained through the authentication request so as to temporarily store the public key of the temporary communication, and therefore, the safety of the communication is improved.
And 204, receiving the combined data, judging whether the public key in the combined data is matched with the ciphertext hash, and if so, authenticating the public key in the combined data to obtain an authenticated public key.
The combined data received by the security chip may be modified by a third party in the communication process, and in order to ensure data security, the public key in the received combined data is checked, and when the public key in the combined data passes authentication, the public key in the combined data is the authenticated public key. The authenticated public key is the public key in the combined data that is not modified by the third party during the communication.
The process of verifying the public key in the received combined data is a process of judging whether the public key in the combined data is matched with the ciphertext hash, and in the process, the process is used for judging whether the public key in the received combined data is matched with the public key in the combined data returned by the server; if not, the public key in the received combined data is modified, and the authentication fails; if the data is matched, the public key in the combined data is determined to be unmodified through the process, and the authenticated public key is obtained.
In one embodiment, determining whether the public key and the ciphertext hash in the combined data match comprises: splitting the combined data into a public key to be verified and a ciphertext hash of the public key; matching a result obtained by carrying out encryption operation on the public key to be verified and a result obtained by carrying out decryption on the ciphertext hash of the public key to obtain a public key verification result; and judging whether the public key and the ciphertext hash in the combined data are matched or not based on the public key verification result. For example: and when the public key verification result is represented, the result obtained by performing encryption operation on the public key to be verified and the result obtained by performing decryption on the ciphertext hash of the public key are not matched, judging that the public key and the ciphertext hash in the combined data are not matched.
In one embodiment, the ciphertext hash in the combined data is a hash of the public key encrypted under the server's private key. The server's private key is stored in the server and the server's public key is stored in the security chip. The public key of the server and the private key of the server have a correspondence of asymmetric encryption. The asymmetric encryption corresponding relation means that data encrypted by a public key of the server can be decrypted by a private key of the server; and the data encrypted by the private key of the server can be decrypted by the public key of the server. The private key of the server is an encrypted private key for signature verification in the combined data, and the security chip is decrypted by the public key of the server to verify whether the combined data is sent by a legal cloud server.
Correspondingly, judging whether the public key and the ciphertext hash in the combined data are matched comprises the following steps: splitting the combined data to obtain a public key in the combined data and a ciphertext hash in the combined data; carrying out hash operation on the public key in the combined data to obtain a verification hash of the public key in the combined data; decrypting the ciphertext hash in the combined data through a public key of the server to obtain a plaintext hash corresponding to the ciphertext hash; and judging whether the verification hash of the public key in the combined data is consistent with the plaintext hash corresponding to the ciphertext hash.
In one embodiment, splitting the combined data is to split the combined data based on a splitting manner corresponding to a combining manner of the combined data to obtain a public key in the combined data and a public key ciphertext in the combined data. When the combined data is obtained by splicing, the combined data is directly split; and when the combined data is obtained by asymmetrically encrypting the spliced data, decrypting the combined data and splitting the combined data.
When the verification hash of the public key in the combined data is consistent with the plaintext hash corresponding to the ciphertext hash, the public key in the combined data passes the authentication, the public key in the combined data is the authenticated public key, and the authenticated public key is the public key which is not modified by a third party. After the authenticated public key is obtained, the authenticated public key is stored in the security chip to enhance the security.
And step 206, calculating the hash of the target data during data interaction, and encrypting the hash of the target data to obtain the ciphertext hash of the target data.
The target data is data transmitted to the server through the terminal for communication. The ciphertext hash of the target data is obtained by calculating the hash of the target data and carrying out reversible encryption on the hash of the target data. The ciphertext hash of the target data is used to verify the target data to determine whether the target data is altered during transmission.
In one embodiment, calculating a hash of the target data and encrypting the hash of the target data to obtain a ciphertext hash of the target data includes: receiving target data sent by a control unit of the intelligent furniture; performing hash operation on the target data to obtain the hash of the target data; and carrying out asymmetric encryption on the hash of the target data to obtain the ciphertext hash of the target data.
In one embodiment, the hash operation is performed on the target data, and the target data is calculated according to any hash algorithm such as MD5, SHA1, SHA3, and the hash of the target data is obtained, and the hash of the target data cannot be obtained by inverse operation. And after the hash of the target data is obtained, carrying out asymmetric encryption on the hash of the target data to obtain the ciphertext hash of the target data which can be decrypted.
In one embodiment, asymmetrically encrypting the hash of the target data to obtain the ciphertext hash of the target data comprises: performing asymmetric encryption on the hash of the target data through a private key of a security chip to obtain a ciphertext hash of the target data; the private key of the security chip corresponds to the public key of the security chip, and the public key of the security chip is used for carrying out communication authentication on the intelligent furniture. Therefore, the terminal encrypts the data through the private key of the security chip, the server receives the communication authentication data, and the data is analyzed through the private key matched with the public key to obtain the ciphertext hash of the target data and the target data; and then, the ciphertext hash is split from the communication authentication data, the ciphertext hash in the communication authentication data is decrypted through a public key of the safety chip, and the target data in the communication authentication data is matched based on the decrypted result, so that the communication authentication of the intelligent furniture is realized.
And step 208, carrying out hash encryption on the target data and the ciphertext of the target data through the authenticated public key to obtain communication authentication data.
In one embodiment, encrypting the target data with a ciphertext hash of the target data with the authenticated public key comprises: splicing the target data and the ciphertext hash of the target data to obtain spliced data of the target data; and encrypting the spliced data of the target data through the authenticated public key to obtain communication authentication data. The communication authentication data is used for transmitting the target data to the server, and the server is enabled to authenticate whether the target data is changed in the transmission process based on the communication authentication data so as to judge whether the target data is changed in the transmission process.
And step 210, sending the communication authentication data to a server so as to perform communication authentication on the intelligent furniture based on the communication authentication data.
In one embodiment, sending the communication authentication data to the server comprises: after the communication authentication data are generated through the security chip, the communication authentication data are sent to the cloud server through the MCU and the communication module, so that the cloud server can carry out communication authentication on the intelligent furniture based on the communication authentication data.
In the communication authentication method for the intelligent furniture, an authentication request is sent to a server so that the server returns combined data obtained by combining public key and ciphertext hash; the ciphertext hash is obtained by encrypting the hash of the public key, and the request process of the combined data occupies less computing resources; and receiving the combined data, judging whether the public key in the combined data is matched with the ciphertext hash, if so, authenticating the public key in the combined data to obtain an authenticated public key, and judging whether the public key in the combined data is changed in the transmission process through less calculation so as to perform the safety authentication of the public key through less calculation resources. When data interaction is carried out, the hash of the target data is calculated, and the hash of the target data is encrypted to obtain the ciphertext hash of the target data; encrypting the target data and the ciphertext hash of the target data through the authenticated public key to obtain communication authentication data; the communication authentication data of the target data are obtained through less computing resources, the server can directly check through the communication authentication data, whether the target data are changed by a third party in the transmission process is detected, and the communication authentication data are sent to the server so as to carry out communication authentication on the intelligent furniture based on the communication authentication data.
In one embodiment, as shown in fig. 3, a communication authentication method for smart furniture is provided, which is described by taking the method as an example applied to the server 104 in fig. 1, and includes the following steps:
step 302, receiving an authentication request sent by a security chip.
After receiving an authentication request sent by a certain security chip, verifying the authentication request. In the process of verifying the authentication request, comparing the received authentication request with a corresponding verification value to obtain a verification result of the authentication request of the security chip; if the verification result of the authentication request represents and the authentication request passes the verification, the server responds to the authentication request and executes corresponding steps; otherwise, the security authentication is finished.
Step 304, in response to the authentication request, sending the combined data obtained by the hash combination of the public key and the ciphertext to the security chip so that the security chip authenticates the public key in the combined data; the ciphertext hash is obtained by encrypting a hash of the public key.
The ciphertext hash is obtained by asymmetrically encrypting the public key. The ciphertext hash can be analyzed to be a hash plaintext corresponding to the ciphertext hash, the public key is subjected to hash calculation in the same way, and a hash for verification can also be obtained, so that whether the public key in the combined data is changed by a third party is judged according to a matching result of the hash plaintext corresponding to the ciphertext hash and the hash for verification.
In one embodiment, in response to the authentication request, sending combined data resulting from the combination of the public key and the ciphertext hash to the secure chip comprises: generating a public key and a private key adapted to the public key in response to the authentication request; carrying out hash operation on the public key to obtain the hash of the public key; encrypting the hash of the public key based on a private key of the server to obtain a ciphertext hash; and combining the public key and the ciphertext hash to obtain combined data corresponding to the authentication request.
In one embodiment, generating a public key and a private key to which the public key is adapted in response to an authentication request includes: the server responds to an authentication request of certain intelligent furniture, and generates a public key corresponding to the authentication request and a private key matched with the public key based on a certain public key algorithm. The public key algorithm includes, but is not limited to, an RSA algorithm, an elliptic curve algorithm, and the like.
The process of performing hash calculation on the public key adopts a process of performing calculation according to a certain hash algorithm. The hash algorithm may be any one algorithm or any combination of algorithms not limited to MD5, SHA1, SHA3, etc. to take security and computational load into account. For example: in order to reduce the calculation amount, a hash algorithm with less calculation resources can be used for operation; to improve the security, a more complex hash algorithm may be used, or a combination of multiple hash algorithms may be used.
Step 306, receiving communication authentication data sent by the security chip; the communication authentication data is obtained by the security chip through the authenticated public key to hash and encrypt the target data and the ciphertext of the target data.
The generation process, the sending process of the communication authentication data are executed in the terminal, and the process, the definition and the related effects thereof can refer to the embodiments of step 206-step 210 in the present application.
And 308, analyzing the communication authentication data through a private key matched with the public key to obtain a ciphertext hash of the target data and the target data.
In one embodiment, parsing the communication authentication data with a public key adapted private key comprises: and analyzing the communication authentication data through a private key matched with the public key to obtain the ciphertext hash of the received target data and the target data. The private key adapted to the public key is used for decrypting a ciphertext obtained by encrypting the public key.
And step 310, judging whether the target data is matched with the ciphertext hash of the target data, and obtaining a communication authentication result of the intelligent furniture.
The target data is interactive data, and when the target data is not sent, the target data cannot be changed in the transmission process; when the server receives the communication authentication data, the target data may be changed in the course of propagation. Thus, the target data is concatenated with the ciphertext hash of the target data and encrypted to detect whether the target data is altered.
In one embodiment, determining whether the target data matches the ciphertext hash of the target data comprises: matching a result obtained by performing encryption operation on the received target data and a result obtained by performing decryption on the ciphertext hash of the target data to obtain a target data verification result; and judging whether the received target data is matched with the ciphertext hash of the target data or not based on the target data checking result. For example: and when the target data verification result is represented, the received result of the encryption operation of the target data and the result of the decryption of the ciphertext hash of the target data are not matched, judging that the public key and the ciphertext hash in the combined data are not matched.
In one embodiment, the ciphertext hash of the target data is obtained by encrypting the hash of the target data with a private key of the security chip. The private key of the secure chip is stored in the secure chip, and the public key of the secure chip is stored in the server. The public key of the security chip and the private key of the security chip have a corresponding relationship of asymmetric encryption. The corresponding relation of the asymmetric encryption means that the data encrypted by the public key of the security chip can be decrypted by the private key of the security chip; and the data encrypted by the private key of the security chip can be decrypted by the public key of the security chip. The private key of the security chip is an encrypted private key for target data verification, the server uses the public key of the security chip for decryption to verify whether the target data in the communication authentication data is sent by legal intelligent furniture or not, and to verify whether the target data is changed in the transmission process or not.
Correspondingly, judging whether the ciphertext hash of the target data is matched with the ciphertext hash of the target data comprises the following steps: performing hash operation on the target data to obtain a verification hash of the target data; decrypting the ciphertext hash of the target data based on the public key of the security chip to obtain the plaintext hash of the target data; and judging whether the verification hash of the target data is matched with the plaintext hash of the target data.
If the verification hash of the target data is matched with the plaintext hash of the target data, determining that the target data is data capable of being communicated; if not, the target data is determined to be data which cannot be communicated.
In the communication authentication method of the intelligent furniture, an authentication request sent by a security chip is received; and sending combined data obtained by combining the public key and the ciphertext hash to the security chip in response to the authentication request so that the security chip authenticates the public key in the combined data, the request process of the combined data occupies less computing resources, and whether the public key in the combined data is changed in the transmission process is judged through less computation so as to perform the security authentication of the public key through less computing resources. When data interaction is carried out, communication authentication data sent by the security chip are received; the communication authentication data is obtained by the security chip through the authenticated public key to hash and encrypt the target data and the ciphertext of the target data; the communication authentication data is analyzed through a private key matched with the public key to obtain the ciphertext hash of the target data and the target data, so that the ciphertext hash of the target data and the ciphertext hash of the target data in the communication authentication data can be directly verified, and the target data is detected to be changed by a third party in the transmission process, so that the safety is improved.
In one embodiment, the steps 202 to 210, and the steps 302 to 310 are discussed comprehensively to understand the overall scheme of the present application, and specifically include the following steps:
the intelligent furniture sends an authentication request to a server;
the server receives an authentication request sent by the security chip;
the server responds to the authentication request and sends combined data obtained by combining public key and ciphertext hash to the security chip;
the intelligent furniture receives the combined data and judges whether a public key in the combined data is matched with the ciphertext hash or not, if so, the public key in the combined data passes the authentication to obtain an authenticated public key;
when the intelligent furniture performs data interaction with a server, calculating the hash of target data, and encrypting the hash of the target data to obtain the ciphertext hash of the target data;
the intelligent furniture encrypts the target data and the ciphertext hash of the target data through the authenticated public key to obtain communication authentication data;
the smart furniture sends the communication authentication data to the server so as to carry out communication authentication on the smart furniture based on the communication authentication data.
The server receives communication authentication data sent by the security chip;
the server analyzes the communication authentication data through a private key matched with the authenticated public key to obtain ciphertext hash of the target data and the target data;
and the server judges whether the target data is matched with the ciphertext hash of the target data or not to obtain a communication authentication result of the intelligent furniture.
In the embodiment, the ciphertext hash is obtained by encrypting the hash of the public key, the request process of the combined data occupies less computing resources, and when the public key is verified, whether the public key in the combined data is changed in the transmission process is judged through less computation, so that the safe authentication of the public key is performed through less computing resources; when data interaction is carried out, communication authentication data of the target data are obtained through less computing resources, and the server can directly carry out verification through ciphertext hash of the target data and the target data in the communication authentication data, so that communication cost and communication safety are considered.
Specifically, the communication authentication method for smart furniture provided by the embodiment of the present application may be applied to an application environment shown in fig. 1. Wherein:
a security chip: an embedded data security chip for intellectual property protection and data protection, hereinafter referred to as security chip. The safety chip can store self-defined data and run a self-defined algorithm. In the security authentication scheme, the custom data and the algorithm stored in the security chip can not be read and analyzed by the outside, so that the security algorithm can be stored in the security chip.
A control unit: the chip is a general MCU chip, FPGA chip or the like, and is hereinafter referred to as MCU. The program operated in the computer has the danger of being exported and analyzed by a third party, so that the computer is used for storing and operating data and codes which have low requirements on safety. In the security authentication scheme, the data and algorithm stored in the MCU can be considered as transparent to the outside, so that the security algorithm is prohibited from being placed in the MCU.
A communication module: the embedded communication module has the networking functions of 4G (fourth generation mobile communication technology) or WiFi (wireless fidelity), and the like, and the control port is communicated with the MCU and has the function of networking equipment.
Cloud server: cloud server or internet of things platform, hereinafter referred to as cloud server for short. The cloud server is kept in a special machine room, and an encryption interaction algorithm is operated on the cloud server. In the security authentication scheme, it can be considered that the security algorithm and the interaction logic operated in the cloud server cannot be read and analyzed by the outside.
In one embodiment, as shown in FIG. 5, the implementation of the present solution is discussed by the application environment shown in FIG. 4, which includes the following steps:
1. generating a group of key pairs of the server according to a public key algorithm PKA1, wherein the public key of the server is marked as PubKey1 and is stored in a security chip; the private key of the server is marked as PrivKey1 and is stored in the cloud server;
2. generating a group of key pairs of the security chips according to a public key algorithm PKA3, wherein the public key of the security chips is marked as PubKey3 and stored in the cloud server; the private key of the security chip is recorded as PrivKey3 and stored in the security chip.
3. The security chip sends an authentication request to the cloud server through the MCU and the communication module, the plaintext of the authentication request is a fixed value and is marked as AuthReq, and the fixed value is ASCII (American Standard code for information interchange) of AuthRequest.
4. And after receiving the AuthReq, the cloud server judges whether the Auth is ASCII of the AuthRequest, and if not, the authentication process is terminated.
5. If the value of AuthReq is equal to the ASCII of AuthRequest, the cloud server generates a group of key pairs according to a public key algorithm PKA2, wherein the public key is marked as PubKey2, and the private key is marked as PrivKey 2.
6. The cloud server calculates the hash of the public key PubKey2 through a hash algorithm HA1, and the obtained hash value of the public key is recorded as HashB 1.
7. The cloud server encrypts the hash value HashB1 of the public key by using a public key algorithm PKA1, the encrypted key is the private key PrivKey1 of the server, and the ciphertext hash CipherHash1 is obtained.
8. And splicing the public key PubKey2 generated by the cloud server with the CipherText hash CipherHash1 to obtain combined data CipherText1, wherein the combined data CipherText1 is returned to the security chip through the communication module and the MCU.
9. The security chip obtains the combined data CipherText1 and does not know whether the received combined data CipherText1 is modified by a third party in the communication process. The CipherText is marked as received combined data CipherText2, and is split into a public key PubKey2 to be checked and a CipherText hash of the public key to be checked, CipherHash 1.
10. The security chip uses the same hash algorithm HA1 to hash the public key PubKey2 to be verified, and obtains a verification hash HashB1 of the public key in the combined data.
11. The security chip uses the same public key algorithm PKA1, and uses the public key PubKey1 of the server to decrypt the ciphertext hash CipherHash1 of the public key to be checked, so as to obtain the plaintext hash Hash1 corresponding to the ciphertext hash.
12. And the security chip compares the verification hash HashB1 of the public key in the combined data with the plaintext hash HashB1 corresponding to the ciphertext hash to determine whether the verification hash HashB1 of the public key in the combined data is completely the same or not, and if the verification hash HashB1 of the public key in the combined data is not completely the same, the authentication flow is terminated.
13. If the verification hash HashB1 of the public key in the combined data is identical to the plaintext hash HashB1 corresponding to the ciphertext hash, the security chip writes the PubKey2 into its internal memory space.
In this embodiment, in the steps executed in each of the steps 1 to 13 when the intelligent seat is started, the public key PubKey2 and the private key PrivKey2 do not change during the power-on period of the intelligent furniture, but the public key PubKey2 and the private key PrivKey2 are updated when the system is initialized again as long as the intelligent seat is powered on again each time.
Further, after step 13, as shown in fig. 6, the method further comprises an interacting step, wherein:
14. when the control unit MCU in the intelligent seat needs to upload the target Data to the cloud server, the target Data which needs to be uploaded is transmitted to the security chip.
15. After the security chip receives the target Data, the hash algorithm HA2 is used for carrying out hash calculation on the target Data to obtain a hash HashA1 of the target Data.
16. The security chip encrypts the hash value HashA1 of the target data by using a public key algorithm PKA3, wherein the encrypted key is the private key PrivKey3 of the security chip, and the ciphertext hash CipherHash2 of the target data is obtained.
17. The security chip splices the target Data and the CipherText hash CipherHash2 of the target Data to obtain combined Data CipherText2 of the target Data.
18. The security chip encrypts the combined data CipherText2 of the target data by using a public key algorithm PKA2, and the encrypted key is an authenticated public key PubKey2 to obtain communication authentication data CipherText 3.
19. The communication authentication data CipherText3 is sent to the cloud server through the MCU and the communication module.
20. When the cloud server receives the sent communication authentication data, the cloud server does not know whether the communication authentication data is modified by a third party in the communication process. This communication authentication data is communication authentication data CipherText3 received by the server.
21. The cloud server decrypts the communication authentication data CipherText3 received by the server by using a public key algorithm PKA2 and a private key PrivKey2 matched with the authenticated public key to obtain spliced data CipherText2 of the target data, wherein the spliced data of the target data is obtained by hashing and splicing the target data and a CipherText of the target data.
22. The cloud server splits the spliced Data CipherText2 of the target Data into the target Data analyzed by the server and the CipherText hash CipherHash2 of the target Data analyzed by the server.
23. The cloud server uses the same hash algorithm HA2 to calculate the hash of the target Data parsed by the server, and obtains the verification hash HashA1 of the target Data.
24. The cloud server uses the same public key algorithm PKA3, and uses the security chip public key PubKey3 to decrypt the ciphertext hash CipherHash2 of the target data to obtain the plaintext hash Hash A1 of the target data.
25. And the cloud server compares whether the verification hash HashA1 of the target data is completely the same as the plaintext hash HashA1 of the target data, and if not, the authentication process is terminated.
26. And if the verification hash HashA1 of the target Data is identical to the plaintext hash HashA1 of the target Data, the cloud server judges that the target Data analyzed by the server is Data transmitted by a legal device and is not modified by a third party.
In this embodiment, the related important data includes:
AuthReq: and sending the authentication request plaintext generated by the security chip to the cloud server.
CipherHash 1: the cloud server encrypts a ciphertext hash obtained by HashB1 by using PrivKey 1; ciperhash 1: the security chip hashes a CipherText obtained by splitting the CipherText 1; CipherHash 2: the security chip encrypts a ciphertext hash obtained by HashA1 by using PrivKey 3; ciperhash 2: the cloud server hashes the CipherText obtained by splitting the CipherText 2; CipherText 1: the cloud server sends a ciphertext to the security chip; cipertext 1: the security chip receives the ciphertext through an insecure communication channel; CipherText 2: the security chip splices the Data with the ciphertext CipherHash2 to obtain a ciphertext; cipertext 2: CipherText3 is the content obtained by decryption by PKA2 and PrivKey 2; CipherText 3: the security chip encrypts a CipherText obtained by CipherText2 by using PubKey 2; cipertext 3: the cloud server receives the ciphertext through an unsafe communication channel;
data: the method comprises the following steps that original data plaintext needing to be sent to a cloud server by an intelligent seat is obtained; data is as follows: and the cloud server splits the CipherText2 to obtain a plaintext.
HA 1: a hashing algorithm; HA 2: a hashing algorithm.
HashA 1: the security chip hashes the Data after HA 2; HashA 1: the cloud server obtains a hash after HA2 is made on Data; HashA1 ×: the cloud server uses a PKA3 algorithm to decrypt a plaintext hash obtained by CipherHash2 by using a public key PubKey 3;
HashB 1: the cloud server performs hash calculation on the PubKey2 to obtain a plaintext hash; HashB 1: the security chip hashes the PubKey2 after HA 1; HashB1 ×: the security chip uses the PKA1 algorithm to decrypt the plaintext hash obtained by CipherHash1 by using the public key PubKey 1.
PKA 1: a public key algorithm; PKA 2: a public key algorithm; PKA 3: a public key algorithm.
PrivKey 1: a secret key stored in a cloud server in advance; PrivKey 2: a key generated by the cloud server; PrivKey 3: a key stored in the secure chip in advance.
PubKey 1: a secret key stored in the security chip in advance; PubKey 2: a key generated by the cloud server; PubKey 2: the security chip splits the CipherText1 to obtain a key; PubKey 3: and the key is stored in the cloud server in advance.
The hashing algorithm may be selected from, and is not limited to, MD5, SHA1, SHA3, and the like. PKA1, PKA2, PKA 3: the three public key algorithms may be the same or different, and the public key algorithms are optional and not limited to RSA, elliptic curve, and the like.
Therefore, the encryption transmission and tampering detection of information are completed by utilizing the encryption and signature verification functions of the asymmetric algorithm, the validity of both communication parties can be verified, if a third party makes a cloud server or an intelligent seat in a fake mode, a safety authentication mechanism can detect and terminate an authentication process in time, and intellectual property is protected.
Specifically, firstly, the key interaction logic of the embodiment occurs between the security chip and the cloud server, and the two components can be completely considered as black boxes, and the possibility of malicious cracking and reverse analysis by a third party is almost 0. Compared with the situation that the MCU is put into the interactive logic, the safety is improved. Secondly, the application does not require the adoption of the MCU with high safety, thereby reducing the cost and having mass production feasibility. Moreover, compared with the situation that the X509 certificate is put into the communication module, the method and the system avoid man-in-the-middle attack and communication plaintext leakage caused by replacement of the certificate, do not need an Internet of things platform to support verification of the X509 certificate, and enhance universality.
It should be understood that, although the steps in the flowcharts related to the embodiments as described above are sequentially displayed as indicated by arrows, the steps are not necessarily performed sequentially as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a part of the steps in the flowcharts related to the embodiments described above may include multiple steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, and the execution order of the steps or stages is not necessarily sequential, but may be rotated or alternated with other steps or at least a part of the steps or stages in other steps.
Based on the same inventive concept, the embodiment of the application also provides a communication authentication device of the intelligent furniture, which is used for realizing the communication authentication method of the intelligent furniture. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme described in the above method, so specific limitations in the following embodiments of the communication authentication device for one or more pieces of intelligent furniture can be referred to the above limitations on the communication authentication method for the intelligent furniture, and are not described herein again.
In one embodiment, as shown in fig. 7, there is provided a communication authentication apparatus for smart furniture, including: an authentication request sending module 702, a public key authentication module 704, a data encryption module 706, a communication authentication data generation module 708, and a communication authentication data sending module 710, wherein:
an authentication request sending module 702, configured to send an authentication request to a server, so that the server returns combined data obtained by combining public key and ciphertext hashes; the ciphertext hash is obtained by encrypting the hash of the public key;
a public key authentication module 704, configured to receive the combined data, and determine whether a public key in the combined data matches a ciphertext hash, if yes, the public key in the combined data passes authentication, so as to obtain an authenticated public key;
the data encryption module 706 is configured to calculate a hash of target data during data interaction, and encrypt the hash of the target data to obtain a ciphertext hash of the target data;
a communication authentication data generation module 708, configured to encrypt the target data and the ciphertext hash of the target data through the authenticated public key to obtain communication authentication data;
a communication authentication data sending module 710, configured to send the communication authentication data to the server, so as to perform communication authentication on the smart furniture based on the communication authentication data.
In one embodiment, the data encryption module 706 includes:
the target data acquisition unit is used for receiving the target data sent by the control unit of the intelligent furniture;
the hash calculation unit of the target data is used for carrying out hash operation on the target data to obtain the hash of the target data;
and the ciphertext hash calculation unit is used for asymmetrically encrypting the hash of the target data to obtain the ciphertext hash of the target data.
In one embodiment, the ciphertext hash calculation unit is specifically configured to: performing asymmetric encryption on the hash of the target data through a private key of the security chip to obtain a ciphertext hash of the target data; the private key of the security chip corresponds to the public key of the security chip, and the public key of the security chip is used for performing communication authentication on the intelligent furniture.
In one embodiment, the ciphertext hash in the combined data is obtained by encrypting the hash of the public key according to a private key of the server; the public key authentication module 704 includes:
the combined data splitting unit is used for splitting the combined data to obtain a public key in the combined data and a ciphertext hash in the combined data;
the verification hash generation unit is used for carrying out hash operation on the public key in the combined data to obtain a verification hash of the public key in the combined data;
the ciphertext hash decryption unit is used for decrypting the ciphertext hash in the combined data through the public key of the server to obtain a plaintext hash corresponding to the ciphertext hash;
and the target data verification unit is used for judging whether the verification hash of the public key in the combined data is consistent with the plaintext hash corresponding to the ciphertext hash.
In one embodiment, as shown in fig. 8, the present application further provides a communication authentication device for smart furniture. The device comprises:
an authentication request receiving module 802, configured to receive an authentication request sent by a security chip;
a public key returning module 804, configured to send, in response to the authentication request, combined data obtained by combining a public key and a ciphertext hash to the secure chip, so that the secure chip authenticates the public key in the combined data; the ciphertext hash is obtained by encrypting the hash of the public key;
a communication authentication data receiving module 806, configured to receive communication authentication data sent by the security chip; the communication authentication data is obtained by the security chip through the authenticated public key to encrypt the target data and the ciphertext hash of the target data;
a communication authentication data analysis module 808, configured to analyze the communication authentication data through a private key adapted to the authenticated public key to obtain a ciphertext hash of the target data and the target data;
and the communication authentication module 810 is configured to determine whether the ciphertext hash of the target data matches the target data, so as to obtain a communication authentication result of the intelligent furniture.
In one embodiment, the public key returning module 804 includes:
a key generation unit, configured to generate a public key and a private key adapted to the public key in response to the authentication request;
the public key hash calculation unit is used for carrying out hash operation on the public key to obtain the hash of the public key;
the ciphertext hash generating unit is used for encrypting the hash of the public key based on the private key of the server to obtain a ciphertext hash;
and the public key combination unit is used for combining the public key and the ciphertext hash to obtain the combined data corresponding to the authentication request.
In one embodiment, the ciphertext hash of the target data is obtained by encrypting the hash of the target data through a private key of the security chip; the communication authentication module 810 includes:
the verification hash generation unit is used for carrying out hash operation on the target data to obtain a verification hash of the target data;
the plaintext hash unit of the target data is used for decrypting the ciphertext hash of the target data based on the public key of the safety chip to obtain the plaintext hash of the target data;
and the target data verification unit is used for judging whether the verification hash of the target data is matched with the plaintext hash of the target data.
Therefore, through the communication authentication device of the intelligent furniture, the encryption and signature verification functions of the asymmetric algorithm are utilized to complete the encryption transmission and the tampering detection of the information, the legality of both communication parties can be verified, if a third party makes a cloud server or an intelligent seat in a fake mode, a safety authentication mechanism can detect and terminate the authentication process in time, and intellectual property is protected. The key interaction logic of the embodiment is generated between the security chip and the cloud server, and the two components can be completely considered as black boxes, and the possibility of malicious cracking and reverse analysis by a third party is almost 0. Compared with the situation that the MCU is put into the interactive logic, the safety is improved. Secondly, the application does not require the adoption of the MCU with high safety, thereby reducing the cost and having mass production feasibility. Moreover, compared with the situation that the X509 certificate is placed in the communication module, man-in-the-middle attack and communication plaintext leakage caused by replacement of the certificate are avoided, the verification of the X509 certificate is not required to be supported by the platform of the Internet of things, and the universality is enhanced.
The modules in the communication authentication device of the intelligent furniture can be wholly or partially realized by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as shown in fig. 9. The computer device includes a processor, a memory, a communication interface, a display screen, and an input device connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The communication interface of the computer device is used for communicating with an external terminal in a wired or wireless manner, and the wireless manner can be realized through WI-FI, a mobile cellular network, NFC (near field communication) or other technologies. The computer program is executed by the security chip to realize a communication authentication method of intelligent furniture.
It will be appreciated by those skilled in the art that the configuration shown in fig. 9 is a block diagram of only a portion of the configuration associated with the present application, and is not intended to limit the computing device to which the present application may be applied, and that a particular computing device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In an embodiment, there is further provided a computer device including a secure chip, in which a computer program is stored, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.
In an embodiment, a computer-readable storage medium is provided, on which a computer program is stored which, when being executed by a processor, carries out the steps of the above-mentioned method embodiments.
In an embodiment, a computer program product is provided, comprising a computer program which, when being executed by a processor, carries out the steps of the above-mentioned method embodiments.
It should be noted that, the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, presented data, etc.) referred to in the present application are information and data authorized by the user or sufficiently authorized by each party.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high-density embedded nonvolatile Memory, resistive Random Access Memory (ReRAM), Magnetic Random Access Memory (MRAM), Ferroelectric Random Access Memory (FRAM), Phase Change Memory (PCM), graphene Memory, and the like. Volatile Memory can include Random Access Memory (RAM), external cache Memory, and the like. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM), among others. The databases involved in the embodiments provided herein may include at least one of relational and non-relational databases. The non-relational database may include, but is not limited to, a block chain based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic devices, quantum computing based data processing logic devices, etc., without limitation.
All possible combinations of the technical features in the above embodiments may not be described for the sake of brevity, but should be considered as being within the scope of the present disclosure as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present application. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present application should be subject to the appended claims.
Claims (11)
1. A communication authentication method for smart furniture, which is executed by a security chip of the smart furniture, the method comprising:
sending an authentication request to a server so that the server returns combined data obtained by combining public key and ciphertext hash; the ciphertext hash is obtained by encrypting the hash of the public key;
receiving the combined data, judging whether a public key in the combined data is matched with a ciphertext hash, if so, authenticating the public key in the combined data to obtain an authenticated public key;
when data interaction is carried out, calculating the hash of target data, and encrypting the hash of the target data to obtain the ciphertext hash of the target data;
encrypting the target data and the ciphertext hash of the target data through the authenticated public key to obtain communication authentication data;
and sending the communication authentication data to the server to perform communication authentication on the intelligent furniture based on the communication authentication data.
2. The method of claim 1, wherein the computing a hash of the target data and encrypting the hash of the target data to obtain a ciphertext hash of the target data comprises:
receiving target data sent by a control unit of the intelligent furniture;
performing hash operation on the target data to obtain a hash of the target data;
and carrying out asymmetric encryption on the hash of the target data to obtain the ciphertext hash of the target data.
3. The method of claim 2, wherein the asymmetrically encrypting the hash of the target data to obtain the ciphertext hash of the target data comprises:
performing asymmetric encryption on the hash of the target data through a private key of the security chip to obtain a ciphertext hash of the target data;
the private key of the security chip corresponds to the public key of the security chip, and the public key of the security chip is used for carrying out communication authentication on the intelligent furniture.
4. The method according to claim 1, wherein the ciphertext hash in the combined data is obtained by encrypting a hash of the public key with a private key of the server; the judging whether the public key and the ciphertext hash in the combined data are matched comprises:
splitting the combined data to obtain a public key in the combined data and a ciphertext hash in the combined data;
performing hash operation on the public key in the combined data to obtain a verification hash of the public key in the combined data;
decrypting the ciphertext hash in the combined data through the public key of the server to obtain a plaintext hash corresponding to the ciphertext hash;
and judging whether the verification hash of the public key in the combined data is consistent with the plaintext hash corresponding to the ciphertext hash.
5. A communication authentication method for smart furniture, performed by a server, the method comprising:
receiving an authentication request sent by a security chip;
in response to the authentication request, sending combined data obtained by combining public key and ciphertext hash to the security chip so that the security chip authenticates the public key in the combined data; the ciphertext hash is obtained by encrypting the hash of the public key;
receiving communication authentication data sent by the security chip; the communication authentication data is obtained by the security chip through the authenticated public key to encrypt the target data and the ciphertext hash of the target data;
analyzing the communication authentication data through a private key matched with the authenticated public key to obtain ciphertext hash of the target data and the target data;
and judging whether the target data is matched with the ciphertext hash of the target data or not to obtain a communication authentication result of the intelligent furniture.
6. The method of claim 5, wherein sending combined data resulting from a combination of public key and ciphertext hashes to the secure chip in response to the authentication request comprises:
generating a public key and a private key adapted to the public key in response to the authentication request;
carrying out hash operation on the public key to obtain the hash of the public key;
encrypting the hash of the public key based on the private key of the server to obtain a ciphertext hash;
and combining the public key and the ciphertext hash to obtain combined data corresponding to the authentication request.
7. The method according to claim 5, wherein the ciphertext hash of the target data is obtained by encrypting the hash of the target data by a private key of the security chip; the determining whether the target data matches the ciphertext hash of the target data includes:
performing hash operation on the target data to obtain a verification hash of the target data;
decrypting the ciphertext hash of the target data based on the public key of the security chip to obtain the plaintext hash of the target data;
and judging whether the verification hash of the target data is matched with the plaintext hash of the target data.
8. A communication authentication apparatus for smart furniture, the apparatus comprising:
the authentication request sending module is used for sending an authentication request to the server so that the server returns combined data obtained by combining public key hashes and ciphertext hashes; the ciphertext hash is obtained by encrypting the hash of the public key;
the public key authentication module is used for receiving the combined data and judging whether a public key in the combined data is matched with the ciphertext hash or not, if so, the public key in the combined data passes authentication to obtain an authenticated public key;
the data encryption module is used for calculating the hash of target data and encrypting the hash of the target data to obtain the ciphertext hash of the target data when data interaction is carried out;
the communication authentication data generation module is used for carrying out hash encryption on the target data and the ciphertext of the target data through the authenticated public key to obtain communication authentication data;
and the communication authentication data sending module is used for sending the communication authentication data to the server so as to carry out communication authentication on the intelligent furniture based on the communication authentication data.
9. A communication authentication apparatus for smart furniture, the apparatus comprising:
the authentication request receiving module is used for receiving an authentication request sent by the security chip;
a public key returning module, configured to send, in response to the authentication request, combined data obtained by combining a public key and a ciphertext hash to the security chip, so that the security chip authenticates the public key in the combined data; the ciphertext hash is obtained by encrypting the hash of the public key;
the communication authentication data receiving module is used for receiving the communication authentication data sent by the security chip; the communication authentication data is obtained by the security chip through the authenticated public key to encrypt the target data and the ciphertext hash of the target data;
the communication authentication data analysis module is used for analyzing the communication authentication data through a private key matched with the authenticated public key to obtain a ciphertext hash of the target data and the target data;
and the communication authentication module is used for judging whether the target data is matched with the ciphertext hash of the target data to obtain a communication authentication result of the intelligent furniture.
10. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor, when executing the computer program, implements the steps of the method of any of claims 1 to 7.
11. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210888420.2A CN115001864B (en) | 2022-07-27 | 2022-07-27 | Communication authentication method and device for intelligent furniture, computer equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210888420.2A CN115001864B (en) | 2022-07-27 | 2022-07-27 | Communication authentication method and device for intelligent furniture, computer equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN115001864A true CN115001864A (en) | 2022-09-02 |
CN115001864B CN115001864B (en) | 2023-03-10 |
Family
ID=83022534
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210888420.2A Active CN115001864B (en) | 2022-07-27 | 2022-07-27 | Communication authentication method and device for intelligent furniture, computer equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115001864B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116702177A (en) * | 2023-06-21 | 2023-09-05 | 南京风荧网络科技有限公司 | System and method for safely transmitting big data of computer |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107040369A (en) * | 2016-10-26 | 2017-08-11 | 阿里巴巴集团控股有限公司 | Data transmission method, apparatus and system |
US20180241560A1 (en) * | 2016-01-29 | 2018-08-23 | Hewlett Packard Enterprise Development Lp | Device attestation |
CN110113745A (en) * | 2019-04-29 | 2019-08-09 | 中兴新能源汽车有限责任公司 | Verification method, server, mobile unit and the storage medium of mobile unit |
CN111541677A (en) * | 2020-04-17 | 2020-08-14 | 中国科学院上海微系统与信息技术研究所 | Safe hybrid encryption method based on narrowband Internet of things |
CN111931158A (en) * | 2020-08-10 | 2020-11-13 | 深圳大趋智能科技有限公司 | Bidirectional authentication method, terminal and server |
CN112202556A (en) * | 2020-10-30 | 2021-01-08 | 联通物联网有限责任公司 | Security authentication method, device and system |
WO2022126980A1 (en) * | 2020-12-15 | 2022-06-23 | 平安科技(深圳)有限公司 | Data transmission method and apparatus, terminal, and storage medium |
WO2022206349A1 (en) * | 2021-04-02 | 2022-10-06 | 腾讯科技(深圳)有限公司 | Information verification method, related apparatus, device, and storage medium |
-
2022
- 2022-07-27 CN CN202210888420.2A patent/CN115001864B/en active Active
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20180241560A1 (en) * | 2016-01-29 | 2018-08-23 | Hewlett Packard Enterprise Development Lp | Device attestation |
CN107040369A (en) * | 2016-10-26 | 2017-08-11 | 阿里巴巴集团控股有限公司 | Data transmission method, apparatus and system |
US20190253249A1 (en) * | 2016-10-26 | 2019-08-15 | Alibaba Group Holding Limited | Data transmission method, apparatus and system |
CN110113745A (en) * | 2019-04-29 | 2019-08-09 | 中兴新能源汽车有限责任公司 | Verification method, server, mobile unit and the storage medium of mobile unit |
CN111541677A (en) * | 2020-04-17 | 2020-08-14 | 中国科学院上海微系统与信息技术研究所 | Safe hybrid encryption method based on narrowband Internet of things |
CN111931158A (en) * | 2020-08-10 | 2020-11-13 | 深圳大趋智能科技有限公司 | Bidirectional authentication method, terminal and server |
CN112202556A (en) * | 2020-10-30 | 2021-01-08 | 联通物联网有限责任公司 | Security authentication method, device and system |
WO2022126980A1 (en) * | 2020-12-15 | 2022-06-23 | 平安科技(深圳)有限公司 | Data transmission method and apparatus, terminal, and storage medium |
WO2022206349A1 (en) * | 2021-04-02 | 2022-10-06 | 腾讯科技(深圳)有限公司 | Information verification method, related apparatus, device, and storage medium |
Non-Patent Citations (1)
Title |
---|
郭军: "基于椭圆曲线加密算法与SHA-3算法的新型认证方案分析与设计", 《移动通信》 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116702177A (en) * | 2023-06-21 | 2023-09-05 | 南京风荧网络科技有限公司 | System and method for safely transmitting big data of computer |
Also Published As
Publication number | Publication date |
---|---|
CN115001864B (en) | 2023-03-10 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11323275B2 (en) | Verification of identity using a secret key | |
US10708062B2 (en) | In-vehicle information communication system and authentication method | |
US7697691B2 (en) | Method of delivering Direct Proof private keys to devices using an on-line service | |
KR102444402B1 (en) | NFC tag authentication to remote servers with applications to secure supply chain asset management | |
US11050562B2 (en) | Target device attestation using a trusted platform module | |
US7693286B2 (en) | Method of delivering direct proof private keys in signed groups to devices using a distribution CD | |
US11153074B1 (en) | Trust framework against systematic cryptographic | |
US7792303B2 (en) | Method of delivering direct proof private keys to devices using a distribution CD | |
CN111241492A (en) | Product multi-tenant secure credit granting method, system and electronic equipment | |
CN117155549A (en) | Key distribution method, key distribution device, computer equipment and storage medium | |
CN116232639B (en) | Data transmission method, device, computer equipment and storage medium | |
CN114499875A (en) | Service data processing method and device, computer equipment and storage medium | |
CN115348107A (en) | Internet of things equipment secure login method and device, computer equipment and storage medium | |
CN115001864B (en) | Communication authentication method and device for intelligent furniture, computer equipment and storage medium | |
CN115514492A (en) | BIOS firmware verification method, device, server, storage medium and program product | |
CN116980228B (en) | Method and system for realizing anonymous identity login in Internet environment | |
CN116049802B (en) | Application single sign-on method, system, computer equipment and storage medium | |
CN108390758B (en) | User password processing method and device and internal control security monitoring system | |
CN114553557B (en) | Key calling method, device, computer equipment and storage medium | |
CN108242997B (en) | Method and apparatus for secure communication | |
CN115694833A (en) | Collaborative signature method | |
US11783057B2 (en) | Method for securely provisioning a device incorporating an integrated circuit without using a secure environment | |
CN114896621A (en) | Application service acquisition method, encryption method, device and computer equipment | |
CN115022057A (en) | Security authentication method, device and equipment and storage medium | |
CN114065170A (en) | Method and device for acquiring platform identity certificate and server |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |