CN108242997B - Method and apparatus for secure communication - Google Patents

Method and apparatus for secure communication Download PDF

Info

Publication number
CN108242997B
CN108242997B CN201611221027.9A CN201611221027A CN108242997B CN 108242997 B CN108242997 B CN 108242997B CN 201611221027 A CN201611221027 A CN 201611221027A CN 108242997 B CN108242997 B CN 108242997B
Authority
CN
China
Prior art keywords
key
public key
digital signature
random number
abstract
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.)
Active
Application number
CN201611221027.9A
Other languages
Chinese (zh)
Other versions
CN108242997A (en
Inventor
黄庆伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Leadcore Technology Co Ltd
Datang Semiconductor Design Co Ltd
Original Assignee
Leadcore Technology Co Ltd
Datang Semiconductor Design Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Leadcore Technology Co Ltd, Datang Semiconductor Design Co Ltd filed Critical Leadcore Technology Co Ltd
Priority to CN201611221027.9A priority Critical patent/CN108242997B/en
Publication of CN108242997A publication Critical patent/CN108242997A/en
Application granted granted Critical
Publication of CN108242997B publication Critical patent/CN108242997B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/04Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
    • H04L63/0428Network 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
    • H04L63/0435Network 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 wherein the sending and receiving network entities apply symmetric encryption, i.e. same key used for encryption and decryption
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords
    • H04L9/0869Generation of secret information including derivation or calculation of cryptographic keys or passwords involving random numbers or seeds
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3247Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving digital signatures

Abstract

The invention relates to the field of information security, and discloses a method and equipment for secure communication. In the embodiment of the invention, whether the public key of the CA is complete and whether the digital signature of the CA is effective are verified; if the public key of the CA is complete and the digital signature of the CA is valid, the CA and the TA generate a symmetric key through three-way handshake, and encryption communication is performed according to the symmetric key. According to the embodiment of the invention, the tampered or counterfeited CA can be effectively identified by verifying the public key and the digital signature of the CA, the CA and the TA generate the symmetric key through three-way handshake, and encryption communication is carried out according to the symmetric key, so that the confidentiality and the integrity of communication contents are ensured, and an attacker is effectively prevented from stealing sensitive data or damaging a communication system.

Description

Method and apparatus for secure communication
Technical Field
The present invention relates to the field of information security, and in particular, to a method and device for secure communication.
Background
In a terminal device system introducing a TEE (Trusted Execution Environment), including two subsystems of TEE and REE (Rich Execution Environment), the TEE is responsible for processing transactions requiring higher security protection, such as key storage, encryption, decryption, fingerprint identification, etc., the REE is a common operating system, such as Android system, iOS apple system, etc., a CA (Client Application) and a TA (Trusted Application) running on the REE operating system communicate through a shared memory, as shown in fig. 1, the Rich Execution Environment 11 includes a Client Application 111 and a Rich Execution Environment operating system 112, the Trusted Execution Environment 13 includes a Trusted Application 131 and a Trusted Execution Environment operating system 132, the Client Application 111 and the Trusted Application 131 communicate through the shared memory 12, the existing technical solution generally performs integrity or confidentiality protection on the TEE operating system and the TA, still other solutions provide integrity protection for the REE operating system.
However, in the process of implementing the present invention, the inventor of the present application finds that, for a CA, an existing scheme is not protected or has insufficient protection, for example, when the CA adopts an Android APK (Android package) form, the CA APK may be signed, but the Android adopts a self-signing manner, a signing certificate used in the self-signing manner is not issued by an authority certificate authority, but is generated by a developer, because the self-signing certificate cannot be verified by using a root certificate of the certificate authority, an additional mechanism must be added to protect integrity of a public key in the self-signing certificate, but the Android has no relevant mechanism, and thus integrity of the CA cannot be guaranteed essentially, that is, the CA may be tampered or counterfeited, but the system cannot find the integrity. An attacker may pose a threat to the TEE system by tampering with or counterfeiting the CA, such as stealing sensitive data, disrupting the proper functioning of the TEE system, and the like. In addition, the existing scheme does not perform confidentiality and integrity protection on the shared memory communication of the CA and the TA, and a maker of the TEE specification GlobalPlatform (Global platform International Standard organization) does not release related specifications, so that an attacker can steal or tamper communication contents through malicious software on the REE system, thereby stealing sensitive data or disturbing the normal operation of the TEE system.
Disclosure of Invention
The invention aims to provide a method and equipment for secure communication, which can effectively identify a tampered or counterfeited CA by verifying the integrity of a public key of the CA and the validity of a digital signature of the CA, generate a symmetric key by three-way handshake between the CA and a TA, and carry out encryption communication according to the symmetric key, thereby ensuring the confidentiality and the integrity of communication content and effectively preventing an attacker from stealing sensitive data or damaging a communication system.
To solve the above technical problem, an embodiment of the present invention provides a method for secure communication, including:
verifying whether the public key of the CA is complete and whether the digital signature of the CA is valid;
and if the public key of the CA is complete and the digital signature of the CA is valid, the CA and the TA generate a symmetric key through three-way handshake, and carry out encryption communication according to the symmetric key.
An embodiment of the present invention further provides a secure communication apparatus, including:
the verification module is used for verifying whether the public key of the CA is complete and whether the digital signature of the CA is valid;
the symmetric key generation module is used for generating a symmetric key of the CA and the TA through three-way handshake after verifying that the public key of the CA is complete and the digital signature of the CA is valid;
and the communication module is used for carrying out encryption communication between the CA and the TA according to the symmetric key.
Compared with the prior art, the embodiment of the invention can effectively identify the tampered or counterfeited CA by verifying the integrity of the public key of the CA and the validity of the digital signature, generates the symmetric key by three-way handshake between the CA and the TA, and carries out encryption communication according to the symmetric key, thereby ensuring the confidentiality and integrity of the communication content and effectively preventing an attacker from stealing sensitive data or damaging a communication system.
In addition, the verifying whether the public key of the CA is complete and the digital signature of the CA is valid specifically includes: the trusted execution environment operating system detects whether a first abstract of a public key of the CA is the same as a second abstract stored in the TA, wherein the second abstract is the second abstract of the public key generated according to a preset abstract algorithm; if the first abstract is the same as the second abstract, the rich execution environment operating system verifies whether the digital signature of the CA is valid according to the public key; if the CA's digital signature is valid, the CA is complete. The tampered or counterfeited CA public key can be effectively identified by detecting whether the first abstract is the same as the second abstract, and the tampered or counterfeited CA can be effectively identified by verifying the validity of the digital signature of the CA, so that the integrity of the CA is ensured.
In addition, before the trusted execution environment operating system detects whether the first digest of the public key of the CA is identical to the second digest stored in the TA, the method further includes: and the rich execution environment operating system calculates the first abstract according to the preset abstract algorithm and sends the first abstract to the trusted execution environment operating system. The trusted execution environment operating system can effectively identify the public key of the counterfeit or tampered CA in the communication process.
In addition, the CA and the TA generate a symmetric key through three-way handshake, which specifically includes: the CA sends the generated first random number and an algorithm list of a symmetric encryption algorithm and a message authentication code algorithm; the TA sends the selected identifier of the algorithm in the algorithm list, the generated public key of the RSA public and private key pair and the generated second random number; the CA sends a third random number encrypted according to the RSA public key; and the CA and the TA respectively generate the symmetric key according to the first random number, the second random number and the third random number. The CA and the TA generate a symmetric key through three-way handshake, so that the security of the key is ensured, the confidentiality and the integrity of communication content are further ensured, and an attacker is effectively prevented from stealing sensitive data or damaging a communication system.
Drawings
FIG. 1 is a diagram of the interaction of a trusted execution environment with a rich execution environment in the prior art;
FIG. 2 is a flow chart of a method of secure communication according to a first embodiment of the present invention;
FIG. 3 is a flow chart of a method of secure communication according to a second embodiment of the present invention;
fig. 4 is a schematic structural diagram of a secure communication device according to a third embodiment of the present invention;
fig. 5 is a schematic structural diagram of a secure communication device according to a fourth embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, embodiments of the present invention will be described in detail below with reference to the accompanying drawings. However, it will be appreciated by those of ordinary skill in the art that numerous technical details are set forth in order to provide a better understanding of the present application in various embodiments of the present invention. However, the technical solution claimed in the present application can be implemented without these technical details and various changes and modifications based on the following embodiments.
A first embodiment of the invention relates to a method of secure communication. The specific flow is shown in fig. 2.
In step 201, it is verified whether the public key of the client application is complete and the digital signature is valid, if the public key of the client application is complete and the digital signature of the client application is valid, step 202 is executed, otherwise, the process is ended.
Specifically, whether the public key of the client application CA is complete and the digital signature of the CA is valid is verified, if the public key of the CA is complete and the digital signature of the CA is valid, the CA is not tampered or counterfeited by a attacker, the step 202 is continuously executed, the client application and the trusted application generate a symmetric key through three-time handshake, otherwise, the CA is tampered or counterfeited by the attacker, and the communication is immediately ended, so that the tampered or counterfeited CA is effectively identified.
In step 202, the client application and the trusted application generate a symmetric key through a three-way handshake.
Specifically, when the CA is not tampered or counterfeited by an attacker, the client application CA and the trusted application TA generate a symmetric key through a three-way handshake process, so that the security of the key is ensured, the confidentiality and integrity of communication content are further ensured, and the attacker is effectively prevented from stealing sensitive data or damaging a communication system.
In step 203, encrypted communication is performed according to the symmetric key.
Specifically, when a sender sends a message to a receiver, the content to be sent is encrypted according to the symmetric key and then sent to the receiver through the shared memory, and when the receiver sends a message back to the sender, the content to be sent is encrypted according to the symmetric key and then sent to the sender through the shared memory, so that an attacker is effectively prevented from stealing sensitive data.
Compared with the prior art, in the embodiment, the tampered or counterfeit CA can be effectively identified by verifying the integrity of the public key of the CA and the validity of the digital signature, the CA and the TA generate the symmetric key through three-way handshake, and encryption communication is performed according to the symmetric key, so that the confidentiality and the integrity of communication content are ensured, and an attacker is effectively prevented from stealing sensitive data or damaging a communication system.
A second embodiment of the invention relates to a method of secure communication. The second embodiment is further improved on the basis of the first embodiment, and the main improvement is that: in the second embodiment of the present invention, a specific process of generating a symmetric key by three-way handshake between CA and TA is also given, as shown in fig. 3, in addition to the process of verifying the public key and digital signature of the CA.
In step 301, the public key of the client application and the digital signature generated from the private key of the client application are saved.
Specifically, the CA stores a public key and a Digital Signature generated according to a private key of the CA, where the public key and the private key are a public-private key pair generated according to a preset Digital Signature Algorithm, that is, a public key of an asymmetric public-private key pair of the CA generated according to the preset Digital Signature Algorithm and a Digital Signature generated by the CA according to a private key of the asymmetric public-private key pair are stored in a software package of the CA, where the preset Digital Signature Algorithm may be an RSA encryption Algorithm, a DSA (Digital Signature Algorithm), or an ECDSA (elliptic curve Digital Signature Algorithm).
In step 302, a first digest of the public key of the client application is computed.
Specifically, the rich execution environment operating system calculates a first Digest of the public key of the client application according to a preset Digest Algorithm, that is, the rich execution environment operating system REE OS calculates a Digest of the CA public key in the CA software package according to a preset Digest Algorithm, which is denoted as the first Digest, where the preset Digest Algorithm may be MD5(Message Digest Algorithm 5), SHA1(Secure Hash Algorithm 1), SHA224(Secure Hash Algorithm 224), SHA256(Secure Hash Algorithm 256, Secure Hash Algorithm 256), SHA384(Secure Hash Algorithm 384) or SHA512(Secure Hash Algorithm 512, Secure Hash Algorithm 512).
In step 303, the first digest is sent to the trusted execution environment operating system.
Specifically, the REE OS sends the calculated first digest to the trusted execution environment operating system TEE OS.
In step 304, it is checked whether the first digest is identical to a second digest stored in the trusted application, and if so, step 305 is performed, otherwise, it ends.
Specifically, the trusted execution environment operating system detects whether a first digest of a public key of a CA is the same as a second digest stored in a TA, where the second digest is the second digest of the public key generated according to a preset digest algorithm, that is, after receiving a first digest sent by a REE OS, the TEE OS first reads a digest of the CA public key stored in advance in a TA software package, that is, the second digest, and then detects whether the first digest is the same as the second digest, if the first digest is the same as the second digest, it indicates that the public key of the CA is complete, which indicates that the CA is not tampered or counterfeited by a attacker, and then performs step 305, otherwise, it indicates that the public key of the CA is tampered or counterfeited by the attacker, and directly ends communication.
In step 305, it is verified whether the digital signature of the client application is valid, if so, step 306 is performed, otherwise, it ends.
Specifically, when the first digest is the same as the second digest, the rich execution environment operating system further verifies whether the digital signature of the CA is valid according to the CA public key, that is, the REE OS performs validity verification of the digital signature on the CA software package by using the CA public key, where the digital signature verification process is the same as the data signature verification process in the prior art, and is not repeated here, and the digital signature verification algorithm is the same as the digital signature algorithm, which may be RSA, DSA, or ECDSA, and if the digital signature is valid, that is, the digital signature verification passes, indicating that the CA is not tampered or counterfeited by a successful attacker, the operating CA is loaded, step 306 is executed, otherwise, the operating CA is not loaded, communication is directly ended, thereby effectively identifying the tampered CA, and ensuring the integrity of the CA.
In step 306, the client application sends the generated first random number and the list of algorithms.
Specifically, the client application sends the generated first random number and an algorithm list of a symmetric Encryption algorithm and a message authentication code algorithm supported by the CA, wherein the symmetric Encryption algorithm may be DES (Data Encryption Standard )Encryption Standard), 3DES (Triple Data Encryption Algorithm) or AES (Advanced Encryption Standard), etc., and the Message Authentication Code Algorithm may be HMAC (Hash-based Message Authentication Code), CBC-MAC (Cipher Block Chaining Message Authentication Code) or CMAC (Cipher-based Message Authentication Code)[
In step 307, the trusted application sends the algorithm identification, the public key and the generated second random number.
Specifically, the TA sends the identifier of the algorithm in the selected algorithm list, the generated public key of the RSA public-private key pair, and the generated second random number, that is, the TA selects the symmetric encryption algorithm and the message authentication code algorithm used by both parties to generate the RSA public-private key pair and the second random number, and then outputs the identifier of the algorithm, the RSA public key pair, and the second random number to the CA.
In step 308, the client application sends the encrypted third random number.
Specifically, the CA sends a third random number encrypted according to the RSA public key, that is, the CA generates a third random number again, encrypts the third random number using the RSA public key of the TA, and outputs the encrypted third random number to the TA.
In step 309, the client application and the trusted application generate a symmetric key.
Specifically, CA and TA generate symmetric keys according to a first random number, a second random number, and a third random number, respectively, where TA decrypts the third random number with its RSA private key, so that CA and TA both have 3 random numbers, i.e., the first random number, the second random number, and the third random number, and CA and TA generate keys using the same rule, such as an xor rule, a digest rule, and the like.
In step 310, encrypted communications are conducted according to the symmetric key.
Specifically, the TA and the CA carry out encryption communication based on the same symmetric key and algorithm, an output party firstly encrypts a message, then calculates a message authentication code for a ciphertext, and then outputs the message authentication code and the ciphertext message through a shared memory, a receiving party firstly calculates the message authentication code for the received ciphertext message, then compares the message authentication code with the received message authentication code for verification, if the two are different, the message integrity is damaged, and if the two are the same, the ciphertext message is decrypted, so that the confidentiality and the integrity of communication content are ensured, and an attacker is effectively prevented from stealing sensitive data or damaging a communication system.
The embodiment of the invention not only provides the process of verifying the public key and the digital signature of the CA, but also provides the specific process of generating the symmetric key by three-way handshake between the CA and the TA, thereby facilitating the realization of the algorithm of technical personnel in practical application.
The steps of the above methods are divided for clarity, and the implementation may be combined into one step or split some steps, and the steps are divided into multiple steps, so long as the steps contain the same logical relationship, which is within the protection scope of the present patent; it is within the scope of the patent to add insignificant modifications to the algorithms or processes or to introduce insignificant design changes to the core design without changing the algorithms or processes.
A third embodiment of the present invention relates to a secure communication apparatus, as shown in fig. 4, including: a verification module 41, a symmetric key generation module 42 and a communication module 43.
And the verifying module 41 is used for verifying whether the public key of the CA is complete and whether the digital signature of the CA is valid.
And a symmetric key generation module 42, configured to generate a symmetric key between the CA and the TA through three-way handshake after verifying that the public key of the CA is complete and the digital signature of the CA is valid.
And a communication module 43, configured to perform encrypted communication between the CA and the TA according to the symmetric key.
It should be understood that this embodiment is a system example corresponding to the first embodiment, and may be implemented in cooperation with the first embodiment. The related technical details mentioned in the first embodiment are still valid in this embodiment, and are not described herein again in order to reduce repetition. Accordingly, the related-art details mentioned in the present embodiment can also be applied to the first embodiment.
It should be noted that each module referred to in this embodiment is a logical module, and in practical applications, one logical unit may be one physical unit, may be a part of one physical unit, and may be implemented by a combination of multiple physical units. In addition, in order to highlight the innovative part of the present invention, elements that are not so closely related to solving the technical problems proposed by the present invention are not introduced in the present embodiment, but this does not indicate that other elements are not present in the present embodiment.
A fourth embodiment of the present invention relates to a secure communication apparatus. The fourth embodiment is further improved on the basis of the third embodiment, and the main improvement lies in that: in the fourth embodiment of the present invention, the authentication module 41, the symmetric key generation module 42, and the communication module 43 are included, and the authentication module further includes: a CA saving module 44, a first summary calculating module 45, and a first summary sending module 46, wherein the detecting module 41 specifically includes: the digest detection submodule 411, the digital signature detection submodule 412, and the determination submodule 413, and the module 42 for generating a symmetric key specifically includes: a first CA sending submodule 421, a TA sending submodule 422, a second CA sending submodule 423, a CA key generating submodule 424, and a TA key generating submodule 425, as shown in fig. 5.
And the CA storage module 44 is configured to store the public key and the digital signature generated according to the private key of the CA, where the public key and the private key are a public-private key pair generated according to a preset digital signature algorithm.
The first abstract calculating module 45 is configured to calculate the first abstract according to a preset abstract algorithm by the rich execution environment operating system.
A first digest sending module 46, configured to send the first digest to the trusted execution environment operating system.
And the verifying module 41 is used for verifying whether the public key of the CA is complete and whether the digital signature of the CA is valid.
The digest detection sub-module 411 is configured to detect, by the operating system of the trusted execution environment, whether the first digest of the public key of the CA is identical to the second digest stored in the TA.
And the digital signature verification sub-module 412 is configured to verify, by the rich execution environment operating system, whether the digital signature of the CA is valid according to the public key when the first digest is the same as the second digest.
A determination submodule 413 configured to determine that the CA is complete when the digital signature verification of the CA is valid.
And a symmetric key generation module 42, configured to generate a symmetric key between the CA and the TA through three-way handshake after verifying that the public key of the CA is complete and the digital signature of the CA is valid.
The first CA sending sub-module 421 is configured to send the generated first random number, the algorithm list of the symmetric encryption algorithm and the message authentication code algorithm by the CA.
And the TA sending submodule 422 is configured to send the identifier of the algorithm in the selected algorithm list, the generated public key of the RSA public and private key pair, and the generated second random number by the TA.
And a second CA transmission sub-module 423 for transmitting the third random number encrypted according to the RSA public key by the CA.
Specifically, in practical applications, the first CA transmission sub-module 421 and the second CA transmission sub-module 423 may be combined together or separated.
The CA key generation sub-module 424 is configured to generate a CA key of a symmetric key according to the first random number, the second random number, and the third random number.
The TA key generation sub-module 425 is configured to generate a TA key of the symmetric key according to the first random number, the second random number, and the third random number.
And a communication module 43, configured to perform encrypted communication between the CA and the TA according to the symmetric key.
Since the second embodiment corresponds to the present embodiment, the present embodiment can be implemented in cooperation with the second embodiment. The related technical details mentioned in the second embodiment are still valid in this embodiment, and the technical effects that can be achieved in the second embodiment can also be achieved in this embodiment, and are not described herein again in order to reduce the repetition. Accordingly, the related-art details mentioned in the present embodiment can also be applied to the second embodiment.
Those skilled in the art can understand that all or part of the steps in the method of the foregoing embodiments may be implemented by a program to instruct related hardware, where the program is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, etc.) or a processor (processor) to execute all or part of the steps of the method described in the embodiments of the present application. And the aforementioned storage medium includes: flash Memory (Flash Memory), a Flash disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, an optical disk, or other various media capable of storing program codes.
It will be understood by those of ordinary skill in the art that the foregoing embodiments are specific examples for carrying out the invention, and that various changes in form and details may be made therein without departing from the spirit and scope of the invention in practice.

