WO2019233204A1 - Method, apparatus and system for key management, storage medium, and computer device - Google Patents

Method, apparatus and system for key management, storage medium, and computer device Download PDF

Info

Publication number
WO2019233204A1
WO2019233204A1 PCT/CN2019/083875 CN2019083875W WO2019233204A1 WO 2019233204 A1 WO2019233204 A1 WO 2019233204A1 CN 2019083875 W CN2019083875 W CN 2019083875W WO 2019233204 A1 WO2019233204 A1 WO 2019233204A1
Authority
WO
WIPO (PCT)
Prior art keywords
certificate
application
authentication
key
public key
Prior art date
Application number
PCT/CN2019/083875
Other languages
French (fr)
Chinese (zh)
Inventor
晏鹏
白广元
Original Assignee
腾讯科技(深圳)有限公司
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 腾讯科技(深圳)有限公司 filed Critical 腾讯科技(深圳)有限公司
Priority to JP2020546477A priority Critical patent/JP7297360B2/en
Publication of WO2019233204A1 publication Critical patent/WO2019233204A1/en
Priority to US16/926,317 priority patent/US11516020B2/en

Links

Images

Classifications

    • 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/3263Cryptographic 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 certificates, e.g. public key certificate [PKC] or attribute certificate [AC]; Public key infrastructure [PKI] arrangements
    • H04L9/3265Cryptographic 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 certificates, e.g. public key certificate [PKC] or attribute certificate [AC]; Public key infrastructure [PKI] arrangements using certificate chains, trees or paths; Hierarchical trust model
    • 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
    • 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/0894Escrow, recovery or storing of secret information, e.g. secret key escrow or cryptographic key storage
    • 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/30Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy
    • 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/3226Cryptographic 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 using a predetermined code, e.g. password, passphrase or PIN
    • H04L9/3231Biological data, e.g. fingerprint, voice or retina
    • 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/3263Cryptographic 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 certificates, e.g. public key certificate [PKC] or attribute certificate [AC]; Public key infrastructure [PKI] arrangements
    • 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/3263Cryptographic 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 certificates, e.g. public key certificate [PKC] or attribute certificate [AC]; Public key infrastructure [PKI] arrangements
    • H04L9/3268Cryptographic 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 certificates, e.g. public key certificate [PKC] or attribute certificate [AC]; Public key infrastructure [PKI] arrangements using certificate validation, registration, distribution or revocation, e.g. certificate revocation list [CRL]
    • 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/50Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using hash chains, e.g. blockchains or hash trees