Claims (4)

1. A method for secure communication, wherein a client application CA applied to a same terminal device and a trusted application TA corresponding to the CA comprise:
verifying whether the public key of the CA is complete and whether the digital signature of the CA is valid specifically includes: the CA stores a public key and a digital signature generated according to a private key of the CA, wherein the public key and the private key are a public and private key pair generated according to a preset digital signature algorithm; the rich execution environment operating system calculates a first abstract of a public key of a CA (conditional access) according to a preset abstract algorithm, and sends the first abstract of the public key of the CA to the trusted execution environment operating system; the trusted execution environment operating system detects whether a first abstract of a public key of the CA is the same as a second abstract stored in the TA, wherein the second abstract is the second abstract of the public key generated according to the preset abstract algorithm; if the first abstract is the same as the second abstract, the rich execution environment operating system verifies whether the digital signature of the CA is valid according to the public key; if the digital signature of the CA is valid, the CA is complete;
and if the public key of the CA is complete and the digital signature of the CA is valid, the CA and the TA generate a symmetric key through three-way handshake, and carry out encryption communication according to the symmetric key.
2. The method according to claim 1, wherein the CA and the TA generate the symmetric key through three-way handshake, specifically comprising:
the CA sends the generated first random number and an algorithm list of a symmetric encryption algorithm and a message authentication code algorithm;
the TA sends the selected identifier of the algorithm in the algorithm list, the generated public key of the RSA public and private key pair and the generated second random number;
the CA sends a third random number encrypted according to the RSA public key;
and the CA and the TA respectively generate the symmetric key according to the first random number, the second random number and the third random number.
3. A secure communication device, wherein a client application CA and a trusted application TA corresponding to the CA are applied to the same terminal device, the secure communication device comprising:
the verification module is used for verifying whether the public key of the CA is complete and whether the digital signature of the CA is valid;
the symmetric key generation module is used for generating a symmetric key of the CA and the TA through three-way handshake after verifying that the public key of the CA is complete and the digital signature of the CA is valid;
a communication module, configured to perform encrypted communication between the CA and the TA according to the symmetric key;
wherein the verification module specifically comprises: the device comprises a digest detection submodule, a digital signature verification submodule and a determination submodule;
the digest detection submodule is used for a trusted execution environment operating system to detect whether a first digest of a public key of the CA is the same as a second digest stored in the TA;
the digital signature verification submodule is used for verifying whether the digital signature of the CA is valid or not according to the public key when the first abstract is the same as the second abstract by the rich execution environment operating system;
the determining submodule is used for determining that the CA is complete when the digital signature of the CA is verified to be valid;
the apparatus further comprises: the system comprises a first abstract calculation module, a first abstract sending module and a CA storage module;
the first abstract calculation module is used for calculating a first abstract of the public key of the CA by the rich execution environment operating system according to a preset abstract algorithm;
the first digest sending module is configured to send a first digest of the public key of the CA to the trusted execution environment operating system;
the CA storage module is used for storing the public key and a digital signature generated according to a private key of the CA by the CA, wherein the public key and the private key are a public and private key pair generated according to a preset digital signature algorithm.
4. The secure communications device of claim 3, wherein the module for generating a symmetric key specifically comprises: the first CA sending submodule, the TA sending submodule, the second CA sending submodule, the CA key generating submodule and the TA key generating submodule;
the first CA sending submodule is used for the CA to send the generated first random number, the algorithm list of the symmetric encryption algorithm and the message authentication code algorithm;
the TA sending submodule is used for sending the selected identifier of the algorithm in the algorithm list, the generated public key of the RSA public and private key pair and the generated second random number by the TA;
the second CA sending submodule is used for sending a third random number encrypted according to the RSA public key by the CA;
the CA key generation submodule is used for generating a CA key of the symmetric key according to the first random number, the second random number and the third random number;
and the TA key generation submodule is used for generating the TA key of the symmetric key according to the first random number, the second random number and the third random number.
CN201611221027.9A 2016-12-26 2016-12-26 Method and apparatus for secure communication Active CN108242997B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611221027.9A CN108242997B (en) 2016-12-26 2016-12-26 Method and apparatus for secure communication

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611221027.9A CN108242997B (en) 2016-12-26 2016-12-26 Method and apparatus for secure communication

Publications (2)

Publication Number Publication Date
CN108242997A CN108242997A (en) 2018-07-03
CN108242997B true CN108242997B (en) 2020-12-22

Family

ID=62702276

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611221027.9A Active CN108242997B (en) 2016-12-26 2016-12-26 Method and apparatus for secure communication

Country Status (1)

Country Link
CN (1) CN108242997B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109508562B (en) * 2018-11-30 2022-03-25 四川长虹电器股份有限公司 TEE-based trusted remote verification method
CN112351037A (en) * 2020-11-06 2021-02-09 支付宝(杭州)信息技术有限公司 Information processing method and device for secure communication

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104010044A (en) * 2014-06-12 2014-08-27 北京握奇数据系统有限公司 Application limitation installing method, manager and terminal based on trusted execution environment technology
CN104125226A (en) * 2014-07-28 2014-10-29 北京握奇智能科技有限公司 Locking and unlocking application method, device and system
CN105260663A (en) * 2015-09-15 2016-01-20 中国科学院信息工程研究所 Secure storage service system and method based on TrustZone technology
CN105653412A (en) * 2015-12-31 2016-06-08 深圳市金立通信设备有限公司 Fingerprint device compatibility detection method and terminal
CN106156618A (en) * 2015-04-17 2016-11-23 国民技术股份有限公司 A kind of safety chip, mobile terminal and the method realizing mobile terminal system safety

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102327782B1 (en) * 2015-05-29 2021-11-18 한국과학기술원 Electronic device and method for approaching to kernel data

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104010044A (en) * 2014-06-12 2014-08-27 北京握奇数据系统有限公司 Application limitation installing method, manager and terminal based on trusted execution environment technology
CN104125226A (en) * 2014-07-28 2014-10-29 北京握奇智能科技有限公司 Locking and unlocking application method, device and system
CN106156618A (en) * 2015-04-17 2016-11-23 国民技术股份有限公司 A kind of safety chip, mobile terminal and the method realizing mobile terminal system safety
CN105260663A (en) * 2015-09-15 2016-01-20 中国科学院信息工程研究所 Secure storage service system and method based on TrustZone technology
CN105653412A (en) * 2015-12-31 2016-06-08 深圳市金立通信设备有限公司 Fingerprint device compatibility detection method and terminal