Definitions

  • the present application relates to the field of computer technology, and in particular, to a key management method, device, system, storage medium, and computer device.
  • each device manufacturer needs to separately establish a server for key management.
  • the interactor who needs to use the device public key needs to request the device from the server.
  • the use of public keys results in complex and inefficient key management.
  • a key management method applied to a terminal includes:
  • signature data of the device certificate is generated by signing the device parameters and the device public key with an authentication private key of the certificate authentication server;
  • the device private key and the device certificate are stored in the secure area.
  • a key management device includes:
  • a generating module for generating a device key including a device public key and a device private key in a local security zone
  • a sending module configured to send a local device parameter and the device public key to a certificate authentication server
  • a receiving module configured to receive a device certificate fed back by the certificate authentication server; signature data of the device certificate is generated by signing the device parameters and the device public key using an authentication private key of the certificate authentication server;
  • a storage module configured to store the device private key and the device certificate in the secure area.
  • a key management system the system includes a terminal and a certificate authentication server;
  • the terminal is configured to generate a device key including a device public key and a device private key in a local security area; and send the local device parameters and the device public key to the certificate authentication server;
  • the certificate authentication server is configured to feed back a device certificate to the terminal; signature data of the device certificate is generated by signing the device parameters and the device public key with the authentication private key of the certificate authentication server;
  • the terminal is further configured to store the device private key and the device certificate in the secure area.
  • a computer-readable storage medium stores a computer program on the computer-readable storage medium.
  • the processor causes the processor to perform the following steps:
  • signature data of the device certificate is generated by signing the device parameters and the device public key with an authentication private key of the certificate authentication server;
  • the device private key and the device certificate are stored in the secure area.
  • a computer device includes a memory and a processor.
  • the memory stores a computer program.
  • the processor causes the processor to perform the following steps:
  • signature data of the device certificate is generated by signing the device parameters and the device public key with an authentication private key of the certificate authentication server;
  • the device private key and the device certificate are stored in the secure area.
  • the above-mentioned key management method, device, system, storage medium, and computer equipment, the generation of the device key, and the storage of the private key and the device certificate in the device key are all performed in a local security area, ensuring the device key And the security of the device certificate;
  • the signature data in the device certificate is generated by signing the local device parameters and the device public key with the authentication private key of the certificate authentication server, which enhances the validity and credibility of the device certificate;
  • the device certificate is directly stored locally, which avoids the complicated operation and inconvenience of the management and use of the key caused by storing the device public key in other devices different from the local, making the key management convenient and efficient.
  • a certificate verification method applied to a certificate authentication server includes:
  • the certificate chain includes an authentication certificate, a device certificate, and an application certificate;
  • the authentication private key corresponding to the authentication certificate is used to sign signature data for generating the device certificate, so
  • the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate;
  • the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to Decrypting the signature data of the application certificate;
  • the feedback indicates the verification result that the verification passes.
  • a certificate verification device includes:
  • a receiving module for receiving an application certificate verification request
  • An obtaining module configured to obtain a certificate chain corresponding to the application certificate verification request; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign and generate the device certificate
  • the signature public data of the authentication certificate is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate;
  • the device public key is used to decrypt the signature data of the application certificate;
  • a verification module configured to verify the device certificate and the application certificate according to an authentication public key of the authentication certificate in the certificate chain when an authentication certificate identical to the authentication certificate in the certificate chain exists locally;
  • a feedback module is used to indicate that the verification result is passed when the device certificate and the application certificate are both verified.
  • a computer-readable storage medium stores a computer program on the computer-readable storage medium.
  • the processor causes the processor to perform the following steps:
  • the certificate chain includes an authentication certificate, a device certificate, and an application certificate;
  • the authentication private key corresponding to the authentication certificate is used to sign signature data for generating the device certificate, so
  • the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate;
  • the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to Decrypting the signature data of the application certificate;
  • the feedback indicates the verification result that the verification passes.
  • a computer device includes a memory and a processor.
  • the memory stores a computer program.
  • the processor causes the processor to perform the following steps:
  • the certificate chain includes an authentication certificate, a device certificate, and an application certificate;
  • the authentication private key corresponding to the authentication certificate is used to sign signature data for generating the device certificate, so
  • the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate;
  • the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to Decrypting the signature data of the application certificate;
  • the feedback indicates the verification result that the verification passes.
  • the certificate chain corresponding to the application certificate verification request is directly obtained; since the authentication private key corresponding to the authentication certificate in the certificate chain is used for signature generation
  • the signature data of the device certificate, the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate, and the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key in the device certificate is used to decrypt
  • the signature data in the application certificate, that is, the device certificate and the application certificate are issued step by step based on the authentication certificate.
  • the device certificate and the application certificate can be verified according to the authentication certificate in the certificate chain, so that when the device certificate and the application certificate are both verified, the feedback indicates that the verification result is passed to ensure the validity and efficiency of the certificate verification.
  • FIG. 1 is an application environment diagram of a key management method in an embodiment
  • FIG. 2 is a schematic flowchart of a key management method according to an embodiment
  • FIG. 3 is a sequence diagram of issuing a device certificate in an embodiment
  • 5 is a sequence diagram of verifying an application certificate in an embodiment
  • FIG. 6 is a schematic diagram of the principle of key management in an embodiment
  • FIG. 7 is a schematic flowchart of a certificate verification method according to an embodiment
  • FIG. 8 is a module structure diagram of a key management apparatus in an embodiment
  • FIG. 9 is a module structure diagram of a key management apparatus in another embodiment.
  • FIG. 10 is a module structure diagram of a certificate verification device in an embodiment
  • FIG. 11 is a module structure diagram of a certificate verification device in another embodiment
  • FIG. 12 is an internal structural diagram of a computer device in an embodiment
  • FIG. 13 is an internal structural diagram of a computer device in another embodiment.
  • FIG. 1 is an application environment diagram of a key management method in an embodiment.
  • the key management method is applied to a key management system.
  • the key management system includes a terminal 110 and a server 120.
  • the server 120 includes at least a certificate authentication server 121, and may further include an application server 122 and / or a key management server 123.
  • the terminal 110 and the server 120 are connected through a network.
  • the terminal 110 is configured to execute the key management method.
  • the terminal 110 may be a desktop terminal or a mobile terminal, and the mobile terminal may be at least one of a terminal such as a mobile phone, a tablet computer, or a notebook computer.
  • the certificate authentication server 121 may be a CA (Certificate Authority Digital Certificate Authority) server or another type of server.
  • the application server 122 may be a server corresponding to an application running on the terminal 110, such as an instant communication server corresponding to an instant communication application.
  • the key management server 123 may be a TAM (Trusted ATTK Management
  • the terminal 110 may generate a device key including a device public key and a device private key in a local security area, and then send the local device parameters and the device public key to the certificate authentication server 121.
  • the certificate authentication server 121 can generate the signature data by signing the device parameters and the device public key using the authentication private key of the certificate authentication server, and obtain the device certificate of the terminal 110.
  • Terminal 110 stores the device private key and the device certificate in the secure area.
  • the terminal 110 may also generate an application key for the application in a local security area when the application key generation instruction triggered by the application running locally is obtained; the application key includes an application public key and an application private key.
  • the application's application parameters and application public key are signed by the device's private key, the application's application certificate is generated, the application private key and the application certificate are stored in the security zone, and the application's certificate chain is stored: Certificate, device certificate and application certificate.
  • the corresponding application server 122 performs certificate verification by the application server 122, or after the application server 122 forwards the certificate chain to the certificate authentication server 121, the certificate authentication server 121 performs certificate verification. Alternatively, after the certificate chain is forwarded to the key management server 123, the certificate authentication server 121 or the key management server 123 performs certificate verification.
  • the certificate verification method can also be applied to the application environment shown in FIG. 1.
  • the server 120 is configured to execute the certificate verification method.
  • the server 120 receives the application certificate verification request sent by the terminal 110, and obtains a certificate chain corresponding to the application certificate verification request. Because the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate; the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; The corresponding device private key is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate.
  • the server 120 can verify the device certificate and the application certificate according to the authentication public key of the authentication certificate in the certificate chain when there is an authentication certificate consistent with the authentication certificate in the certificate chain on the server 120; when the device certificate and the application certificate both pass At that time, the verification result indicating that the verification is passed is fed back to the terminal 110.
  • FIG. 2 is a schematic flowchart of a key management method according to an embodiment. This embodiment is described by using the key management method applied to the terminal 110 in FIG. 1 as an example. Referring to FIG. 2, the method includes the following steps:
  • S202 Generate a device key including a device public key and a device private key in a local security zone.
  • the security zone is a trusted execution environment independent of the operating system in the terminal.
  • the security zone may be TEE (Trusted Execution). It can be understood that the security zone is used to ensure that the data stored or processed inside the security zone is independent of the environment outside the security zone and is a trusted environment. For example, if the asymmetric key is generated in a secure area, everyone except the key owner (terminal manufacturer or application server) cannot obtain the private key in the asymmetric key.
  • the security area may also be other trusted areas within the terminal that can ensure data security, which is not limited in the embodiments of the present application.
  • the device key is used to verify the legitimacy of the terminal and ensure the security of data transmission.
  • the device key can also be called the terminal root key.
  • the device key of the terminal is an asymmetric key, including a device public key and a device private key. Data encrypted by the device's public key can be decrypted by the device's private key; data encrypted by the device's private key can be decrypted by the device's public key.
  • the device key may be an asymmetric key based on RSA-2048. Of course, the device key may also be another asymmetric key, which is not limited in this embodiment of the present application.
  • the transmission party needs to encrypt the transmitted data by using a key, so that only the receiver of the corresponding key can decrypt the encrypted data to obtain the data transmitted by the transmission party. .
  • the data transmitting party encrypts the transmitted data by using the device public key of the terminal. Since the device private key of the terminal is normally only owned by the terminal, Then only the terminal can decrypt the encrypted data through the device private key to obtain the data transmitted by the data transmitting party. Even if other devices can obtain the encrypted data, the encrypted private data cannot be successfully decrypted because the private key of the device of the terminal cannot be possessed, and the data transmitted by the data transmitting party cannot be obtained.
  • the device key may be ATTK (Attestation Key, terminal verification key), which is used to verify the legitimacy of the terminal.
  • ATTK Attestation Key, terminal verification key
  • One terminal has one and only one ATTK.
  • the device key may also be another key, which is not limited in the embodiment of the present application.
  • the security area of the terminal includes a key generation code, and by running the key generation code, a device key including a device public key and a device private key is generated in the security area.
  • a security zone is configured for the terminal.
  • the terminal is allowed to be shipped from the factory only after the security zone configured for the terminal passes the acceptance.
  • the key generation code may be written into the security area, and the key generation code may be used to generate the device public key and device private area in the security area. The device key of the key.
  • a security application may run in a secure area of the terminal.
  • the logical behavior and storage behavior of the security application are both security behaviors.
  • the terminal may generate a device key including a device public key and a device private key by running a security application in a secure area.
  • the security application may be a TA (Trusted Application) application.
  • the device parameters are data reflecting the identity of the terminal.
  • the device parameter may be a terminal identifier, which is used to uniquely identify a terminal, such as a terminal serial number.
  • the certificate authentication server is an authoritative server for authenticating digital certificates.
  • the digital certificate is used to prove that the user (device or application, etc.) listed in the certificate legally owns the public key (device public key or application public key, etc.) listed in the certificate.
  • the certificate authentication server can be a CA server, that is, a server of a digital certificate authority.
  • the terminal may read the local device parameters, that is, the device parameters of the terminal, and generate a device certificate signing request; and then send the read device parameters, the generated device public key, and the device certificate signing request to the corresponding Certificate authentication server.
  • S206 Receive the device certificate fed back by the certificate authentication server; the signature data of the device certificate is generated by signing the device parameters and the device public key with the authentication private key of the certificate authentication server.
  • the device certificate is a file issued by the certificate authentication server and includes the device public key owner information and the device public key.
  • the device public key owner information is the device parameter.
  • the device certificate can include the device public key owner information and the device public key in plain text, that is, the original data without signature processing; it can also include the device public key owner information and the device public key cipher text, which is the device public key Key owner information and data signed by the device's public key.
  • Signature data is data obtained by signing a piece of data with the signer's private key. That is, the certificate authentication server receives the device parameters and the device public key of the terminal, signs the device parameters and the device public key by using the authentication private key of the certificate authentication server to generate signature data, forms a device certificate, and feeds it back to the terminal.
  • the device certificate includes a device parameter, a device public key, and a ciphertext generated by signing the device parameter and the device public key by authenticating the private key.
  • the signature data of the device certificate may be only the cipher text; it may also be a combination of the device parameters, the device private key, and the cipher text.
  • the device certificate complies with the X.509 certificate standard.
  • the authentication certificates and application certificates involved in this application follow the X.509 certificate standard.
  • the authentication certificate, equipment certificate, and application certificate can also meet other certificate standards, which are not limited in the embodiments of the present application.
  • the certificate authentication server calculates the summary information of the device parameters and the device public key according to the signature algorithm agreed with the terminal, and then calculates it by using its own authentication private key pair.
  • the obtained digest information is encrypted to obtain signature data.
  • the method of extracting the digest information and encrypting and signing the digest information can not only ensure the immutability of the data, but also avoid the time consuming caused by encrypting and decrypting a large amount of data.
  • the device parameters and the device public key can also be signed in other ways, which is not limited in the embodiments of the present application.
  • CA server certificate authentication server
  • the terminal may store the device private key and the device certificate in a secure storage area in a secure area of the terminal before the terminal leaves the factory.
  • Secure storage area such as RPMB (Replay Protected Memory Block).
  • a device has one and only one device key. Then the device key and the device certificate can be stored correspondingly or separately.
  • the device private key and the device certificate can be stored at the same time; they can also be stored separately, that is, the device private key is stored after the device private key is generated, and the device certificate is stored after the device certificate is received.
  • the above steps S202 to S208 are completed on a secure and trusted environment inside the equipment production line.
  • the device certificate is issued through a certificate authentication server.
  • the certificate authentication server ensures the security and reliability of the device certificate. Since a large number of devices can share a single authentication certificate, the management and maintenance cost of the device key is reduced.
  • the terminal may also obtain an authentication certificate including an authentication public key corresponding to the authentication private key; use the authentication certificate and the device certificate as the certificate chain of the terminal; and store the certificate chain in a secure area. That is, for each certificate of the terminal, the terminal stores the certificate chain of the certificate in a secure area.
  • the above-mentioned key management method, the generation of the device key, and the storage of the device private key and the device certificate in the device key are all performed in a local security zone, ensuring the security of the device key and the device certificate;
  • the signature data in the device certificate is generated by signing the local device parameters and the device public key with the authentication private key of the certificate authentication server, which enhances the validity and credibility of the device certificate; moreover, the device certificate is directly stored locally It avoids the complicated operation and inconvenience of the management and use of the key caused by storing the device public key in other devices different from the local, making the key management convenient and efficient.
  • FIG. 3 shows a sequence diagram of issuing a device certificate in one embodiment.
  • the terminal before the terminal is shipped, the terminal generates a device key (ATTK) including a device public key and a device private key through a security application (TA) running in a security area (TEE).
  • the TEE is independent of the terminal's operating system.
  • the terminal stores the generated device private key in a TEE secure storage area, and sends a device certificate signing request to a certificate authentication server (CA server), and the device certificate signing request carries the device parameters of the terminal and the generated device public key.
  • CA server certificate authentication server
  • the CA server After receiving the device certificate signing request, the CA server signs the device parameters and the device public key of the terminal with its own authentication private key (the private key of the CA root certificate) to generate a device certificate, and then feeds back the generated device certificate to the terminal.
  • the terminal then stores the device certificate in the secure storage area of the TEE.
  • the key management method further includes: generating an application key of the application in a secure area when the application key generation instruction triggered by the application running locally is obtained; the application key includes the application public key and Application private key; in the security area, sign the application's application parameters and application public key with the device's private key to generate the application's application certificate; store the application private key and application certificate in the security area correspondingly.
  • the application key generation instruction is a computer program for instructing generation of an application key.
  • Application keys are data used to verify the legitimacy of applications and ensure the security of data transmission.
  • the application key is an asymmetric key and includes an application public key and an application private key. Data encrypted by the application public key can be decrypted by the application private key; data encrypted by the application private key can be decrypted by the application public key.
  • the application key may be an asymmetric key based on RSA-2048. Of course, the application key may also be another asymmetric key, which is not limited in this embodiment of the present application.
  • the application key may be an ASK (App Secure Key), which is used to verify the legitimacy of the application.
  • An application has one and only one ASK.
  • the application key may also be another key, which is not limited in the embodiment of the present application.
  • one or more applications can run on the terminal, and each application has its own application public key and application private key.
  • the peer end encrypts the transmitted data through the application public key of the application. Since the application private key of the application is normally only owned by the application itself, then only the application can The encrypted data is decrypted by applying the private key to obtain the data transmitted by the peer. Even if other applications can obtain the encrypted data, because they cannot own the application's application private key, the encrypted data cannot be decrypted successfully, and the data transmitted by the peer cannot be obtained.
  • the terminal when the terminal installs the application or runs the application for the first time, the terminal may obtain an application key generation instruction triggered by the application or an application key generation instruction triggered by the application installation code.
  • the terminal generates the application key of the application in the local security area, and signs the application parameters and the application public key of the application through the device's private key in the security area to generate the application's application certificate; Then store the application private key and application certificate in a secure area.
  • signing the application's application parameters and the application's public key with the device's private key to generate the application's application certificate includes: obtaining the application's application parameters and the application's public key summary information; encrypting the digest information with the device's private key. Get signature data; generate an application certificate for the application based on the encrypted signature data.
  • the digest information is the only fixed-length value corresponding to the data to which the digest information belongs. It is generated by an irreversible string transformation algorithm that operates on the data to which the digest information belongs.
  • the terminal may use an irreversible string transformation algorithm to use the application parameter and the application public key of the application as one piece of text information to generate summary information of the text information.
  • the irreversible string transformation algorithm may be a hash algorithm or other algorithms, which is not limited in this embodiment of the present application.
  • other methods can also be used to generate the application parameter and application public key summary information, which is not limited in this embodiment of the present application.
  • the terminal obtains signature data by encrypting the digest information with the private key of the device, and generates an application certificate of the application.
  • the application certificate can include the application public key owner information and the application public key plain text, that is, the original data without signature processing; it can also include the application public key owner information and the application public key cipher text, that is, the application public key Key owner information and data obtained by applying a public key signature.
  • application public key owner information is application parameters.
  • the digest information is encrypted.
  • the complete transmitted data is no longer encrypted, and encryption is avoided when the amount of data is large. The time consuming caused by the decryption and decryption process not only ensures data security, provides data processing efficiency, but also facilitates subsequent data processing processes.
  • the key management method further includes: obtaining an authentication certificate including an authentication public key corresponding to the authentication private key; using the authentication certificate, device certificate, and application certificate as an application certificate chain; and storing the certificate chain in a secure area .
  • the authentication certificate is a digital certificate held by a certificate authentication server. Because the certificate authentication server is an authoritative organization responsible for issuing and managing digital certificates, and as a trusted third party in e-commerce transactions, it bears the responsibility of checking the validity of public keys in the public key system. Then, the certificate is generally considered to be authoritative and trustworthy.
  • the certificate authentication server may be a CA server, and the authentication certificate may be a CA root certificate.
  • a certificate authentication server holds a CA root certificate, and the certificate authentication server performs a signature operation on the data to be signed according to the private key of the CA root certificate it holds.
  • the certificate authentication server may also hold multiple CA root certificates, which is not limited in this embodiment of the present application.
  • the certificate authentication server may issue the authentication certificate held by the certificate authentication server to the terminal.
  • the terminal can use the application certificate, the device certificate corresponding to the device public key corresponding to the device private key issuing the application certificate, and the authentication public key corresponding to the authentication private key that issued the device certificate
  • the authentication certificate constitutes a certificate chain of the application, and the certificate chain is stored in a secure area of the terminal.
  • the application certificate is issued based on the certificate authentication server, that is, the certificate chain of the application certificate is established based on the certificate authentication server.
  • the trust chain enhances the credibility of each certificate in the certificate chain.
  • the certificate chain of the certificate is established for each certificate, so that when the validity of the certificate is subsequently verified, the certificate chain of the certificate is carried in the verification request, and the validity of the certificate can be verified step by step;
  • the device public key needs to be transmitted to a server that specifically manages the key before requesting the server to verify the validity of the certificate.
  • the generation of the application key and the storage of the private key and the application certificate in the application key are all performed in a local security zone, ensuring the security of the application key and the application certificate.
  • the application certificate The signature data in is generated by the device private key signature, and the device certificate of the device public key corresponding to the device private key is issued by the certificate authentication server, which enhances the validity and credibility of the application certificate.
  • FIG. 4 shows a sequence diagram of issuing an application certificate in one embodiment.
  • an application can be run on a terminal. After the application is installed or run, an application key generation instruction can be triggered.
  • the terminal generates an application key (ASK) including an application public key and an application private key through a TA running on the TEE.
  • the terminal obtains the device private key from the secure storage area through TA, and uses the obtained device private key to sign the application's application parameters and application public key to generate an application certificate; and then stores the application private key and application certificate to the TEE security accordingly Storage area.
  • the terminal can also use the authentication certificate, device certificate, and application certificate as the certificate chain of the application; the certificate chain is stored in the secure area of the TEE.
  • the key management method further includes: generating an application certificate verification request corresponding to the application when receiving the biometric authentication authorization request triggered by the application; and corresponding the application certificate chain with the application certificate verification request, Send to the application server corresponding to the application; receive the verification result fed back by the application server after verifying the received certificate chain according to the authentication certificate stored on the application server; when the verification result indicates that the verification is passed, grant the application the right to perform biometric authentication.
  • the biometric authentication authorization request is used to request the authority to perform biometric authentication.
  • Biometric authentication is a technology in which computer equipment uses the biological characteristics inherent in natural persons to perform identity authentication. Biometric authentication such as fingerprint authentication, facial recognition authentication and iris recognition authentication.
  • the application certificate verification request is used to request the validity verification of the application certificate.
  • the application requesting the terminal to grant the authority to perform biometric authentication is to request to obtain the biometric data inherent to the user stored in the terminal, such as fingerprint data or face data. Because this data is unique to the user's biological privacy. In order to protect the user's biological privacy, it needs to be granted only when the application has legal request permissions. In other words, only after the application certificate of the application passes the verification, the application can be granted the right to perform biometric authentication.
  • the application server receives the application certificate chain and the application certificate verification request.
  • the application server stores an authentication certificate
  • the received certificate chain is verified according to the authentication certificate, and the verification result is fed back to the terminal.
  • a biometric authentication authorization request is triggered through the instant messaging application.
  • the instant messaging application needs to send the certificate chain of the instant messaging application to the instant messaging server corresponding to the instant messaging application, and the instant messaging server verifies the validity of the certificate in the certificate chain, or the instant messaging server forwards it to Other servers verify the validity of the certificates in the certificate chain. Only after the legitimacy verification is passed, the terminal can grant the fingerprint communication payment permission to the instant messaging application.
  • the terminal when the terminal receives the biometric authentication authorization request triggered by the application, the terminal generates an application certificate verification request corresponding to the application, and sends the application certificate chain and the application certificate verification request to the application corresponding to the application. server.
  • the application server When the application server receives an application certificate verification request, it obtains the certificate chain carried by the application certificate verification request, and locally queries whether a certificate chain that is consistent with the authentication certificate in the certificate chain is stored. When the application server stores an authentication certificate consistent with the authentication certificate in the certificate chain, it is determined that the authentication certificate in the certificate chain is legal.
  • the application server then decrypts the signature data on the device certificate according to the authentication public key on the authentication certificate to obtain the first summary information, and extracts the second summary of the device parameters and the device public key on the device certificate according to the abstract information extraction method agreed with the terminal. Information, comparing the first summary information and the second summary information. When the two are inconsistent, the device certificate is determined to be illegal, and a verification result indicating the verification failure is fed back to the terminal.
  • the application server continues to decrypt the signature data on the application certificate to obtain the third summary information according to the device public key on the device certificate, and extracts the third summary information according to the abstract information extraction method agreed with the terminal. Compare the third summary information with the fourth summary information of the application parameters on the application certificate and the fourth summary information of the application public key. When the two are inconsistent, the device certificate is determined to be illegal, and a verification result indicating the verification failure is fed back to the terminal. When the third summary information and the fourth summary information are consistent, it is determined that the application certificate is valid, and a verification result indicating that the verification is passed is fed back to the terminal. In this way, the terminal grants the application the right to perform biometric authentication only when the received authentication result indicates that the authentication is passed.
  • the authentication certificate stored on the application server may be an authentication certificate held by each certificate authentication server obtained from each certificate authentication server through a secure channel in advance.
  • the secure channel is a data transmission channel that can ensure the security of data transmission, is a trusted channel, and may be a data transmission channel established based on the HTTPS protocol.
  • the application server may also obtain a list of revoked authentication certificates in advance. In this way, when the application server performs certificate chain authentication, it first checks whether the authentication certificate in the certificate chain exists in the list of revoked authentication certificates. If the authentication certificate in the certificate chain exists in the list of revoked authentication certificates, it means that the authentication certificate has expired and it is not necessary to perform subsequent certificate verification. If the certificate in the certificate chain does not exist in the list of revoked certificates, the subsequent certificate verification is continued. Among them, the list of revoked certificates is used to publicize invalid certificates.
  • the key management method further includes: receiving a verification result obtained from the certificate authentication server through a secure channel and fed back when the application server does not store the authentication certificate; the verification result is passed by the certificate authentication server through the secure channel. After receiving the certificate chain uploaded by the application server, the certificate chain is verified according to the authentication certificate stored on the certificate authentication server.
  • the certificate chain is transmitted to the certificate authentication server or key management server through a secure channel, and the certificate authentication server or key The management server verifies the legitimacy of each certificate in the certificate chain, feeds the verification result back to the application server, and then the application server feeds back the terminal.
  • the process of the certificate authentication server or the key management server verifying the validity of each certificate in the certificate chain is similar to the process of the application server verifying the validity of each certificate in the certificate chain, and is not repeated here.
  • the validity of the certificate is verified by the certificate authentication server, and the credibility of the verification result is enhanced. Moreover, during the verification, the verification is performed according to the certificate chain, and the device is included in the certificate chain. The public key no longer needs to be uploaded in advance.
  • the application server usually, the application server only checks the validity of the certificate in a scenario with a low security level. In a scenario with a high security level, even if the application server stores an authentication certificate that is consistent with the authentication certificate in the certificate chain.
  • the application server should also transmit the certificate chain to the certificate authentication server or key management server through a secure channel, and the certificate authentication server or key management server should verify the validity of each certificate in the certificate chain. Scenarios with lower security levels include scenarios involving account opening, and scenarios with higher security levels include scenarios involving resource transfer (payment).
  • the terminal when the terminal receives the biometric authentication authorization request triggered by the application, the terminal determines the security level corresponding to the event requesting the biometric authentication authorization, and carries the security level in the generated application certificate verification request.
  • the application server determines whether the certificate validity verification is performed locally or by the certificate authentication server or the key management server according to the security level carried in the application certificate verification request.
  • the application server is configured with a processable security level in advance.
  • the security level carried in the application certificate verification request is a security level that the application server can process, the application server determines that the certificate validity verification is performed locally, otherwise it is determined that the certificate authentication server Or the key management server performs certificate validity verification.
  • the application server may forward the application certificate verification request to the certificate authentication server corresponding to the authentication certificate in the certificate chain after determining that the certificate authentication server or key management server performs the certificate validity verification; For other certificate authentication servers, the certificate authentication server forwarded to this time should obtain the authentic version of the authentication certificate in the certificate chain through the secure channel in advance.
  • the certificate validity check is performed by the application server.
  • the credibility of the verification result can be guaranteed to a certain extent, and on the other hand, multiple passes can be avoided. The risks and time consuming of data.
  • FIG. 5 shows a timing diagram of verifying an application certificate in one embodiment.
  • an application can be run on the terminal, and after the application is run, a biometric authorization request can be triggered.
  • the terminal detects the biometric authentication authorization request
  • the terminal obtains the application certificate chain from the secure storage area through the TA running on the TEE, and generates an application certificate verification request, and sends the obtained certificate chain and the application certificate verification request to the corresponding The application server corresponding to the application.
  • the application server After receiving the application certificate verification request, the application server locally queries whether an authentication certificate consistent with the authentication certificate in the certificate chain is stored.
  • CA certificate authentication server
  • TAM key management server
  • FIG. 6 shows a principle architecture diagram of key management in one embodiment.
  • the terminal may store an authentication certificate (CAROOT), an equipment certificate (ATTK) issued by the authentication certificate, an application certificate (ASK) issued by the equipment certificate, and an application certificate (AKAuthentication Key) issued by the application certificate.
  • the certificate (CAROOT) is the source certificate chain; the certificate authentication server (CA) or the key management server (TAM) stores the certificate (CAROOT).
  • CA certificate authentication server
  • TAM key management server
  • the application private key corresponding to the application certificate is used to sign the signature data of the service certificate, and the application public key of the application certificate is used to decrypt the signature data of the service certificate.
  • the service key may be AK (Authentication Key), which is used to verify the legitimacy of the service.
  • FIG. 7 is a schematic flowchart of a certificate verification method according to an embodiment. This embodiment mainly uses the certificate verification method applied to the server 120 in FIG. 1 as an example for illustration. Referring to FIG. 7, the certificate verification method includes the following steps:
  • the server is an application server.
  • the terminal when the terminal receives the biometric authentication authorization request triggered by the application, the terminal generates an application certificate verification request corresponding to the application, and sends the application certificate chain and the application certificate verification request to the application corresponding to the application. server. In this way, the application server receives the application certificate verification request.
  • the server is a certificate authentication server or a key management server.
  • the application server forwards the application certificate verification request to the certificate authentication server or key management server through a secure channel; or, the application server
  • the application certificate verification request is forwarded to the certificate authentication server or key management server through a secure channel; in this way, the certificate authentication server or key
  • the management server receives the application certificate verification request.
  • the certificate chain includes an authentication certificate, a device certificate, and an application certificate.
  • the authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate.
  • the authentication public key is used for the authentication certificate. It is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate.
  • the next-level certificate is issued in the terminal's security zone one by one to ensure that the chain of trust is based on the authentication certificate.
  • the certificate chain of each certificate includes not only the certificate itself, but also the certificates issued from the source to obtain the certificate.
  • the certificate chain of a device certificate includes an authentication certificate and a device certificate
  • the certificate chain of an application certificate includes an authentication certificate, a device certificate, and an application certificate
  • the certificate chain of a service certificate includes an authentication certificate, a device certificate, an application certificate, and a service certificate.
  • S706 When an authentication certificate identical to the authentication certificate in the certificate chain exists locally, verify the device certificate and the application certificate according to the authentication public key of the authentication certificate in the certificate chain.
  • the server when an authentication certificate identical to the authentication certificate in the certificate chain is stored on the server, it is determined that the authentication certificate in the certificate chain is legal.
  • the server then decrypts the signature data on the device certificate to obtain the first summary information according to the authentication public key on the authentication certificate, and extracts the second summary information of the device parameters and the device public key on the device certificate according to the summary information extraction method agreed with the terminal. Compare the first summary information and the second summary information. When the two are inconsistent, the device certificate is determined to be illegal, and a verification result indicating the verification failure is fed back to the terminal.
  • the server continues to decrypt the signature data on the application certificate according to the device public key on the device certificate to obtain the third summary information, and extracts the application according to the summary information extraction method agreed with the terminal. Compare the third summary information and the fourth summary information with the application parameters and the fourth summary information of the application public key on the certificate. When the two are inconsistent, the device certificate is determined to be illegal, and a verification result indicating the verification failure is fed back to the terminal. When the third summary information and the fourth summary information are consistent, it is determined that the application certificate is valid, and a verification result indicating that the verification is passed is fed back to the terminal.
  • the application server obtains the authentication certificate of each certificate authentication server from the certificate authentication server through a secure channel in advance.
  • the application can be granted the right to perform biometric authentication only when each certificate in the certificate chain is verified. As long as the validity of a certificate in the certificate chain is not verified, the application cannot be granted the right to perform biometric authentication.
  • the certificate chain corresponding to the application certificate verification request is directly obtained; since the authentication private key corresponding to the authentication certificate in the certificate chain is used to sign the signature data of the device certificate, the authentication certificate
  • the authentication public key is used to decrypt the signature data of the device certificate
  • the device private key corresponding to the device certificate is used to sign the signature data of the application certificate.
  • the device public key in the device certificate is used to decrypt the signature data in the application certificate. That is, the device certificate and application certificate are issued step by step based on the authentication certificate.
  • the authentication certificate verifies the device certificate and the application certificate, so that when the device certificate and the application certificate are both verified, the feedback indicates that the verification result is passed to ensure the validity and efficiency of the certificate verification.
  • S706 includes: querying the certification certificate in the certificate chain in the list of revoked certification certificates; when the certification certificate in the certificate chain does not exist in the list of revoked certification certificates, querying the certification certificate in the certificate chain locally. Consistent authentication certificate; when querying the authentication certificate that is consistent with the authentication certificate in the certificate chain, verify the device certificate according to the authentication public key of the authentication certificate in the certificate chain; when the device certificate passes the authentication, the device public key of the device certificate Verify application certificate.
  • the certificate verification method further includes: receiving the device parameters and the device public key; obtaining the digest information of the device parameters and the device public key; encrypting the digest information by authenticating the private key to obtain signature data; and generating the encrypted signature data based on the encrypted signature data Equipment certification and feedback.
  • Both the key management method and the certificate verification method in the embodiments of the present application can be applied to a biometric authentication standard.
  • Biological certification standards such as the SOTER standard developed by Tencent.
  • the terminal After applying the method in the embodiment of the present application to the SOTER standard, the terminal does not need to upload devices ATTK to TAM one by one on the production line in advance, and it can also be supported by the SOTER standard, which further facilitates the access to SOTER's OEM ) Vendor.
  • a key management apparatus 800 is provided.
  • the key management apparatus 800 includes: a generating module 801, a sending module 802, a receiving module 803, and a storage module 804.
  • a generating module 801 is configured to generate a device key including a device public key and a device private key in a local security zone.
  • the sending module 802 is configured to send a local device parameter and a device public key to a certificate authentication server.
  • the receiving module 803 is configured to receive the device certificate fed back by the certificate authentication server; the signature data of the device certificate is generated by signing the device parameters and the device public key with the authentication private key of the certificate authentication server.
  • the storage module 804 is configured to store the device private key and the device certificate in a secure area.
  • the generating module 801 is further configured to generate an application key of the application in a secure area when the application key generation instruction triggered by the application running locally is obtained; the application key includes the application public key and the application Private key; in a secure area, sign the application's application parameters and application public key with the device's private key to generate an application's application certificate.
  • the storage module 804 is further configured to correspondingly store the application private key and the application certificate in a secure area.
  • the generating module 801 is further configured to obtain the application parameters of the application and the digest information of the application public key; obtain the signature data by encrypting the digest information with the device private key; and generate the application certificate of the application according to the encrypted signature data.
  • the storage module 804 is further configured to obtain an authentication certificate including an authentication public key corresponding to the authentication private key; use the authentication certificate, device certificate, and application certificate as an application certificate chain; and store the certificate chain in a secure area.
  • the key management device 800 further includes: an authorization module 805 configured to generate an application certificate verification request corresponding to the application when a biometric authentication authorization request triggered by the application is received; Send the application certificate chain and application certificate verification request to the application server corresponding to the application; receive the verification result fed back by the application server after verifying the received certificate chain according to the authentication certificate stored on the application server; when the verification result indicates When the verification is passed, the application is granted the right to perform biometric authentication.
  • an authorization module 805 configured to generate an application certificate verification request corresponding to the application when a biometric authentication authorization request triggered by the application is received
  • Send the application certificate chain and application certificate verification request to the application server corresponding to the application
  • the authorization module 805 is further configured to receive the verification result obtained from the certificate authentication server through the secure channel and fed back when the application server does not store the authentication certificate; the verification result is received by the certificate authentication server through the secure channel. After the certificate chain uploaded by the application server, the certificate chain is verified according to the authentication certificate stored on the certificate authentication server.
  • a certificate verification apparatus 1000 is provided.
  • the certificate verification apparatus 1000 includes a receiving module 1001, an obtaining module 1002, a verification module 1003, and a feedback module 1004.
  • the receiving module 1001 is configured to receive an application certificate verification request.
  • the obtaining module 1002 is configured to obtain a certificate chain corresponding to an application certificate verification request.
  • the certificate chain includes an authentication certificate, a device certificate, and an application certificate.
  • the authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate.
  • the authentication public key is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate.
  • the verification module 1003 is configured to verify the device certificate and the application certificate according to the authentication public key of the authentication certificate in the certificate chain when an authentication certificate identical to the authentication certificate in the certificate chain exists locally.
  • the feedback module 1004 is configured to, when the device certificate and the application certificate both pass the verification, the feedback indicates the verification result that the verification passes.
  • the verification module 1003 is further configured to query the certificate in the certificate chain in the list of revoked certificates; when the certificate in the certificate chain does not exist in the list of revoked certificates, query locally and in the certificate chain When the authentication certificate that is consistent with the authentication certificate in the certificate chain is found, the device certificate is verified according to the authentication public key of the authentication certificate in the certificate chain; when the device certificate is verified, the device certificate is verified according to the Device public key verification application certificate.
  • the certificate verification device 1000 further includes: a signing module 1005 for receiving device parameters and a device public key; obtaining summary information of the device parameters and the device public key; and encrypting the summary by authenticating the private key.
  • the information obtains signature data; a device certificate is generated and fed back based on the encrypted signature data.
  • FIG. 12 shows an internal structure diagram of a computer device in one embodiment.
  • the computer device may be the terminal 110 in FIG. 1.
  • the computer device includes a processor, a memory, a network interface, an input device, and a display screen connected through a system bus.
  • the memory includes a non-volatile storage medium and an internal memory.
  • the non-volatile storage medium of the computer device stores an operating system and a computer program.
  • the processor can implement the key management method.
  • a computer program may also be stored in the internal memory, and when the computer program is executed by the processor, the processor may execute the key management method.
  • the display screen of a computer device may be a liquid crystal display or an electronic ink display, etc.
  • the input device may be a touch layer covered on the display screen, or a button, a trackball or a touchpad provided on the computer equipment shell, or it may be External keyboard, trackpad, or mouse.
  • FIG. 12 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied.
  • the specific computer equipment may be Include more or fewer parts than shown in the figure, or combine certain parts, or have a different arrangement of parts.
  • FIG. 13 shows an internal structure diagram of a computer device in one embodiment.
  • the computer device may be the server 120 in FIG. 1.
  • the computer device includes a processor, a memory, and a network interface connected through a system bus.
  • the memory includes a non-volatile storage medium and an internal memory.
  • the non-volatile storage medium of the computer device stores an operating system and a computer program.
  • the processor can implement a certificate verification method.
  • a computer program may also be stored in the internal memory, and when the computer program is executed by the processor, the processor may cause the processor to perform a certificate verification method.
  • FIG. 13 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied.
  • the specific computer equipment may be Include more or fewer parts than shown in the figure, or combine certain parts, or have a different arrangement of parts.
  • both the key management device and the certificate verification device provided in this application may be implemented in the form of a computer program.
  • the computer program may be run on a computer device as shown in FIG. 12 or 13.
  • the volatile storage medium may store various program modules constituting the key management device or the certificate verification device, such as the generating module 801, the sending module 802, the receiving module 803, and the storage module 804 shown in FIG.
  • the computer program composed of each program module causes the processor to execute the steps in the key management method or the certificate verification method of each embodiment of the application described in this specification.
  • the computer device shown in FIG. 12 may generate a device key including a device public key and a device private key in a local security area by using the generating module 801 in the key management apparatus 800 shown in FIG. 8.
  • the local device parameters and the device public key are sent to the certificate authentication server through the sending module 802.
  • the receiving module 803 receives the device certificate fed back by the certificate authentication server; the signature data of the device certificate is generated by signing the device parameters and the device public key with the authentication private key of the certificate authentication server.
  • the device private key and the device certificate are stored in the secure area through the storage module 804.
  • the computer device shown in FIG. 13 may receive the application certificate verification request through the receiving module 1001 in the certificate verification apparatus 1000 shown in FIG. 10.
  • the certificate chain includes an authentication certificate, a device certificate, and an application certificate;
  • the authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate, and the authentication public certificate
  • the key is used to decrypt the signature data of the device certificate;
  • the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate.
  • the authentication module 1003 When the authentication module 1003 locally has an authentication certificate consistent with the authentication certificate in the certificate chain, the device certificate and the application certificate are verified according to the authentication public key of the authentication certificate in the certificate chain. Through the feedback module 1004, when both the device certificate and the application certificate are verified to pass, the feedback indicates the verification result that the verification has passed.
  • a key management system including a terminal and a certificate authentication server.
  • the terminal is used to generate a device key including a device public key and a device private key in a local security area; and send the local device parameters and the device public key to a certificate authentication server.
  • the certificate authentication server is used to feed back the device certificate to the terminal; the signed data of the returned device certificate is generated by the certificate authentication server to sign the device parameters and the device public key according to the authentication private key of the certificate authentication server.
  • the terminal is also used to store the device private key and device certificate in a secure area.
  • the key management system further includes an application server.
  • the terminal is also used to generate the certificate chain of the application running locally; when receiving the biometric authentication authorization request triggered by the application, generating an application certificate verification request corresponding to the application; corresponding the application certificate chain with the application certificate verification request, Send to the application server corresponding to the application.
  • the application server is used to verify the received certificate chain according to the stored authentication certificate when the authentication certificate in the certificate chain is stored, and then feed back the verification result to the terminal.
  • the authentication certificate in the certificate chain is not stored, it passes the secure channel.
  • the certificate chain is passed to the certificate authentication server, and the verification result obtained by the certificate authentication server for the certificate chain verification is fed back from the certificate authentication server to the terminal.
  • the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate; the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; The corresponding device private key is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate.
  • the key management system further includes a key management server.
  • the application server is also used to pass the certificate chain to the certificate key management server through a secure channel when the authentication certificate in the certificate chain is not stored, and obtain the verification result obtained by the key management server for the certificate chain verification from the key management server. Feedback to the terminal.
  • the terminal is further configured to generate an application key of the application in a secure area when the application key generation instruction triggered by the application running locally is obtained;
  • the application key includes an application public key and an application private key
  • the application's application parameters and application public key are signed by the device's private key to generate the application's application certificate; the application private key and the application certificate are correspondingly stored in the secure area.
  • the terminal is further configured to obtain the application parameter of the application and the digest information of the application public key; obtain the signature data by encrypting the digest information with the device private key; and generate the application certificate of the application according to the encrypted signature data.
  • the terminal is further configured to obtain an authentication certificate including an authentication public key corresponding to the authentication private key; use the authentication certificate, device certificate, and application certificate as an application certificate chain; and store the certificate chain in a secure area.
  • the application server, key management server, or certificate authentication server is further configured to query the certificate in the certificate chain in the list of revoked certificates; when the certificate in the certificate chain does not exist in the list of revoked certificates , Query the authentication certificate that is consistent with the authentication certificate in the certificate chain locally; when querying the authentication certificate that is consistent with the authentication certificate in the certificate chain, verify the device certificate according to the authentication public key of the authentication certificate in the certificate chain; when the device certificate When the verification is passed, the application certificate is verified based on the device public key of the device certificate.
  • the certificate authentication server is further configured to receive the device parameters and the device public key; obtain the digest information of the device parameters and the device public key; encrypt the digest information by authenticating the private key to obtain signature data; and generate the device based on the encrypted signature data Certificate and feedback.
  • a computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor causes the processor to perform the steps described in the foregoing method embodiment.
  • a computer device which includes a memory and a processor.
  • the memory stores a computer program.
  • the processor is caused to perform the steps described in the foregoing method embodiment.
  • Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory.
  • Volatile memory can include random access memory (RAM) or external cache memory.
  • RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous chain Synchlink DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
  • SRAM static RAM
  • DRAM dynamic RAM
  • SDRAM synchronous DRAM
  • DDRSDRAM dual data rate SDRAM
  • ESDRAM enhanced SDRAM
  • SLDRAM synchronous chain Synchlink DRAM
  • Rambus direct RAM
  • DRAM direct memory bus dynamic RAM
  • RDRAM memory bus dynamic RAM

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Health & Medical Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Biodiversity & Conservation Biology (AREA)
  • Biomedical Technology (AREA)
  • General Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Storage Device Security (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The prevent invention relates to a method, apparatus and system for key management, a storage medium, and a computer device. The method for key management comprises: generating, in a local secure area, device keys including a device public key and a device private key; transmitting a local device parameter and the device public key to a certificate authority server; receiving a device certificate fed back by the certificate authority server, an authentication private key of the certificate authority server being used to encrypt the device parameter and the device public key so as to generate signature data of the device certificate; and storing the device private key and the device certificate in the secure area. The solution provided in the present invention enhances key management efficiency.

Description

密钥管理方法、装置、系统、存储介质和计算机设备Key management method, device, system, storage medium and computer equipment
本申请要求于2018年6月6日提交、申请号为201810574128.7、发明名称为“密钥管理方法、装置、系统、存储介质和计算机设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims priority from a Chinese patent application filed on June 6, 2018, with application number 201810574128.7, and the invention name is "Key Management Method, Apparatus, System, Storage Medium, and Computer Equipment", the entire contents of which are incorporated by reference. In this application.
技术领域Technical field
本申请涉及计算机技术领域,特别是涉及一种密钥管理方法、装置、系统、存储介质和计算机设备。The present application relates to the field of computer technology, and in particular, to a key management method, device, system, storage medium, and computer device.
背景技术Background technique
随着互联网技术的不断发展,越来越多的数据交互通过设备进行,由此用户对于设备验证安全性的要求越来越高。目前,通常需要设备厂商单独建立用于密钥管理的服务器,在设备出厂前,将设备公钥上传至该服务器存储。With the continuous development of Internet technology, more and more data interactions are carried out through devices, so users have higher and higher requirements for device authentication security. At present, it is usually required that a device manufacturer separately establishes a server for key management, and before the device leaves the factory, the device public key is uploaded to the server for storage.
然而,传统的这种密钥管理方式中,每个设备厂商都需要单独建立用于密钥管理的服务器,在需要数据交互时,需要使用设备公钥的交互方则需要从该服务器中请求设备公钥来使用,导致密钥管理复杂而低效。However, in the traditional key management method, each device manufacturer needs to separately establish a server for key management. When data interaction is required, the interactor who needs to use the device public key needs to request the device from the server The use of public keys results in complex and inefficient key management.
发明内容Summary of the Invention
基于此,有必要针对目前密钥管理复杂而低效的问题,提供一种密钥管理方法、装置、系统、存储介质和计算机设备。Based on this, it is necessary to provide a key management method, device, system, storage medium, and computer equipment in response to the current complex and inefficient key management.
一种密钥管理方法,应用于终端,所述方法包括:A key management method applied to a terminal, the method includes:
在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;Generate a device key including the device public key and device private key in the local security zone;
将本地的设备参数和所述设备公钥发送至证书认证服务器;Sending the local device parameters and the device public key to a certificate authentication server;
接收所述证书认证服务器反馈的设备证书;所述设备证书的签名数据,通过所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;Receiving a device certificate fed back by the certificate authentication server; signature data of the device certificate is generated by signing the device parameters and the device public key with an authentication private key of the certificate authentication server;
将所述设备私钥和所述设备证书存储于所述安全区域。The device private key and the device certificate are stored in the secure area.
一种密钥管理装置,所述装置包括:A key management device, the device includes:
生成模块,用于在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;A generating module for generating a device key including a device public key and a device private key in a local security zone;
发送模块,用于将本地的设备参数和所述设备公钥发送至证书认证服务器;A sending module, configured to send a local device parameter and the device public key to a certificate authentication server;
接收模块,用于接收所述证书认证服务器反馈的设备证书;所述设备证书的签名数据,通过所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;A receiving module, configured to receive a device certificate fed back by the certificate authentication server; signature data of the device certificate is generated by signing the device parameters and the device public key using an authentication private key of the certificate authentication server;
存储模块,用于将所述设备私钥和所述设备证书存储于所述安全区域。A storage module, configured to store the device private key and the device certificate in the secure area.
一种密钥管理系统,所述系统包括终端和证书认证服务器;其中,A key management system, the system includes a terminal and a certificate authentication server;
所述终端用于在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;将本地的设备参数和所述设备公钥发送至所述证书认证服务器;The terminal is configured to generate a device key including a device public key and a device private key in a local security area; and send the local device parameters and the device public key to the certificate authentication server;
所述证书认证服务器用于向所述终端反馈设备证书;所述设备证书的签名数据,通过所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;The certificate authentication server is configured to feed back a device certificate to the terminal; signature data of the device certificate is generated by signing the device parameters and the device public key with the authentication private key of the certificate authentication server;
所述终端还用于将所述设备私钥和所述设备证书存储于所述安全区域。The terminal is further configured to store the device private key and the device certificate in the secure area.
一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,所述计算机程序被处理器执行时,使得所述处理器执行以下步骤:A computer-readable storage medium stores a computer program on the computer-readable storage medium. When the computer program is executed by a processor, the processor causes the processor to perform the following steps:
在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;Generate a device key including the device public key and device private key in the local security zone;
将本地的设备参数和所述设备公钥发送至证书认证服务器;Sending the local device parameters and the device public key to a certificate authentication server;
接收所述证书认证服务器反馈的设备证书;所述设备证书的签名数据,通过所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;Receiving a device certificate fed back by the certificate authentication server; signature data of the device certificate is generated by signing the device parameters and the device public key with an authentication private key of the certificate authentication server;
将所述设备私钥和所述设备证书存储于所述安全区域。The device private key and the device certificate are stored in the secure area.
一种计算机设备,包括存储器和处理器,所述存储器中储存有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器执行以下步骤:A computer device includes a memory and a processor. The memory stores a computer program. When the computer program is executed by the processor, the processor causes the processor to perform the following steps:
在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;Generate a device key including the device public key and device private key in the local security zone;
将本地的设备参数和所述设备公钥发送至证书认证服务器;Sending the local device parameters and the device public key to a certificate authentication server;
接收所述证书认证服务器反馈的设备证书;所述设备证书的签名数据,通过所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;Receiving a device certificate fed back by the certificate authentication server; signature data of the device certificate is generated by signing the device parameters and the device public key with an authentication private key of the certificate authentication server;
将所述设备私钥和所述设备证书存储于所述安全区域。The device private key and the device certificate are stored in the secure area.
上述密钥管理方法、装置、系统、存储介质和计算机设备,设备密钥的生成以及设备密 钥中的私钥和设备证书的存储,都是在本地的安全区域中进行,保证了设备密钥和设备证书的安全性;其次,设备证书中的签名数据,是通过证书认证服务器的认证私钥对本地的设备参数和设备公钥签名生成的,增强了设备证书的有效性与可信度;而且,设备证书是直接存储在本地,避免了将设备公钥存储在异于本地的其他设备中导致密钥在管理和使用上的复杂操作和不便,使得密钥管理便捷且高效。The above-mentioned key management method, device, system, storage medium, and computer equipment, the generation of the device key, and the storage of the private key and the device certificate in the device key are all performed in a local security area, ensuring the device key And the security of the device certificate; secondly, the signature data in the device certificate is generated by signing the local device parameters and the device public key with the authentication private key of the certificate authentication server, which enhances the validity and credibility of the device certificate; Moreover, the device certificate is directly stored locally, which avoids the complicated operation and inconvenience of the management and use of the key caused by storing the device public key in other devices different from the local, making the key management convenient and efficient.
一种证书验证方法,应用于证书认证服务器,所述方法包括:A certificate verification method applied to a certificate authentication server. The method includes:
接收应用证书验证请求;Receiving an application certificate verification request;
获取对应于所述应用证书验证请求的证书链;所述证书链包括认证证书、设备证书和应用证书;所述认证证书所对应的认证私钥用于签名生成所述设备证书的签名数据,所述认证证书的认证公钥用于解密所述设备证书的签名数据;所述设备证书所对应的设备私钥用于签名生成所述应用证书的签名数据,所述设备证书的设备公钥用于解密所述应用证书的签名数据;Obtaining a certificate chain corresponding to the application certificate verification request; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign signature data for generating the device certificate, so The authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to Decrypting the signature data of the application certificate;
在本地存在与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书和所述应用证书;When an authentication certificate identical to the authentication certificate in the certificate chain exists locally, verifying the device certificate and the application certificate according to an authentication public key of the authentication certificate in the certificate chain;
当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。When both the device certificate and the application certificate pass, the feedback indicates the verification result that the verification passes.
一种证书验证装置,所述装置包括:A certificate verification device, the device includes:
接收模块,用于接收应用证书验证请求;A receiving module for receiving an application certificate verification request;
获取模块,用于获取对应于所述应用证书验证请求的证书链;所述证书链包括认证证书、设备证书和应用证书;所述认证证书所对应的认证私钥用于签名生成所述设备证书的签名数据,所述认证证书的认证公钥用于解密所述设备证书的签名数据;所述设备证书所对应的设备私钥用于签名生成所述应用证书的签名数据,所述设备证书的设备公钥用于解密所述应用证书的签名数据;An obtaining module, configured to obtain a certificate chain corresponding to the application certificate verification request; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign and generate the device certificate The signature public data of the authentication certificate is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate; The device public key is used to decrypt the signature data of the application certificate;
验证模块,用于在本地存在与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书和所述应用证书;A verification module, configured to verify the device certificate and the application certificate according to an authentication public key of the authentication certificate in the certificate chain when an authentication certificate identical to the authentication certificate in the certificate chain exists locally;
反馈模块,用于当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。A feedback module is used to indicate that the verification result is passed when the device certificate and the application certificate are both verified.
一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,所述计算机 程序被处理器执行时,使得所述处理器执行以下步骤:A computer-readable storage medium stores a computer program on the computer-readable storage medium. When the computer program is executed by a processor, the processor causes the processor to perform the following steps:
接收应用证书验证请求;Receiving an application certificate verification request;
获取对应于所述应用证书验证请求的证书链;所述证书链包括认证证书、设备证书和应用证书;所述认证证书所对应的认证私钥用于签名生成所述设备证书的签名数据,所述认证证书的认证公钥用于解密所述设备证书的签名数据;所述设备证书所对应的设备私钥用于签名生成所述应用证书的签名数据,所述设备证书的设备公钥用于解密所述应用证书的签名数据;Obtaining a certificate chain corresponding to the application certificate verification request; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign signature data for generating the device certificate, so The authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to Decrypting the signature data of the application certificate;
在本地存在与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书和所述应用证书;When an authentication certificate identical to the authentication certificate in the certificate chain exists locally, verifying the device certificate and the application certificate according to an authentication public key of the authentication certificate in the certificate chain;
当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。When both the device certificate and the application certificate pass, the feedback indicates the verification result that the verification passes.
一种计算机设备,包括存储器和处理器,所述存储器中储存有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器执行以下步骤:A computer device includes a memory and a processor. The memory stores a computer program. When the computer program is executed by the processor, the processor causes the processor to perform the following steps:
接收应用证书验证请求;Receiving an application certificate verification request;
获取对应于所述应用证书验证请求的证书链;所述证书链包括认证证书、设备证书和应用证书;所述认证证书所对应的认证私钥用于签名生成所述设备证书的签名数据,所述认证证书的认证公钥用于解密所述设备证书的签名数据;所述设备证书所对应的设备私钥用于签名生成所述应用证书的签名数据,所述设备证书的设备公钥用于解密所述应用证书的签名数据;Obtaining a certificate chain corresponding to the application certificate verification request; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign signature data for generating the device certificate, so The authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to Decrypting the signature data of the application certificate;
在本地存在与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书和所述应用证书;When an authentication certificate identical to the authentication certificate in the certificate chain exists locally, verifying the device certificate and the application certificate according to an authentication public key of the authentication certificate in the certificate chain;
当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。When both the device certificate and the application certificate pass, the feedback indicates the verification result that the verification passes.
上述证书验证方法、装置、存储介质和计算机设备,在需要进行证书验证时,直接获取对应于应用证书验证请求的证书链;由于该证书链中的认证证书所对应的认证私钥用于签名生成设备证书的签名数据,认证证书的认证公钥用于解密设备证书的签名数据,且设备证书所对应的设备私钥用于签名生成应用证书的签名数据,设备证书中的设备公钥用于解密应用证书中的签名数据,也就是说,设备证书及应用证书是基于认证证书逐级签发的,那么在存在与该证书链中的认证证书一致的认证证书时,也就是在确定认证证书可信时,即可根据证 书链中的认证证书验证设备证书和应用证书,以在设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果,保证证书验证的有效性与高效性。When the above certificate verification method, device, storage medium and computer equipment need to perform certificate verification, the certificate chain corresponding to the application certificate verification request is directly obtained; since the authentication private key corresponding to the authentication certificate in the certificate chain is used for signature generation The signature data of the device certificate, the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate, and the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key in the device certificate is used to decrypt The signature data in the application certificate, that is, the device certificate and the application certificate are issued step by step based on the authentication certificate. When there is an authentication certificate that is consistent with the authentication certificate in the certificate chain, it is also determined that the authentication certificate is trustworthy. At this time, the device certificate and the application certificate can be verified according to the authentication certificate in the certificate chain, so that when the device certificate and the application certificate are both verified, the feedback indicates that the verification result is passed to ensure the validity and efficiency of the certificate verification.
附图说明BRIEF DESCRIPTION OF THE DRAWINGS
图1为一个实施例中密钥管理方法的应用环境图;FIG. 1 is an application environment diagram of a key management method in an embodiment; FIG.
图2为一个实施例中密钥管理方法的流程示意图;2 is a schematic flowchart of a key management method according to an embodiment;
图3为一个实施例中签发设备证书的时序图;FIG. 3 is a sequence diagram of issuing a device certificate in an embodiment; FIG.
图4为一个实施例中签发应用证书的时序图;4 is a sequence diagram of issuing an application certificate in an embodiment;
图5为一个实施例中验证应用证书的时序图;5 is a sequence diagram of verifying an application certificate in an embodiment;
图6为一个实施例中密钥管理的原理架构图;FIG. 6 is a schematic diagram of the principle of key management in an embodiment; FIG.
图7为一个实施例中证书验证方法的流程示意图;7 is a schematic flowchart of a certificate verification method according to an embodiment;
图8为一个实施例中密钥管理装置的模块结构图;FIG. 8 is a module structure diagram of a key management apparatus in an embodiment; FIG.
图9为另一个实施例中密钥管理装置的模块结构图;FIG. 9 is a module structure diagram of a key management apparatus in another embodiment; FIG.
图10为一个实施例中证书验证装置的模块结构图;FIG. 10 is a module structure diagram of a certificate verification device in an embodiment; FIG.
图11为另一个实施例中证书验证装置的模块结构图;FIG. 11 is a module structure diagram of a certificate verification device in another embodiment; FIG.
图12为一个实施例中计算机设备的内部结构图;FIG. 12 is an internal structural diagram of a computer device in an embodiment; FIG.
图13为另一个实施例中计算机设备的内部结构图。FIG. 13 is an internal structural diagram of a computer device in another embodiment.
具体实施方式Detailed ways
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solution, and advantages of the present application clearer, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the application, and are not used to limit the application.
图1为一个实施例中密钥管理方法的应用环境图。参照图1,该密钥管理方法应用于密钥管理系统。该密钥管理系统包括终端110和服务器120。其中,服务器120至少包括证书认证服务器121,还可包括应用服务器122和/或密钥管理服务器123。终端110和服务器120通过网络连接。终端110用于执行该密钥管理方法。终端110可以是台式终端或移动终端,移动终端可以是手机、平板电脑或者笔记本电脑等终端中的至少一种。证书认证服务器121 可以是CA(Certificate Authority数字证书认证机构)服务器或其他类型的服务器。应用服务器122可以是运行于终端110上的应用所对应的服务器,比如与即时通信应用所对应的即时通信服务器等。密钥管理服务器123可以是TAM(Trusted ATTK Management受信任ATTK管理)服务器或其他类型的服务器。FIG. 1 is an application environment diagram of a key management method in an embodiment. Referring to FIG. 1, the key management method is applied to a key management system. The key management system includes a terminal 110 and a server 120. The server 120 includes at least a certificate authentication server 121, and may further include an application server 122 and / or a key management server 123. The terminal 110 and the server 120 are connected through a network. The terminal 110 is configured to execute the key management method. The terminal 110 may be a desktop terminal or a mobile terminal, and the mobile terminal may be at least one of a terminal such as a mobile phone, a tablet computer, or a notebook computer. The certificate authentication server 121 may be a CA (Certificate Authority Digital Certificate Authority) server or another type of server. The application server 122 may be a server corresponding to an application running on the terminal 110, such as an instant communication server corresponding to an instant communication application. The key management server 123 may be a TAM (Trusted ATTK Management) server or another type of server.
终端110可在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥,再将本地的设备参数和设备公钥发送至证书认证服务器121。证书认证服务器121在接收到设备参数和设备公钥后,即可通过证书认证服务器的认证私钥对设备参数和设备公钥签名生成签名数据,得到终端110的设备证书,将该设备证书反馈给终端110。终端110继而将设备私钥和设备证书存储于该安全区域。The terminal 110 may generate a device key including a device public key and a device private key in a local security area, and then send the local device parameters and the device public key to the certificate authentication server 121. After receiving the device parameters and the device public key, the certificate authentication server 121 can generate the signature data by signing the device parameters and the device public key using the authentication private key of the certificate authentication server, and obtain the device certificate of the terminal 110. Terminal 110. The terminal 110 then stores the device private key and the device certificate in the secure area.
终端110还可在获取到通过运行于本地的应用所触发的应用密钥生成指令时,在本地的安全区域生成该应用的应用密钥;应用密钥包括应用公钥和应用私钥。在该安全区域,通过设备私钥对应用的应用参数和应用公钥进行签名,生成该应用的应用证书,将应用私钥和应用证书对应存储于安全区域,并存储该应用的证书链:认证证书、设备证书和应用证书。这样,终端110即可在接收到通过该应用所触发的生物认证授权请求时,生成与该应用对应的应用证书验证请求,将该应用的证书链与应用证书验证请求,对应发送至该应用所对应的应用服务器122,由应用服务器122进行证书验证,或者由应用服务器122将证书链转发至证书认证服务器121后,由证书认证服务器121进行证书验证。或者将证书链转发至密钥管理服务器123后,由证书认证服务器121或者密钥管理服务器123进行证书验证。The terminal 110 may also generate an application key for the application in a local security area when the application key generation instruction triggered by the application running locally is obtained; the application key includes an application public key and an application private key. In this security zone, the application's application parameters and application public key are signed by the device's private key, the application's application certificate is generated, the application private key and the application certificate are stored in the security zone, and the application's certificate chain is stored: Certificate, device certificate and application certificate. In this way, when receiving the biometric authentication authorization request triggered by the application, the terminal 110 can generate an application certificate verification request corresponding to the application, and send the application certificate chain and the application certificate verification request to the application office. The corresponding application server 122 performs certificate verification by the application server 122, or after the application server 122 forwards the certificate chain to the certificate authentication server 121, the certificate authentication server 121 performs certificate verification. Alternatively, after the certificate chain is forwarded to the key management server 123, the certificate authentication server 121 or the key management server 123 performs certificate verification.
在一个实施例中,证书验证方法也可以应用于图1所示的应用环境中。其中,服务器120用于执行该证书验证方法。服务器120接收终端110发送的应用证书验证请求,获取对应于应用证书验证请求的证书链。由于该证书链包括认证证书、设备证书和应用证书;认证证书所对应的认证私钥用于签名生成设备证书的签名数据,认证证书的认证公钥用于解密设备证书的签名数据;设备证书所对应的设备私钥用于签名生成应用证书的签名数据,设备证书的设备公钥用于解密应用证书的签名数据。那么服务器120即可在服务器120上存在与证书链中的认证证书一致的认证证书时,根据证书链中的认证证书的认证公钥验证设备证书和应用证书;当设备证书和应用证书均验证通过时,才向终端110反馈表示验证通过的验证结果。In one embodiment, the certificate verification method can also be applied to the application environment shown in FIG. 1. The server 120 is configured to execute the certificate verification method. The server 120 receives the application certificate verification request sent by the terminal 110, and obtains a certificate chain corresponding to the application certificate verification request. Because the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate; the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; The corresponding device private key is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate. Then, the server 120 can verify the device certificate and the application certificate according to the authentication public key of the authentication certificate in the certificate chain when there is an authentication certificate consistent with the authentication certificate in the certificate chain on the server 120; when the device certificate and the application certificate both pass At that time, the verification result indicating that the verification is passed is fed back to the terminal 110.
图2为一个实施例中密钥管理方法的流程示意图。本实施例以该密钥管理方法应用于图1 中的终端110来举例说明。参照图2,该方法包括如下步骤:FIG. 2 is a schematic flowchart of a key management method according to an embodiment. This embodiment is described by using the key management method applied to the terminal 110 in FIG. 1 as an example. Referring to FIG. 2, the method includes the following steps:
S202,在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥。S202. Generate a device key including a device public key and a device private key in a local security zone.
其中,安全区域是终端中独立于操作系统的可信执行环境。安全区域可以是TEE(Trusted Execution Environment)。可以理解,安全区域是用于保证在安全区域内部存储或处理的数据是独立于该安全区域以外环境的,是一个受信环境。例如,如果非对称密钥是在安全区域中生成的,那么除了密钥所有者,其他所有人(终端厂商或者应用服务器等)均无法得到非对称密钥中的私钥。当然,该安全区域也可以是终端内部可保证数据安全的其他可信区域,本申请实施例对此不作限定。Among them, the security zone is a trusted execution environment independent of the operating system in the terminal. The security zone may be TEE (Trusted Execution). It can be understood that the security zone is used to ensure that the data stored or processed inside the security zone is independent of the environment outside the security zone and is a trusted environment. For example, if the asymmetric key is generated in a secure area, everyone except the key owner (terminal manufacturer or application server) cannot obtain the private key in the asymmetric key. Of course, the security area may also be other trusted areas within the terminal that can ensure data security, which is not limited in the embodiments of the present application.
设备密钥是用于验证终端合法性与保障数据传输安全性的数据。设备密钥也可称为终端根密钥。在本申请实施例中,终端的设备密钥是非对称密钥,包括设备公钥和设备私钥。由设备公钥加密的数据,可由设备私钥进行解密;由设备私钥加密的数据,可由设备公钥进行解密。设备密钥可以是基于RSA-2048的非对称密钥,当然,该设备密钥也可以是其他非对称密钥,本申请实施例对此不作限定。The device key is used to verify the legitimacy of the terminal and ensure the security of data transmission. The device key can also be called the terminal root key. In the embodiment of the present application, the device key of the terminal is an asymmetric key, including a device public key and a device private key. Data encrypted by the device's public key can be decrypted by the device's private key; data encrypted by the device's private key can be decrypted by the device's public key. The device key may be an asymmetric key based on RSA-2048. Of course, the device key may also be another asymmetric key, which is not limited in this embodiment of the present application.
可以理解,数据传输双方在进行数据传输时,传输方需要通过密钥对传输的数据进行加密,以使得只有相应密钥的接收方才能对该加密数据进行解密,以获取传输方所传输的数据。那么,在本申请实施例中,数据传输方在与终端进行数据传输时,数据传输方通过终端的设备公钥对传输的数据进行加密,由于终端的设备私钥正常情况下只有终端自己拥有,那么只有终端可通过设备私钥对该加密数据进行解密,获取到数据传输方所传输的数据。而其他设备即使能够获取到该加密数据,由于不能拥有终端的设备私钥,因此也不能对该加密数据解密成功,也就无法获取到数据传输方所传输的数据。It can be understood that when the two data transmission parties are transmitting data, the transmission party needs to encrypt the transmitted data by using a key, so that only the receiver of the corresponding key can decrypt the encrypted data to obtain the data transmitted by the transmission party. . Then, in the embodiment of the present application, when the data transmitting party performs data transmission with the terminal, the data transmitting party encrypts the transmitted data by using the device public key of the terminal. Since the device private key of the terminal is normally only owned by the terminal, Then only the terminal can decrypt the encrypted data through the device private key to obtain the data transmitted by the data transmitting party. Even if other devices can obtain the encrypted data, the encrypted private data cannot be successfully decrypted because the private key of the device of the terminal cannot be possessed, and the data transmitted by the data transmitting party cannot be obtained.
在一个实施例中,设备密钥可以为ATTK(Attestation Key,终端验证密钥),该ATTK用于验证终端的合法性。一台终端有且仅有一个ATTK。当然,该设备密钥也可以是其他密钥,本申请实施例对此不作限定。In one embodiment, the device key may be ATTK (Attestation Key, terminal verification key), which is used to verify the legitimacy of the terminal. One terminal has one and only one ATTK. Of course, the device key may also be another key, which is not limited in the embodiment of the present application.
在一个可选的实施例中,终端的安全区域中包括密钥生成代码,通过运行该密钥生成代码,在安全区域中生成包括设备公钥和设备私钥的设备密钥。In an optional embodiment, the security area of the terminal includes a key generation code, and by running the key generation code, a device key including a device public key and a device private key is generated in the security area.
可以理解,终端厂商在生产终端时,即为终端配置安全区域。只有在为终端配置的安全区域通过验收后,该终端才允许出厂销售。可选地,在终端出厂前且该终端上的安全区域通 过验收后,可向安全区域中写入该密钥生成代码,由该密钥生成代码在安全区域中生成包括设备公钥和设备私钥的设备密钥。Understandably, when a terminal manufacturer produces a terminal, a security zone is configured for the terminal. The terminal is allowed to be shipped from the factory only after the security zone configured for the terminal passes the acceptance. Optionally, before the terminal leaves the factory and the security area on the terminal passes the acceptance, the key generation code may be written into the security area, and the key generation code may be used to generate the device public key and device private area in the security area. The device key of the key.
在一个可选的实施例中,终端的安全区域中可运行有安全应用。安全应用的逻辑行为和存储行为均为安全行为。终端可通过运行于安全区域中安全应用生成包括设备公钥和设备私钥的设备密钥。安全应用可以是TA(Trusted Application)应用。In an optional embodiment, a security application may run in a secure area of the terminal. The logical behavior and storage behavior of the security application are both security behaviors. The terminal may generate a device key including a device public key and a device private key by running a security application in a secure area. The security application may be a TA (Trusted Application) application.
当然,也可以采用其他方式在终端的安全区域中生成设备密钥,本申请实施例中对设备密钥的生成方式不作限定。Of course, other methods may also be used to generate the device key in the secure area of the terminal, and the method for generating the device key is not limited in the embodiments of the present application.
S204,将本地的设备参数和设备公钥发送至证书认证服务器。S204. Send the local device parameters and the device public key to the certificate authentication server.
其中,设备参数是反映终端身份的数据。设备参数可以是终端标识,该终端标识用于唯一标识一个终端,比如终端序列号等。证书认证服务器是用于认证数字证书的权威服务器。数字证书用于证明证书中列出的用户(设备或应用等)合法拥有证书中列出的公开密钥(设备公钥或应用公钥等)。证书认证服务器可以是CA服务器,即是数字证书认证机构的服务器。Among them, the device parameters are data reflecting the identity of the terminal. The device parameter may be a terminal identifier, which is used to uniquely identify a terminal, such as a terminal serial number. The certificate authentication server is an authoritative server for authenticating digital certificates. The digital certificate is used to prove that the user (device or application, etc.) listed in the certificate legally owns the public key (device public key or application public key, etc.) listed in the certificate. The certificate authentication server can be a CA server, that is, a server of a digital certificate authority.
可选地,终端可读取本地的设备参数,也就是本终端的设备参数,并生成设备证书签发请求;然后将读取的设备参数、生成的设备公钥与该设备证书签发请求对应发送至证书认证服务器。Alternatively, the terminal may read the local device parameters, that is, the device parameters of the terminal, and generate a device certificate signing request; and then send the read device parameters, the generated device public key, and the device certificate signing request to the corresponding Certificate authentication server.
S206,接收证书认证服务器反馈的设备证书;设备证书的签名数据,通过证书认证服务器的认证私钥对设备参数和设备公钥签名生成。S206: Receive the device certificate fed back by the certificate authentication server; the signature data of the device certificate is generated by signing the device parameters and the device public key with the authentication private key of the certificate authentication server.
其中,设备证书是经证书认证服务器签名下发的、且包括设备公钥拥有者信息及设备公钥的文件。设备公钥拥有者信息即设备参数。设备证书上可以包括设备公钥拥有者信息及设备公钥的明文,也就是未进行签名处理的原始数据;也可以包括设备公钥拥有者信息以及设备公钥的密文,也就是对设备公钥拥有者信息及设备公钥签名得到的数据。签名数据是通过签名者的私钥对某一数据进行签名后得到的数据。也即是,证书认证服务器接收终端的设备参数和设备公钥,通过证书认证服务器的认证私钥对设备参数和设备公钥签名生成签名数据,形成设备证书,反馈给终端。The device certificate is a file issued by the certificate authentication server and includes the device public key owner information and the device public key. The device public key owner information is the device parameter. The device certificate can include the device public key owner information and the device public key in plain text, that is, the original data without signature processing; it can also include the device public key owner information and the device public key cipher text, which is the device public key Key owner information and data signed by the device's public key. Signature data is data obtained by signing a piece of data with the signer's private key. That is, the certificate authentication server receives the device parameters and the device public key of the terminal, signs the device parameters and the device public key by using the authentication private key of the certificate authentication server to generate signature data, forms a device certificate, and feeds it back to the terminal.
在一个实施例中,设备证书包括设备参数、设备公钥以及通过认证私钥对设备参数和设备公钥签名生成的密文。这里,设备证书的签名数据可以仅是该密文;也可以是设备参数、设备私钥和密文的组合。In one embodiment, the device certificate includes a device parameter, a device public key, and a ciphertext generated by signing the device parameter and the device public key by authenticating the private key. Here, the signature data of the device certificate may be only the cipher text; it may also be a combination of the device parameters, the device private key, and the cipher text.
在本申请实施例中,设备证书符合X.509证书标准。本申请后续涉及的认证证书以及应用证书均符合X.509证书标准。当然,认证证书、设备证书以及应用证书也可以符合其他证书标准,本申请实施例对此不作限定。In the embodiment of the present application, the device certificate complies with the X.509 certificate standard. The authentication certificates and application certificates involved in this application follow the X.509 certificate standard. Of course, the authentication certificate, equipment certificate, and application certificate can also meet other certificate standards, which are not limited in the embodiments of the present application.
可选地,证书认证服务器在接收到终端发送的设备参数和设备公钥后,按照与终端约定的签名算法,计算得到设备参数和设备公钥的摘要信息,再通过自己的认证私钥对计算得到的摘要信息进行加密,得到签名数据。Optionally, after receiving the device parameters and the device public key sent by the terminal, the certificate authentication server calculates the summary information of the device parameters and the device public key according to the signature algorithm agreed with the terminal, and then calculates it by using its own authentication private key pair. The obtained digest information is encrypted to obtain signature data.
由于可在数学上保证:只要改动数据中任何一位,重新计算出的该数据的摘要信息就会与原先的摘要信息不相符。故本申请实施例中,采用提取摘要信息,对摘要信息进行加密签名的方式,就可以既保证了数据的不可更改性,又避免了对大量数据进行加密和解密带来的耗时。当然,也可以采用其他方式对设备参数和设备公钥进行签名,本申请实施例中对此不作限定。Because it can be guaranteed mathematically: as long as any bit in the data is changed, the recalculated summary information of the data will not match the original summary information. Therefore, in the embodiment of the present application, the method of extracting the digest information and encrypting and signing the digest information can not only ensure the immutability of the data, but also avoid the time consuming caused by encrypting and decrypting a large amount of data. Of course, the device parameters and the device public key can also be signed in other ways, which is not limited in the embodiments of the present application.
可以理解为,即使是非对称加密系统也不能保证公钥的分发是可靠的。为了防范公钥分发过程中的中间人攻击,需要一个可信的“始祖”公证人,这就是证书认证服务器(CA服务器)存在的意义。在本申请的实施例中,公钥所在的证书是通过证书认证服务器签发的,或者基于证书认证服务器签发的,在源头上保证了公钥所在的证书的可靠性。It can be understood that even asymmetric encryption systems cannot guarantee that the distribution of public keys is reliable. In order to prevent man-in-the-middle attacks in the process of public key distribution, a trusted "originator" notary is needed, which is the significance of a certificate authentication server (CA server). In the embodiment of the present application, the certificate where the public key is located is issued by a certificate authentication server, or based on the certificate authentication server, the reliability of the certificate where the public key is located is guaranteed at the source.
S208,将设备私钥和设备证书存储于安全区域。S208. Store the device private key and the device certificate in a secure area.
可选地,终端可在终端出厂前,将设备私钥和设备证书存储于终端的安全区域中的安全存储区域。安全存储区域比如RPMB(Replay Protected Memory Block,继电保护存储区域)。Optionally, the terminal may store the device private key and the device certificate in a secure storage area in a secure area of the terminal before the terminal leaves the factory. Secure storage area such as RPMB (Replay Protected Memory Block).
在一个实施例中,由于一个设备有且仅有一个设备密钥。那么设备密钥与设备证书可以对应存储,也可分别独立存储。设备私钥和设备证书可以同时存储;也可以分开存储,即在生成设备私钥后即存储设备私钥,在接收到设备证书后即存储设备证书。In one embodiment, a device has one and only one device key. Then the device key and the device certificate can be stored correspondingly or separately. The device private key and the device certificate can be stored at the same time; they can also be stored separately, that is, the device private key is stored after the device private key is generated, and the device certificate is stored after the device certificate is received.
可以理解,上述S202至S208的步骤,均在设备生产线内部安全可信环境上完成。在本申请实施例中,不再需要在终端出厂前,将终端的设备公钥由终端厂商通过安全信道发送至密钥管理服务器,以这种方式来保证上传数据不会被篡改。而是通过证书认证服务器来签发设备证书,由证书认证服务器来确保设备证书的安全性与可信赖性,由于大量设备可以共用一份认证证书,减少了设备密钥的管理维护成本。It can be understood that the above steps S202 to S208 are completed on a secure and trusted environment inside the equipment production line. In the embodiment of the present application, it is no longer necessary to send the device public key of the terminal from the terminal manufacturer to the key management server through a secure channel before the terminal leaves the factory, in this way to ensure that the uploaded data will not be tampered with. Instead, the device certificate is issued through a certificate authentication server. The certificate authentication server ensures the security and reliability of the device certificate. Since a large number of devices can share a single authentication certificate, the management and maintenance cost of the device key is reduced.
在一个实施例中,终端还可获取包括认证私钥所对应认证公钥的认证证书;将认证证书 和设备证书作为终端的证书链;将证书链存储于安全区域。也就是说,对于终端的每一个证书,终端均会在安全区域存储该证书的证书链。In one embodiment, the terminal may also obtain an authentication certificate including an authentication public key corresponding to the authentication private key; use the authentication certificate and the device certificate as the certificate chain of the terminal; and store the certificate chain in a secure area. That is, for each certificate of the terminal, the terminal stores the certificate chain of the certificate in a secure area.
上述密钥管理方法,设备密钥的生成以及设备密钥中的设备私钥和设备证书的存储,都是在本地的安全区域中进行,保证了设备密钥和设备证书的安全性;其次,设备证书中的签名数据,是通过证书认证服务器的认证私钥对本地的设备参数和设备公钥签名生成的,增强了设备证书的有效性与可信度;而且,设备证书是直接存储在本地,避免了将设备公钥存储在异于本地的其他设备中导致密钥在管理和使用上的复杂操作和不便,使得密钥管理便捷且高效。The above-mentioned key management method, the generation of the device key, and the storage of the device private key and the device certificate in the device key are all performed in a local security zone, ensuring the security of the device key and the device certificate; secondly, The signature data in the device certificate is generated by signing the local device parameters and the device public key with the authentication private key of the certificate authentication server, which enhances the validity and credibility of the device certificate; moreover, the device certificate is directly stored locally It avoids the complicated operation and inconvenience of the management and use of the key caused by storing the device public key in other devices different from the local, making the key management convenient and efficient.
图3示出了一个实施例中签发设备证书的时序图。参考图3,终端在未出厂前,通过运行于安全区域(TEE)中的安全应用(TA)生成包括设备公钥和设备私钥的设备密钥(ATTK),TEE独立于终端的操作系统。终端将生成的设备私钥存储在TEE的安全存储区域,并向证书认证服务器(CA服务器)发送设备证书签发请求,在该设备证书签发请求中携带终端的设备参数和生成的设备公钥。CA服务器在接收到设备证书签发请求后,通过自身的认证私钥(CA根证书的私钥)对终端的设备参数和设备公钥进行签名生成设备证书,再将生成的设备证书反馈给终端。终端再将设备证书存储至TEE的安全存储区域。FIG. 3 shows a sequence diagram of issuing a device certificate in one embodiment. Referring to FIG. 3, before the terminal is shipped, the terminal generates a device key (ATTK) including a device public key and a device private key through a security application (TA) running in a security area (TEE). The TEE is independent of the terminal's operating system. The terminal stores the generated device private key in a TEE secure storage area, and sends a device certificate signing request to a certificate authentication server (CA server), and the device certificate signing request carries the device parameters of the terminal and the generated device public key. After receiving the device certificate signing request, the CA server signs the device parameters and the device public key of the terminal with its own authentication private key (the private key of the CA root certificate) to generate a device certificate, and then feeds back the generated device certificate to the terminal. The terminal then stores the device certificate in the secure storage area of the TEE.
在一个实施例中,密钥管理方法还包括:当获取到通过运行于本地的应用所触发的应用密钥生成指令时,在安全区域生成应用的应用密钥;应用密钥包括应用公钥和应用私钥;在安全区域,通过设备私钥对应用的应用参数和应用公钥进行签名,生成应用的应用证书;将应用私钥和应用证书对应存储于安全区域。In one embodiment, the key management method further includes: generating an application key of the application in a secure area when the application key generation instruction triggered by the application running locally is obtained; the application key includes the application public key and Application private key; in the security area, sign the application's application parameters and application public key with the device's private key to generate the application's application certificate; store the application private key and application certificate in the security area correspondingly.
其中,应用密钥生成指令是用于指示生成应用密钥的计算机程序。应用密钥是用于验证应用合法性与保障数据传输安全性的数据。在本申请实施例中,应用密钥是非对称密钥,包括应用公钥和应用私钥。由应用公钥加密的数据,可由应用私钥进行解密;由应用私钥加密的数据,可由应用公钥进行解密。应用密钥可以是基于RSA-2048的非对称密钥,当然,该应用密钥也可以是其他非对称密钥,本申请实施例对此不作限定。The application key generation instruction is a computer program for instructing generation of an application key. Application keys are data used to verify the legitimacy of applications and ensure the security of data transmission. In the embodiment of the present application, the application key is an asymmetric key and includes an application public key and an application private key. Data encrypted by the application public key can be decrypted by the application private key; data encrypted by the application private key can be decrypted by the application public key. The application key may be an asymmetric key based on RSA-2048. Of course, the application key may also be another asymmetric key, which is not limited in this embodiment of the present application.
在一个实施例中,应用密钥可以为ASK(App Secure Key,应用验证密钥),该ASK用于验证应用的合法性。一个应用有且仅有一个ASK。当然,该应用密钥也可以是其他密钥,本申请实施例对此不作限定。In one embodiment, the application key may be an ASK (App Secure Key), which is used to verify the legitimacy of the application. An application has one and only one ASK. Of course, the application key may also be another key, which is not limited in the embodiment of the present application.
可以理解,终端上可运行有一个或多个应用,每个应用拥有自己的应用公钥和应用私钥。终端上的应用在与外部设备进行数据交互时,对端通过该应用的应用公钥对传输的数据进行加密,由于该应用的应用私钥正常情况下只有该应用自己拥有,那么只有该应用可通过应用私钥对该加密数据进行解密,获取到对端所传输的数据。而其他应用即使能够获取到该加密数据,由于不能拥有该应用的应用私钥,因此也不能对该加密数据解密成功,也就无法获取到对端所传输的数据。It can be understood that one or more applications can run on the terminal, and each application has its own application public key and application private key. When an application on a terminal performs data interaction with an external device, the peer end encrypts the transmitted data through the application public key of the application. Since the application private key of the application is normally only owned by the application itself, then only the application can The encrypted data is decrypted by applying the private key to obtain the data transmitted by the peer. Even if other applications can obtain the encrypted data, because they cannot own the application's application private key, the encrypted data cannot be decrypted successfully, and the data transmitted by the peer cannot be obtained.
可选地,终端在安装应用或者首次运行应用时,可获取通过该应用所触发的应用密钥生成指令,或者通过该应用的安装代码所触发的应用密钥生成指令。终端即在本地的安全区域中生成该应用的应用密钥,并在该安全区域中,通过本终端的设备私钥对该应用的应用参数和应用公钥进行签名,生成该应用的应用证书;再将应用私钥和应用证书对应存储于安全区域。Optionally, when the terminal installs the application or runs the application for the first time, the terminal may obtain an application key generation instruction triggered by the application or an application key generation instruction triggered by the application installation code. The terminal generates the application key of the application in the local security area, and signs the application parameters and the application public key of the application through the device's private key in the security area to generate the application's application certificate; Then store the application private key and application certificate in a secure area.
在一个实施例中,通过设备私钥对应用的应用参数和应用公钥进行签名,生成应用的应用证书,包括:获取应用的应用参数和应用公钥的摘要信息;通过设备私钥加密摘要信息得到签名数据;根据加密得到的签名数据生成应用的应用证书。In one embodiment, signing the application's application parameters and the application's public key with the device's private key to generate the application's application certificate includes: obtaining the application's application parameters and the application's public key summary information; encrypting the digest information with the device's private key. Get signature data; generate an application certificate for the application based on the encrypted signature data.
其中,摘要信息是唯一对应该摘要信息所属数据的固定长度的值。它由一个不可逆的字符串变换算法对该摘要信息所属数据进行运算而产生。Among them, the digest information is the only fixed-length value corresponding to the data to which the digest information belongs. It is generated by an irreversible string transformation algorithm that operates on the data to which the digest information belongs.
可选地,终端可采用不可逆的字符串变换算法,将该应用的应用参数和应用公钥作为一个文本信息,生成该文本信息的摘要信息。该不可逆的字符串变换算法可以为哈希算法,也可以为其他算法,本申请实施例对此不作限定。当然,也可以采用其他方式生成该应用的应用参数和应用公钥的摘要信息,本申请实施例对此不作限定。Optionally, the terminal may use an irreversible string transformation algorithm to use the application parameter and the application public key of the application as one piece of text information to generate summary information of the text information. The irreversible string transformation algorithm may be a hash algorithm or other algorithms, which is not limited in this embodiment of the present application. Of course, other methods can also be used to generate the application parameter and application public key summary information, which is not limited in this embodiment of the present application.
进一步地,终端再通过设备私钥加密摘要信息得到签名数据,生成该应用的应用证书。应用证书上可以包括应用公钥拥有者信息以及应用公钥的明文,也就是未进行签名处理的原始数据;也可以包括应用公钥拥有者信息以及应用公钥的密文,也就是对应用公钥拥有者信息以及应用公钥签名得到的数据。其中,应用公钥拥有者信息即应用参数。Further, the terminal obtains signature data by encrypting the digest information with the private key of the device, and generates an application certificate of the application. The application certificate can include the application public key owner information and the application public key plain text, that is, the original data without signature processing; it can also include the application public key owner information and the application public key cipher text, that is, the application public key Key owner information and data obtained by applying a public key signature. Among them, application public key owner information is application parameters.
可以理解,如果数据在传输中发生了改变,则接收者通过对收到数据计算得到的新摘要信息与原摘要信息不相符,这样接收者就可知道数据发生了改变。因此,在本实施例中,对摘要信息进行加密,在通过摘要加密也能保证传输数据的完整性与安全性的情况下,不再对 完整的传输数据进行加密,避免了数据量大时加密和解密过程带来的耗时,既保证了数据安全,提供了数据处理效率,又便利了后续的数据处理过程。It can be understood that if the data changes during transmission, the new digest information calculated by the receiver through the received data does not match the original digest information, so the receiver can know that the data has changed. Therefore, in this embodiment, the digest information is encrypted. In the case that the integrity and security of the transmitted data can also be guaranteed by the digest encryption, the complete transmitted data is no longer encrypted, and encryption is avoided when the amount of data is large. The time consuming caused by the decryption and decryption process not only ensures data security, provides data processing efficiency, but also facilitates subsequent data processing processes.
在一个实施例中,该密钥管理方法还包括:获取包括认证私钥所对应认证公钥的认证证书;将认证证书、设备证书和应用证书作为应用的证书链;将证书链存储于安全区域。In one embodiment, the key management method further includes: obtaining an authentication certificate including an authentication public key corresponding to the authentication private key; using the authentication certificate, device certificate, and application certificate as an application certificate chain; and storing the certificate chain in a secure area .
其中,认证证书是证书认证服务器所持有的数字证书。由于证书认证服务器是负责发放和管理数字证书的权威机构,并作为电子商务交易中受信任的第三方,承担公钥体系中公钥合法性检验的责任。那么,认证证书通常被认为具有权威性可信赖。在本申请实施例中,证书认证服务器可以是CA服务器,认证证书可以是CA根证书。The authentication certificate is a digital certificate held by a certificate authentication server. Because the certificate authentication server is an authoritative organization responsible for issuing and managing digital certificates, and as a trusted third party in e-commerce transactions, it bears the responsibility of checking the validity of public keys in the public key system. Then, the certificate is generally considered to be authoritative and trustworthy. In the embodiment of the present application, the certificate authentication server may be a CA server, and the authentication certificate may be a CA root certificate.
通常情况下,一个证书认证服务器持有一个CA根证书,证书认证服务器根据其所持有的CA根证书的私钥来对待签名的数据进行签名操作。当然,一个证书认证服务器也可持有多个CA根证书,本申请实施例对此不作限定。Generally, a certificate authentication server holds a CA root certificate, and the certificate authentication server performs a signature operation on the data to be signed according to the private key of the CA root certificate it holds. Of course, one certificate authentication server may also hold multiple CA root certificates, which is not limited in this embodiment of the present application.
可选地,证书认证服务器在为终端签发设备证书后,可将其所持有的认证证书下发至该终端。这样终端在通过设备私钥签发应用证书后,可将应用证书,签发该应用证书的设备私钥所对应设备公钥所在的设备证书,以及签发该设备证书的认证私钥所对应认证公钥所在的认证证书组成该应用的证书链,将该证书链存储在终端的安全区域。Optionally, after the certificate authentication server issues a device certificate for the terminal, the certificate authentication server may issue the authentication certificate held by the certificate authentication server to the terminal. In this way, after the application certificate is issued by the device private key, the terminal can use the application certificate, the device certificate corresponding to the device public key corresponding to the device private key issuing the application certificate, and the authentication public key corresponding to the authentication private key that issued the device certificate The authentication certificate constitutes a certificate chain of the application, and the certificate chain is stored in a secure area of the terminal.
可以理解,由于设备证书是通过证书认证服务器签发的,应用证书又是根据设备证书签发的,那么应用证书即是基于证书认证服务器签发的,也就是说应用证书的证书链是基于证书认证服务器建立的信任链,增强了证书链中的各证书的可信度。Understandably, since the device certificate is issued by the certificate authentication server and the application certificate is issued according to the device certificate, the application certificate is issued based on the certificate authentication server, that is, the certificate chain of the application certificate is established based on the certificate authentication server. The trust chain enhances the credibility of each certificate in the certificate chain.
本实施例中,对于每个证书建立了该证书的证书链,这样在后续验证证书的合法性时,在验证请求中携带该证书的证书链,即可逐级完成证书合法性的验证;不需要事先将设备公钥传输到专门管理密钥的服务器,再请求该服务器进行证书合法性的验证。In this embodiment, the certificate chain of the certificate is established for each certificate, so that when the validity of the certificate is subsequently verified, the certificate chain of the certificate is carried in the verification request, and the validity of the certificate can be verified step by step; The device public key needs to be transmitted to a server that specifically manages the key before requesting the server to verify the validity of the certificate.
上述实施例中,应用密钥的生成以及应用密钥中的私钥和应用证书的存储,都是在本地的安全区域中进行,保证了应用密钥和应用证书的安全性;其次,应用证书中的签名数据,是通过设备私钥签名生成的,设备私钥所对应的设备公钥所在的设备证书又是通过证书认证服务器签发的,增强了应用证书的有效性与可信度。In the above embodiment, the generation of the application key and the storage of the private key and the application certificate in the application key are all performed in a local security zone, ensuring the security of the application key and the application certificate. Secondly, the application certificate The signature data in is generated by the device private key signature, and the device certificate of the device public key corresponding to the device private key is issued by the certificate authentication server, which enhances the validity and credibility of the application certificate.
图4示出了一个实施例中签发应用证书的时序图。参考图4,终端上可运行应用,应用在安装或运行后,可触发应用密钥生成指令,终端通过运行于TEE的TA生成包括应用公钥 和应用私钥的应用密钥(ASK)。终端再通过TA从安全存储区域中获取设备私钥,通过获取的设备私钥对该应用的应用参数和应用公钥进行签名生成应用证书;再将应用私钥和应用证书对应存储至TEE的安全存储区域。终端还可将认证证书、设备证书和应用证书作为应用的证书链;将证书链存储于TEE的安全区域。FIG. 4 shows a sequence diagram of issuing an application certificate in one embodiment. Referring to FIG. 4, an application can be run on a terminal. After the application is installed or run, an application key generation instruction can be triggered. The terminal generates an application key (ASK) including an application public key and an application private key through a TA running on the TEE. The terminal then obtains the device private key from the secure storage area through TA, and uses the obtained device private key to sign the application's application parameters and application public key to generate an application certificate; and then stores the application private key and application certificate to the TEE security accordingly Storage area. The terminal can also use the authentication certificate, device certificate, and application certificate as the certificate chain of the application; the certificate chain is stored in the secure area of the TEE.
在一个实施例中,该密钥管理方法还包括:在接收到通过应用所触发的生物认证授权请求时,生成与应用对应的应用证书验证请求;将应用的证书链与应用证书验证请求,对应发送至应用所对应的应用服务器;接收应用服务器根据应用服务器上存储的认证证书对接收到的证书链进行验证后反馈的验证结果;当验证结果表示验证通过时,授予应用进行生物认证的权限。In one embodiment, the key management method further includes: generating an application certificate verification request corresponding to the application when receiving the biometric authentication authorization request triggered by the application; and corresponding the application certificate chain with the application certificate verification request, Send to the application server corresponding to the application; receive the verification result fed back by the application server after verifying the received certificate chain according to the authentication certificate stored on the application server; when the verification result indicates that the verification is passed, grant the application the right to perform biometric authentication.
其中,生物认证授权请求用于请求授予进行生物认证的权限。生物认证是计算机设备利用自然人所固有的生物特征来进行身份鉴定的技术。生物认证比如指纹认证、面部识别认证以及虹膜识别认证等。应用证书验证请求用于请求对应用证书进行合法性验证。Among them, the biometric authentication authorization request is used to request the authority to perform biometric authentication. Biometric authentication is a technology in which computer equipment uses the biological characteristics inherent in natural persons to perform identity authentication. Biometric authentication such as fingerprint authentication, facial recognition authentication and iris recognition authentication. The application certificate verification request is used to request the validity verification of the application certificate.
可以理解,应用请求终端授予其进行生物认证的权限,即是请求获取终端中存储的用户所固有的生物特征的数据,如指纹数据或者面部数据等。由于这些数据是用户所特有的生物隐私。为了保护用户生物隐私,则需要在应用具有合法请求权限时才能授予。也就是说,只有在应用的应用证书校验通过后,才可以授予该应用进行生物认证的权限。It can be understood that the application requesting the terminal to grant the authority to perform biometric authentication is to request to obtain the biometric data inherent to the user stored in the terminal, such as fingerprint data or face data. Because this data is unique to the user's biological privacy. In order to protect the user's biological privacy, it needs to be granted only when the application has legal request permissions. In other words, only after the application certificate of the application passes the verification, the application can be granted the right to perform biometric authentication.
而应用服务器接收应用的证书链与应用证书验证请求,当应用服务器存储有认证证书时,根据该认证证书对接收到的证书链进行验证,向终端反馈验证结果。The application server receives the application certificate chain and the application certificate verification request. When the application server stores an authentication certificate, the received certificate chain is verified according to the authentication certificate, and the verification result is fed back to the terminal.
举例说明,用户在终端的即时通信应用上开通指纹支付时,即通过该即时通信应用触发了生物认证授权请求。这时,该即时通信应用则需要将该即时通信应用的证书链发送到该即时通信应用对应的即时通信服务器,由即时通信服务器验证证书链中证书的合法性,或者,由即时通信服务器转发至其他服务器验证证书链中证书的合法性。只有在合法性验证通过后,终端才能授予该即时通信应用进行指纹识别支付的权限。For example, when a user opens a fingerprint payment on an instant messaging application of a terminal, a biometric authentication authorization request is triggered through the instant messaging application. At this time, the instant messaging application needs to send the certificate chain of the instant messaging application to the instant messaging server corresponding to the instant messaging application, and the instant messaging server verifies the validity of the certificate in the certificate chain, or the instant messaging server forwards it to Other servers verify the validity of the certificates in the certificate chain. Only after the legitimacy verification is passed, the terminal can grant the fingerprint communication payment permission to the instant messaging application.
可选地,终端在接收到通过应用所触发的生物认证授权请求时,即生成与应用对应的应用证书验证请求;将该应用的证书链与应用证书验证请求,对应发送至应用所对应的应用服务器。Optionally, when the terminal receives the biometric authentication authorization request triggered by the application, the terminal generates an application certificate verification request corresponding to the application, and sends the application certificate chain and the application certificate verification request to the application corresponding to the application. server.
应用服务器在接收到应用证书验证请求时,即获取该应用证书验证请求携带的证书链, 并在本地查询是否存储有与该证书链中的认证证书一致的证书链。当应用服务器上存储有与该证书链中的认证证书一致的认证证书时,即判定该证书链中的认证证书是合法的。When the application server receives an application certificate verification request, it obtains the certificate chain carried by the application certificate verification request, and locally queries whether a certificate chain that is consistent with the authentication certificate in the certificate chain is stored. When the application server stores an authentication certificate consistent with the authentication certificate in the certificate chain, it is determined that the authentication certificate in the certificate chain is legal.
应用服务器然后根据该认证证书上的认证公钥解密设备证书上的签名数据,得到第一摘要信息,并根据与终端约定的摘要信息提取方式提取设备证书上设备参数和设备公钥的第二摘要信息,比较第一摘要信息和第二摘要信息。当两者不一致时,则判定设备证书不合法,向终端反馈表示验证失败的验证结果。The application server then decrypts the signature data on the device certificate according to the authentication public key on the authentication certificate to obtain the first summary information, and extracts the second summary of the device parameters and the device public key on the device certificate according to the abstract information extraction method agreed with the terminal. Information, comparing the first summary information and the second summary information. When the two are inconsistent, the device certificate is determined to be illegal, and a verification result indicating the verification failure is fed back to the terminal.
当第一摘要信息和第二摘要信息一致时,应用服务器则继续根据该设备证书上的设备公钥解密应用证书上的签名数据得到第三摘要信息,并根据与终端约定的摘要信息提取方式提取应用证书上应用参数和应用公钥的第四摘要信息,比较第三摘要信息和第四摘要信息。当两者不一致时,则判定设备证书不合法,向终端反馈表示验证失败的验证结果。当第三摘要信息和第四摘要信息一致时,则判定应用证书合法,向终端反馈表示验证通过的验证结果。这样,终端只有在接收到的验证结果表示验证通过时,才授予应用进行生物认证的权限。When the first summary information and the second summary information are consistent, the application server continues to decrypt the signature data on the application certificate to obtain the third summary information according to the device public key on the device certificate, and extracts the third summary information according to the abstract information extraction method agreed with the terminal. Compare the third summary information with the fourth summary information of the application parameters on the application certificate and the fourth summary information of the application public key. When the two are inconsistent, the device certificate is determined to be illegal, and a verification result indicating the verification failure is fed back to the terminal. When the third summary information and the fourth summary information are consistent, it is determined that the application certificate is valid, and a verification result indicating that the verification is passed is fed back to the terminal. In this way, the terminal grants the application the right to perform biometric authentication only when the received authentication result indicates that the authentication is passed.
可以理解,应用服务器上存储的认证证书,可以是事先通过安全通道从各证书认证服务器上获取的各证书认证服务器所持有的认证证书。当可以找到与证书链中的认证证书一致的认证证书时,才可判定该认证证书有效,也就是证书链的源头有效,从而根据该认证证书逐级校验。其中,安全通道是可以保证数据传输安全性的数据传输通道,是受信任通道,可以是基于HTTPS协议建立的数据传输通道。It can be understood that the authentication certificate stored on the application server may be an authentication certificate held by each certificate authentication server obtained from each certificate authentication server through a secure channel in advance. When an authentication certificate that is consistent with the authentication certificate in the certificate chain can be found, it can be determined that the authentication certificate is valid, that is, the source of the certificate chain is valid, and the verification is performed step by step according to the authentication certificate. Among them, the secure channel is a data transmission channel that can ensure the security of data transmission, is a trusted channel, and may be a data transmission channel established based on the HTTPS protocol.
在一个实施例中,应用服务器还可事先获取吊销认证证书列表。这样应用服务器在进行证书链认证时,先查看证书链中的认证证书是否存在于该吊销认证证书列表。若证书链中的认证证书存在于该吊销认证证书列表中,则说明认证证书已失效,不必再进行后续的证书验证。若证书链中的认证证书不存在于该吊销认证证书列表中,才继续进行后续的证书验证。其中,吊销认证证书列表用于公示失效的认证证书。In one embodiment, the application server may also obtain a list of revoked authentication certificates in advance. In this way, when the application server performs certificate chain authentication, it first checks whether the authentication certificate in the certificate chain exists in the list of revoked authentication certificates. If the authentication certificate in the certificate chain exists in the list of revoked authentication certificates, it means that the authentication certificate has expired and it is not necessary to perform subsequent certificate verification. If the certificate in the certificate chain does not exist in the list of revoked certificates, the subsequent certificate verification is continued. Among them, the list of revoked certificates is used to publicize invalid certificates.
在一个实施例中,该密钥管理方法还包括:接收应用服务器未存储有认证证书时所反馈的、通过安全信道从证书认证服务器获取到的验证结果;验证结果由证书认证服务器在通过安全信道接收到应用服务器上传的证书链后,根据证书认证服务器上存储的认证证书对证书链验证得到。In one embodiment, the key management method further includes: receiving a verification result obtained from the certificate authentication server through a secure channel and fed back when the application server does not store the authentication certificate; the verification result is passed by the certificate authentication server through the secure channel. After receiving the certificate chain uploaded by the application server, the certificate chain is verified according to the authentication certificate stored on the certificate authentication server.
可选地,当应用服务器上未存储有与该证书链中的认证证书一致的认证证书时,即将该 证书链通过安全通道传输至证书认证服务器或者密钥管理服务器,由证书认证服务器或者密钥管理服务器来验证证书链中各证书的合法性,将验证结果反馈给应用服务器,再由应用服务器反馈给终端。可以理解,证书认证服务器或者密钥管理服务器验证证书链中各证书的合法性的过程,与应用服务器验证证书链中各证书的合法性的过程类似,在此不再赘述。Optionally, when the application server does not store an authentication certificate consistent with the authentication certificate in the certificate chain, the certificate chain is transmitted to the certificate authentication server or key management server through a secure channel, and the certificate authentication server or key The management server verifies the legitimacy of each certificate in the certificate chain, feeds the verification result back to the application server, and then the application server feeds back the terminal. It can be understood that the process of the certificate authentication server or the key management server verifying the validity of each certificate in the certificate chain is similar to the process of the application server verifying the validity of each certificate in the certificate chain, and is not repeated here.
在本实施例中,通过证书认证服务器来进行证书合法性校验,增强了校验结果的可信度;而且,在校验时,根据证书链来进行校验,证书链中即包括了设备公钥,不再需要事先进行上传。In this embodiment, the validity of the certificate is verified by the certificate authentication server, and the credibility of the verification result is enhanced. Moreover, during the verification, the verification is performed according to the certificate chain, and the device is included in the certificate chain. The public key no longer needs to be uploaded in advance.
可以理解,通常情况下,应用服务器仅在安全级别较低的场景下进行证书合法性校验。在安全级别较高的场景下,即使应用服务器上存储有与该证书链中的认证证书一致的认证证书。应用服务器也应当将该证书链通过安全通道传输至证书认证服务器或者密钥管理服务器,由证书认证服务器或者密钥管理服务器来验证证书链中各证书的合法性。安全级别较低的场景比如涉及账号开通的场景,安全级别较高的场景比如涉及资源转移(支付)的场景等。It can be understood that, usually, the application server only checks the validity of the certificate in a scenario with a low security level. In a scenario with a high security level, even if the application server stores an authentication certificate that is consistent with the authentication certificate in the certificate chain. The application server should also transmit the certificate chain to the certificate authentication server or key management server through a secure channel, and the certificate authentication server or key management server should verify the validity of each certificate in the certificate chain. Scenarios with lower security levels include scenarios involving account opening, and scenarios with higher security levels include scenarios involving resource transfer (payment).
在一个实施例中,终端在接收到通过应用所触发的生物认证授权请求时,确定请求生物认证授权的事件所对应的安全级别,并在生成的应用证书验证请求中携带该安全级别。这样,应用服务器在接收到应用证书验证请求后,根据应用证书验证请求中携带的安全级别判定由本地进行证书合法性验证,还是由证书认证服务器或者密钥管理服务器进行证书合法性验证。其中,应用服务器事先配置了可处理的安全级别,在应用证书验证请求中携带的安全级别为应用服务器可处理的安全级别时,应用服务器判定由本地进行证书合法性验证,否则判定由证书认证服务器或者密钥管理服务器进行证书合法性验证。In one embodiment, when the terminal receives the biometric authentication authorization request triggered by the application, the terminal determines the security level corresponding to the event requesting the biometric authentication authorization, and carries the security level in the generated application certificate verification request. In this way, after receiving the application certificate verification request, the application server determines whether the certificate validity verification is performed locally or by the certificate authentication server or the key management server according to the security level carried in the application certificate verification request. Wherein, the application server is configured with a processable security level in advance. When the security level carried in the application certificate verification request is a security level that the application server can process, the application server determines that the certificate validity verification is performed locally, otherwise it is determined that the certificate authentication server Or the key management server performs certificate validity verification.
在一个实施例中,应用服务器在判定由证书认证服务器或者密钥管理服务器进行证书合法性验证后,可将应用证书验证请求转发至证书链中认证证书所对应的证书认证服务器;可也转发至其他证书认证服务器,此时,转发至的证书认证服务器应当事先通过安全通道获取了证书链中认证证书的真实版本。In one embodiment, the application server may forward the application certificate verification request to the certificate authentication server corresponding to the authentication certificate in the certificate chain after determining that the certificate authentication server or key management server performs the certificate validity verification; For other certificate authentication servers, the certificate authentication server forwarded to this time should obtain the authentic version of the authentication certificate in the certificate chain through the secure channel in advance.
上述实施例中,在安全级别较低的场景下,由应用服务器来进行证书合法性校验,一方面可以在一定程度上保证校验结果的可信度,另一方面还可避免多次传递数据带来的风险和耗时。In the above embodiment, in a scenario with a low security level, the certificate validity check is performed by the application server. On the one hand, the credibility of the verification result can be guaranteed to a certain extent, and on the other hand, multiple passes can be avoided. The risks and time consuming of data.
图5示出了一个实施例中验证应用证书的时序图。参考图5,终端上可运行应用,应用 在运行后,可触发生物认证授权请求。终端在检测到该生物认证授权请求时,通过运于TEE的TA从安全存储区域中获取该应用的证书链,并生成应用证书验证请求,将获取的证书链与应用证书验证请求,对应发送至该应用所对应的应用服务器。应用服务器在接收到应用证书验证请求后,在本地查询是否存储有与该证书链中的认证证书一致的认证证书。若存在,则依次校验认证证书、设备证书和应用证书,并反馈校验结果;若不存在,则通过安全通道将证书链发送至证书认证服务器(CA)或者密钥管理服务器(TAM),由CA或TAM依次校验认证证书、设备证书和应用证书,并反馈校验结果。FIG. 5 shows a timing diagram of verifying an application certificate in one embodiment. Referring to FIG. 5, an application can be run on the terminal, and after the application is run, a biometric authorization request can be triggered. When the terminal detects the biometric authentication authorization request, the terminal obtains the application certificate chain from the secure storage area through the TA running on the TEE, and generates an application certificate verification request, and sends the obtained certificate chain and the application certificate verification request to the corresponding The application server corresponding to the application. After receiving the application certificate verification request, the application server locally queries whether an authentication certificate consistent with the authentication certificate in the certificate chain is stored. If it exists, verify the authentication certificate, device certificate, and application certificate in turn, and feedback the verification result; if it does not exist, send the certificate chain to the certificate authentication server (CA) or key management server (TAM) through a secure channel. The CA or TAM sequentially verifies the authentication certificate, device certificate, and application certificate, and feeds back the verification result.
图6示出了一个实施例中密钥管理的原理架构图。参考图6,终端上可存储有认证证书(CA ROOT)、认证证书签发的设备证书(ATTK)、设备证书签发的应用证书(ASK)以及应用证书签发的业务证书(AK Authentication Key),形成以认证证书(CA ROOT)为源头的证书链;证书认证服务器(CA)或者密钥管理服务器(TAM)上存储有认证证书(CA ROOT)。这样,在后续验证证书合法性时,终端将待验证证书的证书链伴随验证请求上传,即可逐级验证证书合法性。其中,应用证书所对应的应用私钥用于签名生成业务证书的签名数据,应用证书的应用公钥用于解密业务证书的签名数据。业务密钥可以是AK(Authentication Key),该AK用于验证业务的合法性。FIG. 6 shows a principle architecture diagram of key management in one embodiment. Referring to FIG. 6, the terminal may store an authentication certificate (CAROOT), an equipment certificate (ATTK) issued by the authentication certificate, an application certificate (ASK) issued by the equipment certificate, and an application certificate (AKAuthentication Key) issued by the application certificate. The certificate (CAROOT) is the source certificate chain; the certificate authentication server (CA) or the key management server (TAM) stores the certificate (CAROOT). In this way, when the legitimacy of the certificate is subsequently verified, the terminal uploads the certificate chain of the certificate to be verified along with the verification request to verify the legitimacy of the certificate step by step. The application private key corresponding to the application certificate is used to sign the signature data of the service certificate, and the application public key of the application certificate is used to decrypt the signature data of the service certificate. The service key may be AK (Authentication Key), which is used to verify the legitimacy of the service.
图7为一个实施例中证书验证方法的流程示意图。本实施例主要以该证书验证方法应用于图1中的服务器120来举例说明。参照图7,该证书验证方法包括如下步骤:FIG. 7 is a schematic flowchart of a certificate verification method according to an embodiment. This embodiment mainly uses the certificate verification method applied to the server 120 in FIG. 1 as an example for illustration. Referring to FIG. 7, the certificate verification method includes the following steps:
S702,接收应用证书验证请求。S702. Receive an application certificate verification request.
在一个实施例中,服务器为应用服务器。可选地,终端在接收到通过应用所触发的生物认证授权请求时,即生成与应用对应的应用证书验证请求;将该应用的证书链与应用证书验证请求,对应发送至应用所对应的应用服务器。这样,应用服务器便接收到应用证书验证请求。In one embodiment, the server is an application server. Optionally, when the terminal receives the biometric authentication authorization request triggered by the application, the terminal generates an application certificate verification request corresponding to the application, and sends the application certificate chain and the application certificate verification request to the application corresponding to the application. server. In this way, the application server receives the application certificate verification request.
在一个实施例中,服务器为证书认证服务器或者密钥管理服务器。可选地,应用服务器在未在应用服务器上查找到与证书链中的认证证书一致的认证证书时,通过安全通道将应用证书验证请求转发至证书认证服务器或者密钥管理服务器;或者,应用服务器在判定应用证书验证请求中携带的安全级别高于应用服务器所能处理的安全级别时,通过安全通道将应用 证书验证请求转发至证书认证服务器或者密钥管理服务器;这样,证书认证服务器或者密钥管理服务器便接收到应用证书验证请求。In one embodiment, the server is a certificate authentication server or a key management server. Optionally, when the application server does not find an authentication certificate on the application server that is consistent with the authentication certificate in the certificate chain, the application server forwards the application certificate verification request to the certificate authentication server or key management server through a secure channel; or, the application server When determining that the security level carried in the application certificate verification request is higher than the security level that the application server can handle, the application certificate verification request is forwarded to the certificate authentication server or key management server through a secure channel; in this way, the certificate authentication server or key The management server receives the application certificate verification request.
S704,获取对应于应用证书验证请求的证书链;证书链包括认证证书、设备证书和应用证书;认证证书所对应的认证私钥用于签名生成设备证书的签名数据,认证证书的认证公钥用于解密设备证书的签名数据;设备证书所对应的设备私钥用于签名生成应用证书的签名数据,设备证书的设备公钥用于解密应用证书的签名数据。S704. Obtain a certificate chain corresponding to an application certificate verification request. The certificate chain includes an authentication certificate, a device certificate, and an application certificate. The authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate. The authentication public key is used for the authentication certificate. It is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate.
可以理解,终端在出厂后,是在终端的安全区域中逐级签发下一级证书的,确保信任链基于认证证书。每个证书的证书链,不仅包括其证书本身,还包括自源头起签发得到该证书的各证书。比如,设备证书的证书链包括认证证书和设备证书,应用证书的证书链包括认证证书、设备证书和应用证书,业务证书的证书链包括认证证书、设备证书、应用证书和业务证书,等。It can be understood that after the terminal leaves the factory, the next-level certificate is issued in the terminal's security zone one by one to ensure that the chain of trust is based on the authentication certificate. The certificate chain of each certificate includes not only the certificate itself, but also the certificates issued from the source to obtain the certificate. For example, the certificate chain of a device certificate includes an authentication certificate and a device certificate, the certificate chain of an application certificate includes an authentication certificate, a device certificate, and an application certificate, and the certificate chain of a service certificate includes an authentication certificate, a device certificate, an application certificate, and a service certificate.
S706,在本地存在与证书链中的认证证书一致的认证证书时,根据证书链中的认证证书的认证公钥验证设备证书和应用证书。S706: When an authentication certificate identical to the authentication certificate in the certificate chain exists locally, verify the device certificate and the application certificate according to the authentication public key of the authentication certificate in the certificate chain.
可选地,当服务器上存储有与该证书链中的认证证书一致的认证证书时,即判定该证书链中的认证证书是合法的。服务器然后根据该认证证书上的认证公钥解密设备证书上的签名数据得到第一摘要信息,并根据与终端约定的摘要信息提取方式提取设备证书上设备参数和设备公钥的第二摘要信息,比较第一摘要信息和第二摘要信息。当两者不一致时,则判定设备证书不合法,向终端反馈表示验证失败的验证结果。当第一摘要信息和第二摘要信息一致时,服务器则继续根据该设备证书上的设备公钥解密应用证书上的签名数据得到第三摘要信息,并根据与终端约定的摘要信息提取方式提取应用证书上应用参数和应用公钥的第四摘要信息,比较第三摘要信息和第四摘要信息。当两者不一致时,则判定设备证书不合法,向终端反馈表示验证失败的验证结果。当第三摘要信息和第四摘要信息一致时,则判定应用证书合法,向终端反馈表示验证通过的验证结果。Optionally, when an authentication certificate identical to the authentication certificate in the certificate chain is stored on the server, it is determined that the authentication certificate in the certificate chain is legal. The server then decrypts the signature data on the device certificate to obtain the first summary information according to the authentication public key on the authentication certificate, and extracts the second summary information of the device parameters and the device public key on the device certificate according to the summary information extraction method agreed with the terminal. Compare the first summary information and the second summary information. When the two are inconsistent, the device certificate is determined to be illegal, and a verification result indicating the verification failure is fed back to the terminal. When the first summary information and the second summary information are consistent, the server continues to decrypt the signature data on the application certificate according to the device public key on the device certificate to obtain the third summary information, and extracts the application according to the summary information extraction method agreed with the terminal. Compare the third summary information and the fourth summary information with the application parameters and the fourth summary information of the application public key on the certificate. When the two are inconsistent, the device certificate is determined to be illegal, and a verification result indicating the verification failure is fed back to the terminal. When the third summary information and the fourth summary information are consistent, it is determined that the application certificate is valid, and a verification result indicating that the verification is passed is fed back to the terminal.
可以理解,当服务器为应用服务器,应用服务器事先通过安全通道从证书认证服务器处获取了各证书认证服务器的认证证书。It can be understood that when the server is an application server, the application server obtains the authentication certificate of each certificate authentication server from the certificate authentication server through a secure channel in advance.
S708,当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。S708. When both the device certificate and the application certificate are passed, the feedback indicates that the verification result is passed.
可以理解,只有证书链中的各证书均验证通过时,才能授予应用进行生物认证的权限。 而只要证书链中有一个证书的合法性未验证通过,都不能授予应用进行生物认证的权限。It can be understood that the application can be granted the right to perform biometric authentication only when each certificate in the certificate chain is verified. As long as the validity of a certificate in the certificate chain is not verified, the application cannot be granted the right to perform biometric authentication.
上述证书验证方法,在需要进行证书验证时,直接获取对应于应用证书验证请求的证书链;由于该证书链中的认证证书所对应的认证私钥用于签名生成设备证书的签名数据,认证证书的认证公钥用于解密设备证书的签名数据,且设备证书所对应的设备私钥用于签名生成应用证书的签名数据,设备证书中的设备公钥用于解密应用证书中的签名数据,也就是说,设备证书及应用证书是基于认证证书逐级签发的,那么在存在与该证书链中的认证证书一致的认证证书时,也就是在确定认证证书可信时,即可根据证书链中的认证证书验证设备证书和应用证书,以在设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果,保证证书验证的有效性与高效性。In the above certificate verification method, when certificate verification is required, the certificate chain corresponding to the application certificate verification request is directly obtained; since the authentication private key corresponding to the authentication certificate in the certificate chain is used to sign the signature data of the device certificate, the authentication certificate The authentication public key is used to decrypt the signature data of the device certificate, and the device private key corresponding to the device certificate is used to sign the signature data of the application certificate. The device public key in the device certificate is used to decrypt the signature data in the application certificate. That is, the device certificate and application certificate are issued step by step based on the authentication certificate. When there is an authentication certificate that is consistent with the authentication certificate in the certificate chain, that is, when it is determined that the authentication certificate is trustworthy, it can be based on the certificate chain. The authentication certificate verifies the device certificate and the application certificate, so that when the device certificate and the application certificate are both verified, the feedback indicates that the verification result is passed to ensure the validity and efficiency of the certificate verification.
在一个实施例中,S706包括:在吊销认证证书列表中查询证书链中的认证证书;当证书链中的认证证书不存在于吊销认证证书列表中时,在本地查询与证书链中的认证证书一致的认证证书;当查询到与证书链中的认证证书一致的认证证书时,根据证书链中的认证证书的认证公钥验证设备证书;当设备证书验证通过时,根据设备证书的设备公钥验证应用证书。In one embodiment, S706 includes: querying the certification certificate in the certificate chain in the list of revoked certification certificates; when the certification certificate in the certificate chain does not exist in the list of revoked certification certificates, querying the certification certificate in the certificate chain locally. Consistent authentication certificate; when querying the authentication certificate that is consistent with the authentication certificate in the certificate chain, verify the device certificate according to the authentication public key of the authentication certificate in the certificate chain; when the device certificate passes the authentication, the device public key of the device certificate Verify application certificate.
在一个实施例中,该证书验证方法还包括:接收设备参数和设备公钥;获取设备参数和设备公钥的摘要信息;通过认证私钥加密摘要信息得到签名数据;根据加密得到的签名数据生成设备证书并反馈。In one embodiment, the certificate verification method further includes: receiving the device parameters and the device public key; obtaining the digest information of the device parameters and the device public key; encrypting the digest information by authenticating the private key to obtain signature data; and generating the encrypted signature data based on the encrypted signature data Equipment certification and feedback.
可以理解,这里证书验证方法实施例中服务器所执行的步骤,在前述的密钥管理方法实施例中已有说明,在此不再赘述。It can be understood that the steps performed by the server in the embodiment of the certificate verification method are described in the foregoing embodiment of the key management method, and are not repeated here.
本申请实施例中的密钥管理方法和证书验证方法,均可应用于生物认证标准中。生物认证标准比如腾讯公司研发的SOTER标准。将本申请实施例中的方法应用于SOTER标准后,让终端无需事先在产线上逐个上传设备ATTK至TAM,同样可以被SOTER标准支持,进一步方便接入SOTER的OEM(Original Equipment Manufacturer代工生产)厂商。Both the key management method and the certificate verification method in the embodiments of the present application can be applied to a biometric authentication standard. Biological certification standards such as the SOTER standard developed by Tencent. After applying the method in the embodiment of the present application to the SOTER standard, the terminal does not need to upload devices ATTK to TAM one by one on the production line in advance, and it can also be supported by the SOTER standard, which further facilitates the access to SOTER's OEM ) Vendor.
应该理解的是,虽然上述各实施例的流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,这些步骤可以以其它的顺序执行。而且,上述各实施例中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,这些子步骤或者阶段的执行顺序也不必然是依 次进行,而是可以与其它步骤或者其它步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that although the steps in the flowcharts of the foregoing embodiments are sequentially displayed in accordance with the instructions of the arrows, these steps are not necessarily performed in the order indicated by the arrows. Unless explicitly stated in this document, the execution of these steps is not strictly limited, and these steps can be performed in other orders. Moreover, at least a part of the steps in the above embodiments may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily performed at the same time, but may be performed at different times. These sub-steps or stages The execution order of is not necessarily performed sequentially, but may be performed in turn or alternately with at least a part of another step or a sub-step or stage of another step.
如图8所示,在一个实施例中,提供了一种密钥管理装置800。参照图8,该密钥管理装置800包括:生成模块801、发送模块802、接收模块803和存储模块804。As shown in FIG. 8, in one embodiment, a key management apparatus 800 is provided. Referring to FIG. 8, the key management apparatus 800 includes: a generating module 801, a sending module 802, a receiving module 803, and a storage module 804.
生成模块801,用于在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥。A generating module 801 is configured to generate a device key including a device public key and a device private key in a local security zone.
发送模块802,用于将本地的设备参数和设备公钥发送至证书认证服务器。The sending module 802 is configured to send a local device parameter and a device public key to a certificate authentication server.
接收模块803,用于接收证书认证服务器反馈的设备证书;设备证书的签名数据,通过证书认证服务器的认证私钥对设备参数和设备公钥签名生成。The receiving module 803 is configured to receive the device certificate fed back by the certificate authentication server; the signature data of the device certificate is generated by signing the device parameters and the device public key with the authentication private key of the certificate authentication server.
存储模块804,用于将设备私钥和设备证书存储于安全区域。The storage module 804 is configured to store the device private key and the device certificate in a secure area.
在一个实施例中,生成模块801还用于当获取到通过运行于本地的应用所触发的应用密钥生成指令时,在安全区域生成应用的应用密钥;应用密钥包括应用公钥和应用私钥;在安全区域,通过设备私钥对应用的应用参数和应用公钥进行签名,生成应用的应用证书。存储模块804还用于将应用私钥和应用证书对应存储于安全区域。In one embodiment, the generating module 801 is further configured to generate an application key of the application in a secure area when the application key generation instruction triggered by the application running locally is obtained; the application key includes the application public key and the application Private key; in a secure area, sign the application's application parameters and application public key with the device's private key to generate an application's application certificate. The storage module 804 is further configured to correspondingly store the application private key and the application certificate in a secure area.
在一个实施例中,生成模块801还用于获取应用的应用参数和应用公钥的摘要信息;通过设备私钥加密摘要信息得到签名数据;根据加密得到的签名数据生成应用的应用证书。In one embodiment, the generating module 801 is further configured to obtain the application parameters of the application and the digest information of the application public key; obtain the signature data by encrypting the digest information with the device private key; and generate the application certificate of the application according to the encrypted signature data.
在一个实施例中,存储模块804还用于获取包括认证私钥所对应认证公钥的认证证书;将认证证书、设备证书和应用证书作为应用的证书链;将证书链存储于安全区域。In one embodiment, the storage module 804 is further configured to obtain an authentication certificate including an authentication public key corresponding to the authentication private key; use the authentication certificate, device certificate, and application certificate as an application certificate chain; and store the certificate chain in a secure area.
如图9所示,在一个实施例中,密钥管理装置800还包括:授权模块805,用于在接收到通过应用所触发的生物认证授权请求时,生成与应用对应的应用证书验证请求;将应用的证书链与应用证书验证请求,对应发送至应用所对应的应用服务器;接收应用服务器根据应用服务器上存储的认证证书对接收到的证书链进行验证后反馈的验证结果;当验证结果表示验证通过时,授予应用进行生物认证的权限。As shown in FIG. 9, in one embodiment, the key management device 800 further includes: an authorization module 805 configured to generate an application certificate verification request corresponding to the application when a biometric authentication authorization request triggered by the application is received; Send the application certificate chain and application certificate verification request to the application server corresponding to the application; receive the verification result fed back by the application server after verifying the received certificate chain according to the authentication certificate stored on the application server; when the verification result indicates When the verification is passed, the application is granted the right to perform biometric authentication.
在一个实施例中,授权模块805还用于接收应用服务器未存储有认证证书时所反馈的、通过安全信道从证书认证服务器获取到的验证结果;验证结果由证书认证服务器在通过安全信道接收到应用服务器上传的证书链后,根据证书认证服务器上存储的认证证书对证书链验证得到。In one embodiment, the authorization module 805 is further configured to receive the verification result obtained from the certificate authentication server through the secure channel and fed back when the application server does not store the authentication certificate; the verification result is received by the certificate authentication server through the secure channel. After the certificate chain uploaded by the application server, the certificate chain is verified according to the authentication certificate stored on the certificate authentication server.
如图10所示,在一个实施例中,提供了一种证书验证装置1000。参照图10,该证书验证装置1000包括:接收模块1001、获取模块1002、验证模块1003和反馈模块1004。As shown in FIG. 10, in one embodiment, a certificate verification apparatus 1000 is provided. Referring to FIG. 10, the certificate verification apparatus 1000 includes a receiving module 1001, an obtaining module 1002, a verification module 1003, and a feedback module 1004.
接收模块1001,用于接收应用证书验证请求。The receiving module 1001 is configured to receive an application certificate verification request.
获取模块1002,用于获取对应于应用证书验证请求的证书链;证书链包括认证证书、设备证书和应用证书;认证证书所对应的认证私钥用于签名生成设备证书的签名数据,认证证书的认证公钥用于解密设备证书的签名数据;设备证书所对应的设备私钥用于签名生成应用证书的签名数据,设备证书的设备公钥用于解密应用证书的签名数据。The obtaining module 1002 is configured to obtain a certificate chain corresponding to an application certificate verification request. The certificate chain includes an authentication certificate, a device certificate, and an application certificate. The authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate. The authentication public key is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate.
验证模块1003,用于在本地存在与证书链中的认证证书一致的认证证书时,根据证书链中的认证证书的认证公钥验证设备证书和应用证书。The verification module 1003 is configured to verify the device certificate and the application certificate according to the authentication public key of the authentication certificate in the certificate chain when an authentication certificate identical to the authentication certificate in the certificate chain exists locally.
反馈模块1004,用于当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。The feedback module 1004 is configured to, when the device certificate and the application certificate both pass the verification, the feedback indicates the verification result that the verification passes.
在一个实施例中,验证模块1003还用于在吊销认证证书列表中查询证书链中的认证证书;当证书链中的认证证书不存在于吊销认证证书列表中时,在本地查询与证书链中的认证证书一致的认证证书;当查询到与证书链中的认证证书一致的认证证书时,根据证书链中的认证证书的认证公钥验证设备证书;当设备证书验证通过时,根据设备证书的设备公钥验证应用证书。In one embodiment, the verification module 1003 is further configured to query the certificate in the certificate chain in the list of revoked certificates; when the certificate in the certificate chain does not exist in the list of revoked certificates, query locally and in the certificate chain When the authentication certificate that is consistent with the authentication certificate in the certificate chain is found, the device certificate is verified according to the authentication public key of the authentication certificate in the certificate chain; when the device certificate is verified, the device certificate is verified according to the Device public key verification application certificate.
如图11所示,在一个实施例中,证书验证装置1000还包括:签发模块1005,用于接收设备参数和设备公钥;获取设备参数和设备公钥的摘要信息;通过认证私钥加密摘要信息得到签名数据;根据加密得到的签名数据生成设备证书并反馈。As shown in FIG. 11, in one embodiment, the certificate verification device 1000 further includes: a signing module 1005 for receiving device parameters and a device public key; obtaining summary information of the device parameters and the device public key; and encrypting the summary by authenticating the private key. The information obtains signature data; a device certificate is generated and fed back based on the encrypted signature data.
图12示出了一个实施例中计算机设备的内部结构图。该计算机设备可以是图1中的终端110。如图12所示,该计算机设备包括通过系统总线连接的处理器、存储器、网络接口、输入设备和显示屏。其中,存储器包括非易失性存储介质和内存储器。该计算机设备的非易失性存储介质存储有操作系统,还可存储有计算机程序,该计算机程序被处理器执行时,可使得处理器实现密钥管理方法。该内存储器中也可储存有计算机程序,该计算机程序被处理器执行时,可使得处理器执行密钥管理方法。计算机设备的显示屏可以是液晶显示屏或者电子墨水显示屏等,输入装置可以是显示屏上覆盖的触摸层,也可以是计算机设备外壳上设置的按键、轨迹球或触控板,也可以是外接的键盘、触控板或鼠标等。本领域技术人员可以理 解,图12中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。FIG. 12 shows an internal structure diagram of a computer device in one embodiment. The computer device may be the terminal 110 in FIG. 1. As shown in FIG. 12, the computer device includes a processor, a memory, a network interface, an input device, and a display screen connected through a system bus. The memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium of the computer device stores an operating system and a computer program. When the computer program is executed by the processor, the processor can implement the key management method. A computer program may also be stored in the internal memory, and when the computer program is executed by the processor, the processor may execute the key management method. The display screen of a computer device may be a liquid crystal display or an electronic ink display, etc. The input device may be a touch layer covered on the display screen, or a button, a trackball or a touchpad provided on the computer equipment shell, or it may be External keyboard, trackpad, or mouse. Those skilled in the art can understand that the structure shown in FIG. 12 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied. The specific computer equipment may be Include more or fewer parts than shown in the figure, or combine certain parts, or have a different arrangement of parts.
图13示出了一个实施例中计算机设备的内部结构图。该计算机设备可以是图1中的服务器120。如图13所示,该计算机设备包括通过系统总线连接的处理器、存储器和网络接口。其中,存储器包括非易失性存储介质和内存储器。该计算机设备的非易失性存储介质存储有操作系统,还可存储有计算机程序,该计算机程序被处理器执行时,可使得处理器实现证书验证方法。该内存储器中也可储存有计算机程序,该计算机程序被处理器执行时,可使得处理器执行证书验证方法。本领域技术人员可以理解,图13中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。FIG. 13 shows an internal structure diagram of a computer device in one embodiment. The computer device may be the server 120 in FIG. 1. As shown in FIG. 13, the computer device includes a processor, a memory, and a network interface connected through a system bus. The memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium of the computer device stores an operating system and a computer program. When the computer program is executed by the processor, the processor can implement a certificate verification method. A computer program may also be stored in the internal memory, and when the computer program is executed by the processor, the processor may cause the processor to perform a certificate verification method. Those skilled in the art can understand that the structure shown in FIG. 13 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied. The specific computer equipment may be Include more or fewer parts than shown in the figure, or combine certain parts, or have a different arrangement of parts.
在一个实施例中,本申请提供的密钥管理装置与证书验证装置均可以实现为一种计算机程序的形式,计算机程序可在如图12或13所示的计算机设备上运行,计算机设备的非易失性存储介质可存储组成该密钥管理装置或证书验证装置的各个程序模块,比如,图8所示的生成模块801、发送模块802、接收模块803和存储模块804等。各个程序模块组成的计算机程序使得处理器执行本说明书中描述的本申请各个实施例的密钥管理方法或证书验证方法中的步骤。In one embodiment, both the key management device and the certificate verification device provided in this application may be implemented in the form of a computer program. The computer program may be run on a computer device as shown in FIG. 12 or 13. The volatile storage medium may store various program modules constituting the key management device or the certificate verification device, such as the generating module 801, the sending module 802, the receiving module 803, and the storage module 804 shown in FIG. The computer program composed of each program module causes the processor to execute the steps in the key management method or the certificate verification method of each embodiment of the application described in this specification.
例如,图12所示的计算机设备可以通过如图8所示的密钥管理装置800中的生成模块801在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥。通过发送模块802将本地的设备参数和设备公钥发送至证书认证服务器。通过接收模块803接收证书认证服务器反馈的设备证书;设备证书的签名数据,通过证书认证服务器的认证私钥对设备参数和设备公钥签名生成。通过存储模块804将设备私钥和设备证书存储于安全区域。For example, the computer device shown in FIG. 12 may generate a device key including a device public key and a device private key in a local security area by using the generating module 801 in the key management apparatus 800 shown in FIG. 8. The local device parameters and the device public key are sent to the certificate authentication server through the sending module 802. The receiving module 803 receives the device certificate fed back by the certificate authentication server; the signature data of the device certificate is generated by signing the device parameters and the device public key with the authentication private key of the certificate authentication server. The device private key and the device certificate are stored in the secure area through the storage module 804.
例如,图13所示的计算机设备可以通过如图10所示的证书验证装置1000中的接收模块1001接收应用证书验证请求。通过获取模块1002获取对应于应用证书验证请求的证书链;证书链包括认证证书、设备证书和应用证书;认证证书所对应的认证私钥用于签名生成设备证书的签名数据,认证证书的认证公钥用于解密设备证书的签名数据;设备证书所对应的设 备私钥用于签名生成应用证书的签名数据,设备证书的设备公钥用于解密应用证书的签名数据。通过验证模块1003在本地存在与证书链中的认证证书一致的认证证书时,根据证书链中的认证证书的认证公钥验证设备证书和应用证书。通过反馈模块1004当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。For example, the computer device shown in FIG. 13 may receive the application certificate verification request through the receiving module 1001 in the certificate verification apparatus 1000 shown in FIG. 10. Acquire a certificate chain corresponding to an application certificate verification request through the acquisition module 1002; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate, and the authentication public certificate The key is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate. When the authentication module 1003 locally has an authentication certificate consistent with the authentication certificate in the certificate chain, the device certificate and the application certificate are verified according to the authentication public key of the authentication certificate in the certificate chain. Through the feedback module 1004, when both the device certificate and the application certificate are verified to pass, the feedback indicates the verification result that the verification has passed.
在一个实施例中,提供了一种密钥管理系统,包括终端和证书认证服务器。其中,终端用于在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;将本地的设备参数和设备公钥发送至证书认证服务器。证书认证服务器用于向终端反馈设备证书;反馈的设备证书的签名数据,通过证书认证服务器根据证书认证服务器的认证私钥对设备参数和设备公钥签名生成。终端还用于将设备私钥和设备证书存储于安全区域。In one embodiment, a key management system is provided, including a terminal and a certificate authentication server. The terminal is used to generate a device key including a device public key and a device private key in a local security area; and send the local device parameters and the device public key to a certificate authentication server. The certificate authentication server is used to feed back the device certificate to the terminal; the signed data of the returned device certificate is generated by the certificate authentication server to sign the device parameters and the device public key according to the authentication private key of the certificate authentication server. The terminal is also used to store the device private key and device certificate in a secure area.
在一个实施例中,密钥管理系统还包括应用服务器。终端还用于生成运行于本地的应用的证书链;在接收到通过应用所触发的生物认证授权请求时,生成与应用对应的应用证书验证请求;将应用的证书链与应用证书验证请求,对应发送至应用所对应的应用服务器。In one embodiment, the key management system further includes an application server. The terminal is also used to generate the certificate chain of the application running locally; when receiving the biometric authentication authorization request triggered by the application, generating an application certificate verification request corresponding to the application; corresponding the application certificate chain with the application certificate verification request, Send to the application server corresponding to the application.
应用服务器用于在存储有证书链中的认证证书时,根据存储的认证证书对接收到的证书链进行验证后向终端反馈验证结果;在未存储有证书链中的认证证书时,通过安全通道将证书链传递至证书认证服务器,并从证书认证服务器获取证书认证服务器对证书链验证得到的验证结果反馈至终端。The application server is used to verify the received certificate chain according to the stored authentication certificate when the authentication certificate in the certificate chain is stored, and then feed back the verification result to the terminal. When the authentication certificate in the certificate chain is not stored, it passes the secure channel. The certificate chain is passed to the certificate authentication server, and the verification result obtained by the certificate authentication server for the certificate chain verification is fed back from the certificate authentication server to the terminal.
其中,证书链包括认证证书、设备证书和应用证书;认证证书所对应的认证私钥用于签名生成设备证书的签名数据,认证证书的认证公钥用于解密设备证书的签名数据;设备证书所对应的设备私钥用于签名生成应用证书的签名数据,设备证书的设备公钥用于解密应用证书的签名数据。Among them, the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign the signature data of the device certificate; the authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; The corresponding device private key is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the signature data of the application certificate.
在一个实施例中,密钥管理系统还包括密钥管理服务器。应用服务器还用于在未存储有证书链中的认证证书时,通过安全通道将证书链传递至证书密钥管理服务器,并从密钥管理服务器获取密钥管理服务器对证书链验证得到的验证结果反馈至终端。In one embodiment, the key management system further includes a key management server. The application server is also used to pass the certificate chain to the certificate key management server through a secure channel when the authentication certificate in the certificate chain is not stored, and obtain the verification result obtained by the key management server for the certificate chain verification from the key management server. Feedback to the terminal.
在一个实施例中,终端还用于当获取到通过运行于本地的应用所触发的应用密钥生成指令时,在安全区域生成应用的应用密钥;应用密钥包括应用公钥和应用私钥;在安全区域,通过设备私钥对应用的应用参数和应用公钥进行签名,生成应用的应用证书;将应用私钥和 应用证书对应存储于安全区域。In one embodiment, the terminal is further configured to generate an application key of the application in a secure area when the application key generation instruction triggered by the application running locally is obtained; the application key includes an application public key and an application private key In the secure area, the application's application parameters and application public key are signed by the device's private key to generate the application's application certificate; the application private key and the application certificate are correspondingly stored in the secure area.
在一个实施例中,终端还用于获取应用的应用参数和应用公钥的摘要信息;通过设备私钥加密摘要信息得到签名数据;根据加密得到的签名数据生成应用的应用证书。In one embodiment, the terminal is further configured to obtain the application parameter of the application and the digest information of the application public key; obtain the signature data by encrypting the digest information with the device private key; and generate the application certificate of the application according to the encrypted signature data.
在一个实施例中,终端还用于获取包括认证私钥所对应认证公钥的认证证书;将认证证书、设备证书和应用证书作为应用的证书链;将证书链存储于安全区域。In one embodiment, the terminal is further configured to obtain an authentication certificate including an authentication public key corresponding to the authentication private key; use the authentication certificate, device certificate, and application certificate as an application certificate chain; and store the certificate chain in a secure area.
在一个实施例中,应用服务器或密钥管理服务器或证书认证服务器还用于在吊销认证证书列表中查询证书链中的认证证书;当证书链中的认证证书不存在于吊销认证证书列表中时,在本地查询与证书链中的认证证书一致的认证证书;当查询到与证书链中的认证证书一致的认证证书时,根据证书链中的认证证书的认证公钥验证设备证书;当设备证书验证通过时,根据设备证书的设备公钥验证应用证书。In one embodiment, the application server, key management server, or certificate authentication server is further configured to query the certificate in the certificate chain in the list of revoked certificates; when the certificate in the certificate chain does not exist in the list of revoked certificates , Query the authentication certificate that is consistent with the authentication certificate in the certificate chain locally; when querying the authentication certificate that is consistent with the authentication certificate in the certificate chain, verify the device certificate according to the authentication public key of the authentication certificate in the certificate chain; when the device certificate When the verification is passed, the application certificate is verified based on the device public key of the device certificate.
在一个实施例中,证书认证服务器还用于接收设备参数和设备公钥;获取设备参数和设备公钥的摘要信息;通过认证私钥加密摘要信息得到签名数据;根据加密得到的签名数据生成设备证书并反馈。In one embodiment, the certificate authentication server is further configured to receive the device parameters and the device public key; obtain the digest information of the device parameters and the device public key; encrypt the digest information by authenticating the private key to obtain signature data; and generate the device based on the encrypted signature data Certificate and feedback.
在一个实施例中,提供了一种计算机可读存储介质,该计算机可读存储介质上存储有计算机程序,该计算机程序被处理器执行时,使得处理器执行上述方法实施例所述的步骤。In one embodiment, a computer-readable storage medium is provided. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor causes the processor to perform the steps described in the foregoing method embodiment.
在一个实施例中,提供了一种计算机设备,包括存储器和处理器,存储器中储存有计算机程序,计算机程序被处理器执行时,使得处理器执行上述方法实施例所述的步骤。In one embodiment, a computer device is provided, which includes a memory and a processor. The memory stores a computer program. When the computer program is executed by the processor, the processor is caused to perform the steps described in the foregoing method embodiment.
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一非易失性计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,本申请所提供的各实施例中所使用的对存储器、存储、数据库或其它介质的任何引用,均可包括非易失性和/或易失性存储器。非易失性存储器可包括只读存储器(ROM)、可编程ROM(PROM)、电可编程ROM(EPROM)、电可擦除可编程ROM(EEPROM)或闪存。易失性存储器可包括随机存取存储器(RAM)或者外部高速缓冲存储器。作为说明而非局限,RAM以多种形式可得,诸如静态RAM(SRAM)、动态RAM(DRAM)、同步DRAM(SDRAM)、双数据率SDRAM(DDRSDRAM)、增强型SDRAM(ESDRAM)、同步链路(Synchlink)DRAM(SLDRAM)、存储器总线(Rambus) 直接RAM(RDRAM)、直接存储器总线动态RAM(DRDRAM)、以及存储器总线动态RAM(RDRAM)等。A person of ordinary skill in the art can understand that all or part of the processes in the methods of the foregoing embodiments can be implemented by using a computer program to instruct related hardware. The program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it may include the processes of the embodiments of the methods described above. Wherein, any reference to the storage, storage, database, or other media used in the embodiments provided in this application may include non-volatile and / or volatile storage. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous chain Synchlink DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
以上实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。The technical features of the above embodiments can be arbitrarily combined. In order to make the description concise, all possible combinations of the technical features in the above embodiments are not described. However, as long as there is no contradiction in the combination of these technical features, all It is considered to be the range described in this specification.
以上实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对本申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。The above embodiments only express several implementation manners of the present application, and their descriptions are more specific and detailed, but they cannot be understood as limiting the patent scope of the present application. It should be noted that, for those of ordinary skill in the art, without departing from the concept of the present application, several modifications and improvements can be made, and these all belong to the protection scope of the present application. Therefore, the protection scope of this application patent shall be subject to the appended claims.

Claims (23)

  1. 一种密钥管理方法,其特征在于,应用于终端,所述方法包括:A key management method, which is applied to a terminal, and the method includes:
    在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;Generate a device key including the device public key and device private key in the local security zone;
    将本地的设备参数和所述设备公钥发送至证书认证服务器;Sending the local device parameters and the device public key to a certificate authentication server;
    接收所述证书认证服务器反馈的设备证书;所述设备证书的签名数据,通过所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;Receiving a device certificate fed back by the certificate authentication server; signature data of the device certificate is generated by signing the device parameters and the device public key with an authentication private key of the certificate authentication server;
    将所述设备私钥和所述设备证书存储于所述安全区域。The device private key and the device certificate are stored in the secure area.
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:The method according to claim 1, further comprising:
    当获取到通过运行于本地的应用所触发的应用密钥生成指令时,在所述安全区域生成所述应用的应用密钥;所述应用密钥包括应用公钥和应用私钥;When an application key generation instruction triggered by an application running locally is obtained, an application key of the application is generated in the secure area; the application key includes an application public key and an application private key;
    在所述安全区域,通过所述设备私钥对所述应用的应用参数和所述应用公钥进行签名,生成所述应用的应用证书;Signing the application parameter of the application and the application public key with the device private key in the secure area to generate an application certificate for the application;
    将所述应用私钥和所述应用证书对应存储于所述安全区域。The application private key and the application certificate are correspondingly stored in the secure area.
  3. 根据权利要求2所述的方法,其特征在于,所述通过所述设备私钥对所述应用的应用参数和所述应用公钥进行签名,生成所述应用的应用证书,包括:The method according to claim 2, wherein the signing the application parameter of the application and the application public key by the device private key, and generating the application certificate of the application, comprise:
    获取所述应用的应用参数和所述应用公钥的摘要信息;Obtaining application parameters of the application and summary information of the application public key;
    通过所述设备私钥加密所述摘要信息得到签名数据;Encrypting the digest information by using the device private key to obtain signature data;
    根据加密得到的所述签名数据生成所述应用的应用证书。Generate an application certificate of the application according to the encrypted signature data.
  4. 根据权利要求2所述的方法,其特征在于,所述方法还包括:The method according to claim 2, further comprising:
    获取包括所述认证私钥所对应认证公钥的认证证书;Obtaining an authentication certificate including an authentication public key corresponding to the authentication private key;
    将所述认证证书、所述设备证书和所述应用证书作为所述应用的证书链;Using the authentication certificate, the device certificate, and the application certificate as a certificate chain of the application;
    将所述证书链存储于所述安全区域。The certificate chain is stored in the secure area.
  5. 根据权利要求4所述的方法,其特征在于,所述方法还包括:The method according to claim 4, further comprising:
    在接收到通过所述应用所触发的生物认证授权请求时,生成与所述应用对应的应用证书验证请求;When receiving a biometric authentication authorization request triggered by the application, generating an application certificate verification request corresponding to the application;
    将所述应用的证书链与所述应用证书验证请求,对应发送至所述应用所对应的应用服务器;Correspondingly sending the application certificate chain and the application certificate verification request to the application server corresponding to the application;
    接收所述应用服务器根据所述应用服务器上存储的认证证书对接收到的证书链进行验证后反馈的验证结果;Receiving the verification result fed back by the application server after verifying the received certificate chain according to the authentication certificate stored on the application server;
    当所述验证结果表示验证通过时,授予所述应用进行生物认证的权限。When the verification result indicates that the verification is passed, the application is granted the right to perform biometric authentication.
  6. 根据权利要求5所述的方法,其特征在于,所述方法还包括:The method according to claim 5, further comprising:
    接收所述应用服务器未存储有所述认证证书时所反馈的、通过安全信道从所述证书认证服务器获取到的验证结果;所述验证结果由所述证书认证服务器在通过所述安全信道接收到所述应用服务器上传的所述证书链后,根据所述证书认证服务器上存储的认证证书对所述证书链验证得到。Receiving a verification result obtained when the application server does not store the authentication certificate and obtained from the certificate authentication server through a secure channel; the verification result is received by the certificate authentication server through the secure channel After the certificate chain uploaded by the application server, the certificate chain is verified according to an authentication certificate stored on the certificate authentication server.
  7. 一种证书验证方法,其特征在于,应用于证书认证服务器,所述方法包括:A certificate verification method, which is characterized in that it is applied to a certificate authentication server, and the method includes:
    接收应用证书验证请求;Receiving an application certificate verification request;
    获取对应于所述应用证书验证请求的证书链;所述证书链包括认证证书、设备证书和应用证书;所述认证证书所对应的认证私钥用于签名生成所述设备证书的签名数据,所述认证证书的认证公钥用于解密所述设备证书的签名数据;所述设备证书所对应的设备私钥用于签名生成所述应用证书的签名数据,所述设备证书的设备公钥用于解密所述应用证书的签名数据;Obtaining a certificate chain corresponding to the application certificate verification request; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign signature data for generating the device certificate, so The authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to Decrypting the signature data of the application certificate;
    在本地存在与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书和所述应用证书;When an authentication certificate identical to the authentication certificate in the certificate chain exists locally, verifying the device certificate and the application certificate according to an authentication public key of the authentication certificate in the certificate chain;
    当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。When both the device certificate and the application certificate pass, the feedback indicates the verification result that the verification passes.
  8. 根据权利要求7所述的方法,其特征在于,所述在本地存在与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书中的认证公钥验证所述设备证书和所述应用证书,包括:The method according to claim 7, characterized in that, when an authentication certificate identical to the authentication certificate in the certificate chain exists locally, the authentication is performed according to an authentication public key in the authentication certificate in the certificate chain. The device certificate and the application certificate include:
    在吊销认证证书列表中查询所述证书链中的认证证书;Query the certificate in the certificate chain in the list of revoked certificates;
    当所述证书链中的认证证书不存在于所述吊销认证证书列表中时,在本地查询与所述证书链中的认证证书一致的认证证书;When the authentication certificate in the certificate chain does not exist in the list of revoked authentication certificates, query locally for an authentication certificate that is consistent with the authentication certificate in the certificate chain;
    当查询到与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书;When an authentication certificate identical to the authentication certificate in the certificate chain is found, verifying the device certificate according to the authentication public key of the authentication certificate in the certificate chain;
    当所述设备证书验证通过时,根据所述设备证书的设备公钥验证所述应用证书。When the device certificate verification is passed, the application certificate is verified according to a device public key of the device certificate.
  9. 根据权利要求7所述的方法,其特征在于,所述方法还包括:The method according to claim 7, further comprising:
    接收设备参数和设备公钥;Receive equipment parameters and equipment public key;
    获取所述设备参数和所述设备公钥的摘要信息;Obtaining the device parameters and summary information of the device public key;
    通过认证私钥加密所述摘要信息得到签名数据;Encrypting the digest information by authenticating the private key to obtain signature data;
    根据加密得到的所述签名数据生成所述设备证书并反馈。Generate the device certificate according to the encrypted signature data and feed it back.
  10. 一种密钥管理装置,其特征在于,所述装置包括:A key management device, characterized in that the device includes:
    生成模块,用于在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;A generating module for generating a device key including a device public key and a device private key in a local security zone;
    发送模块,用于将本地的设备参数和所述设备公钥发送至证书认证服务器;A sending module, configured to send a local device parameter and the device public key to a certificate authentication server;
    接收模块,用于接收所述证书认证服务器反馈的设备证书;所述设备证书的签名数据,通过所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;A receiving module, configured to receive a device certificate fed back by the certificate authentication server; signature data of the device certificate is generated by signing the device parameters and the device public key using an authentication private key of the certificate authentication server;
    存储模块,用于将所述设备私钥和所述设备证书存储于所述安全区域。A storage module, configured to store the device private key and the device certificate in the secure area.
  11. 一种证书验证装置,其特征在于,所述装置包括:A certificate verification device, characterized in that the device includes:
    接收模块,用于接收应用证书验证请求;A receiving module for receiving an application certificate verification request;
    获取模块,用于获取对应于所述应用证书验证请求的证书链;所述证书链包括认证证书、设备证书和应用证书;所述认证证书所对应的认证私钥用于签名生成所述设备证书的签名数据,所述认证证书的认证公钥用于解密所述设备证书的签名数据;所述设备证书所对应的设备私钥用于签名生成所述应用证书的签名数据,所述设备证书的设备公钥用于解密所述应用证书的签名数据;An obtaining module, configured to obtain a certificate chain corresponding to the application certificate verification request; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign and generate the device certificate The signature public data of the authentication certificate is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate; The device public key is used to decrypt the signature data of the application certificate;
    验证模块,用于在本地存在与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书和所述应用证书;A verification module, configured to verify the device certificate and the application certificate according to an authentication public key of the authentication certificate in the certificate chain when an authentication certificate identical to the authentication certificate in the certificate chain exists locally;
    反馈模块,用于当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。A feedback module is used to indicate that the verification result is passed when the device certificate and the application certificate are both verified.
  12. 一种密钥管理系统,其特征在于,所述系统包括终端和证书认证服务器;其中,A key management system, characterized in that the system includes a terminal and a certificate authentication server;
    所述终端用于在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;将本地的设备参数和所述设备公钥发送至所述证书认证服务器;The terminal is configured to generate a device key including a device public key and a device private key in a local security area; and send the local device parameters and the device public key to the certificate authentication server;
    所述证书认证服务器用于向所述终端反馈设备证书;反馈的所述设备证书的签名数据,通过所述证书认证服务器根据所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;The certificate authentication server is configured to feed back the device certificate to the terminal; the returned signature data of the device certificate is used by the certificate authentication server to pair the device parameters and the device according to the authentication private key of the certificate authentication server. Public key signature generation;
    所述终端还用于将所述设备私钥和所述设备证书存储于所述安全区域。The terminal is further configured to store the device private key and the device certificate in the secure area.
  13. 根据权利要求12所述的系统,其特征在于,还包括应用服务器;所述终端还用于生成运行于本地的应用的证书链;在接收到通过所述应用所触发的生物认证授权请求时,生成与所述应用对应的应用证书验证请求;将所述应用的证书链与所述应用证书验证请求,对应发送至所述应用所对应的所述应用服务器;The system according to claim 12, further comprising an application server; the terminal is further configured to generate a certificate chain running in a local application; upon receiving a biometric authentication authorization request triggered by the application, Generating an application certificate verification request corresponding to the application; and sending the application certificate chain and the application certificate verification request to the application server corresponding to the application;
    所述应用服务器用于在存储有所述证书链中的认证证书时,根据存储的认证证书对接收到的证书链进行验证后向所述终端反馈验证结果;在未存储有所述证书链中的认证证书时,通过安全通道将所述证书链传递至所述证书认证服务器,并从所述证书认证服务器获取所述证书认证服务器对所述证书链验证得到的验证结果反馈至所述终端;The application server is configured to, when the authentication certificate in the certificate chain is stored, verify the received certificate chain according to the stored authentication certificate, and feed back the verification result to the terminal; if the certificate chain is not stored, When the certificate is authenticated, the certificate chain is passed to the certificate authentication server through a secure channel, and the verification result obtained by the certificate authentication server to verify the certificate chain is fed back from the certificate authentication server to the terminal;
    其中,所述证书链包括认证证书、设备证书和应用证书;所述认证证书所对应的认证私钥用于签名生成所述设备证书的签名数据,所述认证证书的认证公钥用于解密所述设备证书的签名数据;所述设备证书所对应的设备私钥用于签名生成所述应用证书的签名数据,所述设备证书的设备公钥用于解密所述应用证书的签名数据。The certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign signature data of the device certificate, and the authentication public key of the authentication certificate is used to decrypt the certificate. The device certificate ’s signature data; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to decrypt the application certificate ’s signature data.
  14. 一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,所述计算机程序被处理器执行时,使得所述处理器执行如权利要求1至9中任一项所述的方法的步骤。A computer-readable storage medium having a computer program stored on the computer-readable storage medium. When the computer program is executed by a processor, the processor causes the processor to execute the computer program according to any one of claims 1 to 9. Method steps.
  15. 一种计算机设备,包括存储器和处理器,所述存储器中储存有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:A computer device includes a memory and a processor. The memory stores a computer program. When the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    在本地的安全区域,生成包括设备公钥和设备私钥的设备密钥;Generate a device key including the device public key and device private key in the local security zone;
    将本地的设备参数和所述设备公钥发送至证书认证服务器;Sending the local device parameters and the device public key to a certificate authentication server;
    接收所述证书认证服务器反馈的设备证书;所述设备证书的签名数据,通过所述证书认证服务器的认证私钥对所述设备参数和所述设备公钥签名生成;Receiving a device certificate fed back by the certificate authentication server; signature data of the device certificate is generated by signing the device parameters and the device public key with an authentication private key of the certificate authentication server;
    将所述设备私钥和所述设备证书存储于所述安全区域。The device private key and the device certificate are stored in the secure area.
  16. 根据权利要求15所述的计算机设备,其特征在于,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:The computer device according to claim 15, wherein when the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    当获取到通过运行于本地的应用所触发的应用密钥生成指令时,在所述安全区域生成所述应用的应用密钥;所述应用密钥包括应用公钥和应用私钥;When an application key generation instruction triggered by an application running locally is obtained, an application key of the application is generated in the secure area; the application key includes an application public key and an application private key;
    在所述安全区域,通过所述设备私钥对所述应用的应用参数和所述应用公钥进行签名,生成所述应用的应用证书;Signing the application parameter of the application and the application public key with the device private key in the secure area to generate an application certificate for the application;
    将所述应用私钥和所述应用证书对应存储于所述安全区域。The application private key and the application certificate are correspondingly stored in the secure area.
  17. 根据权利要求16所述的计算机设备,其特征在于,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:The computer device of claim 16, wherein when the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    获取所述应用的应用参数和所述应用公钥的摘要信息;Obtaining application parameters of the application and summary information of the application public key;
    通过所述设备私钥加密所述摘要信息得到签名数据;Encrypting the digest information by using the device private key to obtain signature data;
    根据加密得到的所述签名数据生成所述应用的应用证书。Generate an application certificate of the application according to the encrypted signature data.
  18. 根据权利要求16所述的计算机设备,其特征在于,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:The computer device of claim 16, wherein when the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    获取包括所述认证私钥所对应认证公钥的认证证书;Obtaining an authentication certificate including an authentication public key corresponding to the authentication private key;
    将所述认证证书、所述设备证书和所述应用证书作为所述应用的证书链;Using the authentication certificate, the device certificate, and the application certificate as a certificate chain of the application;
    将所述证书链存储于所述安全区域。The certificate chain is stored in the secure area.
  19. 根据权利要求18所述的计算机设备,其特征在于,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:The computer device according to claim 18, wherein when the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    在接收到通过所述应用所触发的生物认证授权请求时,生成与所述应用对应的应用证书验证请求;When receiving a biometric authentication authorization request triggered by the application, generating an application certificate verification request corresponding to the application;
    将所述应用的证书链与所述应用证书验证请求,对应发送至所述应用所对应的应用服务器;Correspondingly sending the application certificate chain and the application certificate verification request to the application server corresponding to the application;
    接收所述应用服务器根据所述应用服务器上存储的认证证书对接收到的证书链进行验证 后反馈的验证结果;Receiving the verification result fed back by the application server after verifying the received certificate chain according to the authentication certificate stored on the application server;
    当所述验证结果表示验证通过时,授予所述应用进行生物认证的权限。When the verification result indicates that the verification is passed, the application is granted the right to perform biometric authentication.
  20. 根据权利要求19所述的计算机设备,其特征在于,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:The computer device according to claim 19, wherein when the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    接收所述应用服务器未存储有所述认证证书时所反馈的、通过安全信道从所述证书认证服务器获取到的验证结果;所述验证结果由所述证书认证服务器在通过所述安全信道接收到所述应用服务器上传的所述证书链后,根据所述证书认证服务器上存储的认证证书对所述证书链验证得到。Receiving a verification result obtained when the application server does not store the authentication certificate and obtained from the certificate authentication server through a secure channel; the verification result is received by the certificate authentication server through the secure channel After the certificate chain uploaded by the application server, the certificate chain is verified according to an authentication certificate stored on the certificate authentication server.
  21. 一种计算机设备,包括存储器和处理器,所述存储器中储存有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:A computer device includes a memory and a processor. The memory stores a computer program. When the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    接收应用证书验证请求;Receiving an application certificate verification request;
    获取对应于所述应用证书验证请求的证书链;所述证书链包括认证证书、设备证书和应用证书;所述认证证书所对应的认证私钥用于签名生成所述设备证书的签名数据,所述认证证书的认证公钥用于解密所述设备证书的签名数据;所述设备证书所对应的设备私钥用于签名生成所述应用证书的签名数据,所述设备证书的设备公钥用于解密所述应用证书的签名数据;Obtaining a certificate chain corresponding to the application certificate verification request; the certificate chain includes an authentication certificate, a device certificate, and an application certificate; the authentication private key corresponding to the authentication certificate is used to sign signature data for generating the device certificate, so The authentication public key of the authentication certificate is used to decrypt the signature data of the device certificate; the device private key corresponding to the device certificate is used to sign the signature data of the application certificate, and the device public key of the device certificate is used to Decrypting the signature data of the application certificate;
    在本地存在与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书和所述应用证书;When an authentication certificate identical to the authentication certificate in the certificate chain exists locally, verifying the device certificate and the application certificate according to an authentication public key of the authentication certificate in the certificate chain;
    当设备证书和应用证书均验证通过时,反馈表示验证通过的验证结果。When both the device certificate and the application certificate pass, the feedback indicates the verification result that the verification passes.
  22. 根据权利要求21所述的计算机设备,其特征在于,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:The computer device according to claim 21, wherein when the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    在吊销认证证书列表中查询所述证书链中的认证证书;Query the certificate in the certificate chain in the list of revoked certificates;
    当所述证书链中的认证证书不存在于所述吊销认证证书列表中时,在本地查询与所述证书链中的认证证书一致的认证证书;When the authentication certificate in the certificate chain does not exist in the list of revoked authentication certificates, query locally for an authentication certificate that is consistent with the authentication certificate in the certificate chain;
    当查询到与所述证书链中的认证证书一致的认证证书时,根据所述证书链中的认证证书的认证公钥验证所述设备证书;When an authentication certificate identical to the authentication certificate in the certificate chain is found, verifying the device certificate according to the authentication public key of the authentication certificate in the certificate chain;
    当所述设备证书验证通过时,根据所述设备证书的设备公钥验证所述应用证书。When the device certificate verification is passed, the application certificate is verified according to a device public key of the device certificate.
  23. 根据权利要求21所述的计算机设备,其特征在于,所述计算机程序被所述处理器执行时,使得所述处理器执行如下操作:The computer device according to claim 21, wherein when the computer program is executed by the processor, the processor causes the processor to perform the following operations:
    接收设备参数和设备公钥;Receive equipment parameters and equipment public key;
    获取所述设备参数和所述设备公钥的摘要信息;Obtaining the device parameters and summary information of the device public key;
    通过认证私钥加密所述摘要信息得到签名数据;Encrypting the digest information by authenticating the private key to obtain signature data;
    根据加密得到的所述签名数据生成所述设备证书并反馈。Generate the device certificate according to the encrypted signature data and feed it back.
PCT/CN2019/083875 2018-06-06 2019-04-23 Method, apparatus and system for key management, storage medium, and computer device WO2019233204A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2020546477A JP7297360B2 (en) 2018-06-06 2019-04-23 Key management method, device, system, computer equipment and computer program
US16/926,317 US11516020B2 (en) 2018-06-06 2020-07-10 Key management method, apparatus, and system, storage medium, and computer device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810574128.7A CN108768664B (en) 2018-06-06 2018-06-06 Key management method, device, system, storage medium and computer equipment
CN201810574128.7 2018-06-06

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US16/926,317 Continuation US11516020B2 (en) 2018-06-06 2020-07-10 Key management method, apparatus, and system, storage medium, and computer device

Publications (1)

Publication Number Publication Date
WO2019233204A1 true WO2019233204A1 (en) 2019-12-12

Family

ID=63999191

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/083875 WO2019233204A1 (en) 2018-06-06 2019-04-23 Method, apparatus and system for key management, storage medium, and computer device

Country Status (4)

Country Link
US (1) US11516020B2 (en)
JP (1) JP7297360B2 (en)
CN (1) CN108768664B (en)
WO (1) WO2019233204A1 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112836238A (en) * 2021-02-18 2021-05-25 支付宝(杭州)信息技术有限公司 Verification method, device, equipment and system based on privacy protection
CN113055182A (en) * 2021-03-15 2021-06-29 中国工商银行股份有限公司 Authentication method and system, terminal, server, computer system, and medium
CN114499891A (en) * 2022-03-21 2022-05-13 宁夏凯信特信息科技有限公司 Signature server system and signature verification method
JP2022533871A (en) * 2020-04-23 2022-07-27 グーグル エルエルシー Privacy preserving application and device error detection
CN115379450A (en) * 2022-07-25 2022-11-22 中国第一汽车股份有限公司 Data processing method and device and electronic equipment

Families Citing this family (27)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108768664B (en) * 2018-06-06 2020-11-03 腾讯科技(深圳)有限公司 Key management method, device, system, storage medium and computer equipment
CN109508562B (en) * 2018-11-30 2022-03-25 四川长虹电器股份有限公司 TEE-based trusted remote verification method
KR102263877B1 (en) * 2018-12-18 2021-06-14 시큐리티플랫폼 주식회사 Unique encryption key generator for device and method thereof
EP3674934A1 (en) * 2018-12-26 2020-07-01 Thales Dis France SA Biometric acquisition system and method
CN110348204B (en) * 2019-06-17 2023-05-16 海光信息技术股份有限公司 Code protection system, authentication method, authentication device, chip and electronic equipment
CN112118211A (en) * 2019-06-20 2020-12-22 北京京东尚科信息技术有限公司 Device communication method, device, system, medium, and electronic device
CN111193748B (en) * 2020-01-06 2021-12-03 惠州市德赛西威汽车电子股份有限公司 Interactive key security authentication method and system
CN111401901B (en) * 2020-03-23 2021-06-04 腾讯科技(深圳)有限公司 Authentication method and device of biological payment device, computer device and storage medium
CN113472720B (en) * 2020-03-31 2024-02-06 山东云海安全认证服务有限公司 Digital certificate key processing method, device, terminal equipment and storage medium
SG10202003630VA (en) * 2020-04-21 2021-09-29 Grabtaxi Holdings Pte Ltd Authentication and validation procedure for improved security in communications systems
CN111414638B (en) * 2020-04-23 2023-03-24 飞天诚信科技股份有限公司 Method and device for realizing distinguishing key generation mode
EP3923612A1 (en) * 2020-06-09 2021-12-15 Deutsche Telekom AG Method and communication system for ensuring secure communication in a zero touch connectivity-environment
US11595218B2 (en) * 2020-06-23 2023-02-28 Arm Limited Authorization delegation
CN111770199B (en) * 2020-08-31 2020-12-08 支付宝(杭州)信息技术有限公司 Information sharing method, device and equipment
CN111814132B (en) * 2020-09-14 2021-08-03 浙江地芯引力科技有限公司 Security authentication method and device, security authentication chip and storage medium
CN114362951B (en) * 2020-10-13 2024-05-17 花瓣云科技有限公司 Method and device for updating certificates
US11246032B1 (en) * 2020-10-29 2022-02-08 Motional Ad Llc Device provisioning and authentication
EP4002756B1 (en) * 2020-11-24 2022-11-02 Axis AB Systems and methods of managing a certificate associated with a component located at a remote location
CN113034096B (en) * 2021-02-03 2022-09-06 浙江富安莱科技有限公司 Intelligent research and development and production information system
CN115460083B (en) * 2021-06-09 2024-04-19 贵州白山云科技股份有限公司 Security acceleration service deployment method, device, medium and equipment
CN114257382B (en) * 2022-01-30 2024-06-11 支付宝(杭州)信息技术有限公司 Key management and service processing method, device and system
CN114785514B (en) * 2022-03-23 2023-11-14 国网上海能源互联网研究院有限公司 Method and system for application license authorization of industrial Internet of things terminal
CN115001749B (en) * 2022-05-05 2024-02-09 中科创达软件股份有限公司 Equipment authorization method, device, equipment and medium
CN115276963B (en) * 2022-06-13 2024-06-14 云南电网有限责任公司 Intelligent key-based power grid security management method, system and medium
CN115529181A (en) * 2022-09-28 2022-12-27 中国农业银行股份有限公司 Authentication method, device, equipment and storage medium
US20240144232A1 (en) * 2022-10-28 2024-05-02 Stripe, Inc. Systems and methods for terminal device attestation for contactless payments
CN116506134B (en) * 2023-06-28 2023-09-15 山东海量信息技术研究院 Digital certificate management method, device, equipment, system and readable storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1801029A (en) * 2004-12-31 2006-07-12 联想(北京)有限公司 Method for generating digital certificate and applying the generated digital certificate
CN101777978A (en) * 2008-11-24 2010-07-14 华为终端有限公司 Method and system based on wireless terminal for applying digital certificate and wireless terminal
CN106533691A (en) * 2016-10-18 2017-03-22 北京信安世纪科技有限公司 Method and device for verifying validity of digital certificate
CN107104795A (en) * 2017-04-25 2017-08-29 上海汇尔通信息技术有限公司 Method for implanting, framework and the system of RSA key pair and certificate
CN107392588A (en) * 2017-06-21 2017-11-24 深圳市欧乐在线技术发展有限公司 A kind of payment mechanism and its implementation based on signaling network
CN108768664A (en) * 2018-06-06 2018-11-06 腾讯科技(深圳)有限公司 Key management method, device, system, storage medium and computer equipment

Family Cites Families (52)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6233685B1 (en) * 1997-08-29 2001-05-15 Sean William Smith Establishing and employing the provable untampered state of a device
JP4463998B2 (en) 1999-04-09 2010-05-19 マイクロソフト コーポレーション Protected online music distribution system
FI108389B (en) * 1999-04-15 2002-01-15 Sonera Smarttrust Oy Management of subscriber identity modules
DE60115072T3 (en) * 2000-09-21 2010-04-01 Research In Motion Ltd., Waterloo SYSTEM AND METHOD FOR SUBMITING A SOFTWARE CODE
EP1361527A1 (en) * 2002-05-07 2003-11-12 Sony Ericsson Mobile Communications AB Method for loading an application in a device, device and smart card therefor
US20050076198A1 (en) * 2003-10-02 2005-04-07 Apacheta Corporation Authentication system
JP4692922B2 (en) * 2005-03-16 2011-06-01 日本電気株式会社 Local terminal, remote terminal, application access control system, operation method thereof, and operation program
EP1732263A1 (en) * 2005-06-07 2006-12-13 Sony Ericsson Mobile Communications AB Method and apparatus for certificate roll-over
KR100736091B1 (en) * 2005-12-09 2007-07-06 삼성전자주식회사 Apparatus and method for managing a plurality of certificates
US8140843B2 (en) * 2006-07-07 2012-03-20 Sandisk Technologies Inc. Content control method using certificate chains
JP2009543208A (en) * 2006-07-07 2009-12-03 サンディスク コーポレイション Content management system and method using certificate chain
CN101512535B (en) * 2006-08-31 2011-05-18 国际商业机器公司 Attestation of computing platforms
US8064605B2 (en) * 2007-09-27 2011-11-22 Intel Corporation Methods and apparatus for providing upgradeable key bindings for trusted platform modules
US8369526B2 (en) * 2008-02-12 2013-02-05 Discretix Technologies Ltd. Device, system, and method of securely executing applications
EP2340633B1 (en) * 2008-10-22 2018-09-26 BlackBerry Limited Pushing certificate chains to remote devices
JP2011151679A (en) * 2010-01-22 2011-08-04 Ricoh Co Ltd Electronic device
WO2012170130A1 (en) * 2011-06-10 2012-12-13 Certicom (U.S.) Limited Implicitly certified public keys
JP2013150179A (en) * 2012-01-19 2013-08-01 Sony Corp Information processing apparatus, information storage device, information processing system, information processing method, and program
US9083531B2 (en) * 2012-10-16 2015-07-14 Symantec Corporation Performing client authentication using certificate store on mobile device
CN103916848B (en) * 2013-01-09 2019-06-14 中兴通讯股份有限公司 A kind of method and system of mobile terminal data backup and recovery
CN103945374A (en) * 2013-01-18 2014-07-23 深圳市华营数字商业有限公司 Method of mobile terminal equipment and user authentication based on PKI technology
JP6079394B2 (en) 2013-04-11 2017-02-15 富士通株式会社 Certificate generation method, certificate generation apparatus, information processing apparatus, communication device, and program
WO2015108410A1 (en) * 2014-01-15 2015-07-23 Xorkey B.V. Secure login without passwords
CN105743855B (en) * 2014-12-10 2019-05-21 广东华大互联网股份有限公司 A kind of safety control system of Internet application equipment and its distribution, application method
JP6403583B2 (en) * 2015-01-21 2018-10-10 キヤノン株式会社 Distribution management server and distribution management method for distributing updated applications
CN106209730B (en) * 2015-04-30 2020-03-10 华为技术有限公司 Method and device for managing application identifier
US9503449B1 (en) * 2015-05-12 2016-11-22 Payoda Inc. Application centric centralized certificate management system for managing certificates across data centers
US10164963B2 (en) * 2015-10-23 2018-12-25 Oracle International Corporation Enforcing server authentication based on a hardware token
US9882894B2 (en) * 2015-12-15 2018-01-30 Verizon Patent And Licensing Inc. Secure authentication service
CN105704123B (en) * 2016-01-08 2017-09-15 腾讯科技(深圳)有限公司 A kind of methods, devices and systems for carrying out business processing
KR102444239B1 (en) * 2016-01-21 2022-09-16 삼성전자주식회사 Security Chip, Application Processor, Device including security Chip and Operating Method thereof
KR101821645B1 (en) * 2016-02-17 2018-01-25 중부대학교 산학협력단 Key management method using self-extended certification
JP2017175226A (en) * 2016-03-18 2017-09-28 株式会社インテック Program, method and system for issuing public key certificate
CN106096962A (en) * 2016-06-12 2016-11-09 财付通支付科技有限公司 Electronic certificate processing method and electronic certificate processing means
US10320571B2 (en) * 2016-09-23 2019-06-11 Microsoft Technology Licensing, Llc Techniques for authenticating devices using a trusted platform module device
US10437985B2 (en) * 2016-10-01 2019-10-08 Intel Corporation Using a second device to enroll a secure application enclave
CN108476226B (en) * 2016-12-22 2021-06-22 华为技术有限公司 Application program authorization method, terminal and server
KR101816653B1 (en) * 2017-02-14 2018-02-21 주식회사 코인플러그 Method for providing login flow via authentication based on public key infrastructure in response to user’s login request for using service provided by service provider server in use of smart contract with blockchain database and server using the same
CN108667609B (en) * 2017-04-01 2021-07-20 西安西电捷通无线网络通信股份有限公司 Digital certificate management method and equipment
CN108667781A (en) * 2017-04-01 2018-10-16 西安西电捷通无线网络通信股份有限公司 A kind of digital certificate management method and equipment
EP3402152B1 (en) * 2017-05-08 2019-10-16 Siemens Aktiengesellschaft System-specific automated certificate management
CN109218263B (en) * 2017-07-04 2021-06-08 斑马智行网络(香港)有限公司 Control method and device
GB2566263A (en) * 2017-09-01 2019-03-13 Trustonic Ltd Post-manufacture certificate generation
CN109474432B (en) * 2017-09-07 2021-11-02 西安西电捷通无线网络通信股份有限公司 Digital certificate management method and device
US20190109877A1 (en) * 2017-10-11 2019-04-11 Microsoft Technology Licensing, Llc Secure application metering
US10841086B2 (en) * 2018-02-06 2020-11-17 Wickr, Inc. Facilitating communications using hybrid cryptography
CN110278084B (en) * 2018-03-16 2021-10-15 华为技术有限公司 eID establishing method, related device and system
CN108183804B (en) * 2018-03-28 2021-01-26 湖南东方华龙信息科技有限公司 Certificate sharing method
CN110417554A (en) * 2018-04-26 2019-11-05 华为技术有限公司 A kind of method and device for verifying terminal device identity
CN110445614B (en) * 2019-07-05 2021-05-25 创新先进技术有限公司 Certificate application method and device, terminal equipment, gateway equipment and server
US11431502B2 (en) * 2020-09-18 2022-08-30 Citrix Systems, Inc. Enhanced token transfer
US11296933B1 (en) * 2021-03-26 2022-04-05 Sensormatic Electronics, LLC Secure low-latency and low-throughput support of rest API in IoT devices

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1801029A (en) * 2004-12-31 2006-07-12 联想(北京)有限公司 Method for generating digital certificate and applying the generated digital certificate
CN101777978A (en) * 2008-11-24 2010-07-14 华为终端有限公司 Method and system based on wireless terminal for applying digital certificate and wireless terminal
CN106533691A (en) * 2016-10-18 2017-03-22 北京信安世纪科技有限公司 Method and device for verifying validity of digital certificate
CN107104795A (en) * 2017-04-25 2017-08-29 上海汇尔通信息技术有限公司 Method for implanting, framework and the system of RSA key pair and certificate
CN107392588A (en) * 2017-06-21 2017-11-24 深圳市欧乐在线技术发展有限公司 A kind of payment mechanism and its implementation based on signaling network
CN108768664A (en) * 2018-06-06 2018-11-06 腾讯科技(深圳)有限公司 Key management method, device, system, storage medium and computer equipment

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2022533871A (en) * 2020-04-23 2022-07-27 グーグル エルエルシー Privacy preserving application and device error detection
JP7135210B2 (en) 2020-04-23 2022-09-12 グーグル エルエルシー Privacy preserving applications and device error detection
US11928237B2 (en) 2020-04-23 2024-03-12 Google Llc Privacy preserving application and device error detection
CN112836238A (en) * 2021-02-18 2021-05-25 支付宝(杭州)信息技术有限公司 Verification method, device, equipment and system based on privacy protection
CN112836238B (en) * 2021-02-18 2023-10-27 支付宝(杭州)信息技术有限公司 Verification method, device, equipment and system based on privacy protection
CN113055182A (en) * 2021-03-15 2021-06-29 中国工商银行股份有限公司 Authentication method and system, terminal, server, computer system, and medium
CN113055182B (en) * 2021-03-15 2022-11-08 中国工商银行股份有限公司 Authentication method and system, terminal, server, computer system, and medium
CN114499891A (en) * 2022-03-21 2022-05-13 宁夏凯信特信息科技有限公司 Signature server system and signature verification method
CN114499891B (en) * 2022-03-21 2024-05-31 宁夏凯信特信息科技有限公司 Signature server system and signature verification method
CN115379450A (en) * 2022-07-25 2022-11-22 中国第一汽车股份有限公司 Data processing method and device and electronic equipment

Also Published As

Publication number Publication date
CN108768664B (en) 2020-11-03
JP7297360B2 (en) 2023-06-26
US11516020B2 (en) 2022-11-29
JP2021516495A (en) 2021-07-01
US20200344072A1 (en) 2020-10-29
CN108768664A (en) 2018-11-06

Similar Documents

Publication Publication Date Title
WO2019233204A1 (en) Method, apparatus and system for key management, storage medium, and computer device
US11757662B2 (en) Confidential authentication and provisioning
US11356280B2 (en) Personal device security using cryptocurrency wallets
US20210367795A1 (en) Identity-Linked Authentication Through A User Certificate System
US10652015B2 (en) Confidential communication management
US9847880B2 (en) Techniques for ensuring authentication and integrity of communications
US20210319132A1 (en) Methods and Devices For Managing User Identity Authentication Data
US20190173873A1 (en) Identity verification document request handling utilizing a user certificate system and user identity document repository
WO2017020452A1 (en) Authentication method and authentication system
EP2954639A1 (en) Method and apparatus for embedding secret information in digital certificates
CN114172747B (en) Method and system for group members to obtain authentication certificate based on digital certificate
CN112583588B (en) Communication method and device and readable storage medium
CN115242471A (en) Information transmission method and device, electronic equipment and computer readable storage medium
CN110401535B (en) Digital certificate generation, secure communication and identity authentication method and device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19814448

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2020546477

Country of ref document: JP

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19814448

Country of ref document: EP

Kind code of ref document: A1