Also Published As

Publication number Publication date
CN108242997A (en) 2018-07-03

Similar Documents

Publication Publication Date Title
US11323276B2 (en) Mutual authentication of confidential communication
US10652015B2 (en) Confidential communication management
US9847880B2 (en) Techniques for ensuring authentication and integrity of communications
US20160119291A1 (en) Secure communication channel with token renewal mechanism
US7693286B2 (en) Method of delivering direct proof private keys in signed groups to devices using a distribution CD
US20180204004A1 (en) Authentication method and apparatus for reinforced software
JP2009500905A (en) Secure patch system
CN107317677B (en) Secret key storage and equipment identity authentication method and device
US20160182230A1 (en) Secure token-based signature schemes using look-up tables
CN110519309B (en) Data transmission method, device, terminal, server and storage medium
CN110401615B (en) Identity authentication method, device, equipment, system and readable storage medium
CN110493197B (en) Login processing method and related equipment
KR20200037847A (en) NFC tag authentication to remote servers with applications to protect supply chain asset management
CN108242997B (en) Method and apparatus for secure communication
CN111614621A (en) Internet of things communication method and system
CN109905384B (en) Data migration method and system
CN112929871A (en) OTA upgrade package acquisition method, electronic device and storage medium
CN111338841A (en) Data processing method, device, equipment and storage medium
US11177933B2 (en) Side channel timing attack mitigation in securing data in transit
KR102005787B1 (en) Method for Encrypting Certificate
CN109104393B (en) Identity authentication method, device and system
CN114240428A (en) Data transmission method and device, data transaction terminal and data supplier
CN114189862A (en) Wireless terminal and interface access authentication method of wireless terminal in Uboot mode
CN114692218A (en) Electronic signature method, equipment and system for individual user
CN110555311A (en) Electronic signature system security design method and system based on pure soft cryptographic operation

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