Trusted computing environment management system and method based on openstack platform

By introducing a trusted computing environment management system on the OpenStack platform that includes remote authentication, encrypted communication, and encrypted data disks, the problem of decreased virtual machine security in virtualized environments is solved, and higher data and key security is achieved.

CN119670100BActive Publication Date: 2025-11-11CHINA UNITED NETWORK COMM GRP CO LTD +2
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411814908.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-10
Publication Date
2025-11-11
Estimated Expiration
2044-12-10

AI Technical Summary

Technical Problem

In existing technologies, trusted computing suffers from reduced security in virtualized environments, especially during multi-party data interaction, which makes it vulnerable to attacks and leads to a decline in the security of trusted computing in virtual machines.

Method used

A trusted computing environment management system based on the OpenStack platform is adopted, including a remote verification unit, a communication security unit, a data security unit, and a key management unit. It improves the security of virtual machines by remotely verifying the trustworthiness of virtual machines, establishing encrypted communication, creating encrypted disks, and managing and backing up keys.

Benefits of technology

By using remote authentication, encrypted communication, and encrypted data disks, the security of trusted computing in virtual machines is enhanced, ensuring the security of data transmission and storage, and improving the security of key management and backup.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119670100B_ABST
    Figure CN119670100B_ABST
Patent Text Reader

Abstract

The embodiment of the application provides a kind of based on Openstack platform's trusted computing environment management system and method, it is related to cloud computing field, the trusted computing environment management system based on OpenStack platform in the application includes: remote certification, communication security, data security and key management. Whether virtual machine is trusted by vtpm local authentication, realizes remote certification, improves the security of virtual machine operating environment. By establishing the two-way identity authentication between server and client, the communication security of data surface is realized according to the communication channel of shared key encryption. The security of disk data encryption is improved by the security mode of tpm hardware protection encryption key. By introducing key management and key backup, the security of key is improved. According to the above system and method, virtual machine is run in reliable environment, and the security of trusted computing is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of cloud computing technology, and in particular to a trusted computing environment management system and method based on the OpenStack platform. Background Technology

[0002] Trusted computing is a more secure computing technology that provides additional protection and security guarantees during data processing and storage. Virtualization technology is a technique that uses software or hardware to create multiple logical computing environments on physical computing resources. It can divide a physical computer into multiple virtual computing environments, each of which can run an operating system and applications independently. Introducing trusted computing technology into a virtualization environment can build a more secure and reliable virtualization platform.

[0003] In existing technologies, trusted computing technology uses special hardware or hardware extensions to create a trusted execution environment. In a trusted execution environment, the code and data running on the virtual machine are not easily tampered with or stolen by viruses or attackers.

[0004] However, in existing technologies, trusted computing involves multiple complex components and protocols, which are vulnerable to attacks during multi-party data interaction, leading to reduced security of trusted computing performed by virtual machines. Summary of the Invention

[0005] This application provides a trusted computing environment management system and method based on the OpenStack platform, which aims to improve the security of trusted computing performed by virtual machines.

[0006] In a first aspect, embodiments of this application provide a trusted computing environment management system based on the OpenStack platform, including: a remote authentication unit, a communication security unit, a data security unit, and a key management unit;

[0007] The remote verification unit is used to remotely verify whether the virtual machine is trustworthy; the communication security unit is used to establish encrypted communication between the client and the server; the data security unit is used to create an encrypted disk; and the key management unit is used to manage and back up keys in the trusted computing environment.

[0008] The steps for the remote verification unit to verify whether the virtual machine is trustworthy include:

[0009] The nova-api component sends a remote certification request to the CA certification center;

[0010] The CA certification center obtains the PCR list from the virtual machine during registration and generates a random number;

[0011] The CA certification center sends the PCR list and the random number to the nova-api component;

[0012] The nova-api component generates a remote authentication request based on the PCR manifest and the random number, and sends the remote authentication request to the virtual machine;

[0013] The virtual machine invokes the virtual machine's remote authentication service to parse the remote authentication request and generate a remote authentication report for the virtual machine.

[0014] The virtual machine sends the remote proof report to the nova-compute component;

[0015] The nova-compute component calls the remote proof service of the host machine to obtain the remote proof report of the host machine, merges the remote proof report of the virtual machine and the remote proof report of the host machine to generate a remote proof report, and sends the remote proof report to the CA certification center;

[0016] The CA certification center verifies the remote proof report, generates a remote verification result, and sends the remote verification result to the nova-compute component;

[0017] The nova-compute component saves the remote verification results to the database to enable remote authentication of the virtual machine.

[0018] In one possible implementation, the virtual machine invokes the virtual machine's remote proof service to parse the remote authentication request and generate a remote proof report for the virtual machine, including: the virtual machine obtaining the private key from the asymmetric key pair; invoking the virtual machine's remote proof service to parse the remote authentication request and obtain the random number and PCR list from the remote authentication request; encrypting the random number and the PCR list using the private key from the asymmetric key pair to generate a remote proof report for the virtual machine.

[0019] In one possible implementation, the step of establishing encrypted communication between the client and the server by the communication security unit includes: a CA key center creating a CA root key and creating a CA root certificate based on the CA root key; the CA key center sending the CA root certificate to the server and the client; the server creating a server key pair and creating a server certificate request based on the server key pair, wherein the server key pair includes a server private key and a server public key; the server signing the server certificate request based on the server private key and the CA root certificate to generate a server certificate, wherein the server certificate includes information about the server public key; and the client creating a client key pair and creating a client certificate request based on the client key pair, wherein the client key pair includes information about the client private key. The client and the server jointly establish a mutual authentication relationship (PER). The client sends the client certificate to the server. The server sends the server certificate to the client to establish a mutual authentication relationship (PER). If the mutual authentication is successful, the server generates a first shared key pair based on the server's private key and the client's public key. The client generates a second shared key pair based on the client's private key and the server's public key. If the first and second shared key pairs are identical, the server and the client communicate encrypted using the shared keys.

[0020] In one possible implementation, the step of the data security unit creating an encrypted disk includes: the tpm module creating a master key and generating a subkey based on the master key; the tpm module generating a key value required for Luks encryption and decryption, and encapsulating the key value into the subkey; the tpm module persisting the subkey encapsulating the key value to a register address of the tpm module; the Luks encryption block obtaining the subkey from the register address via a decryption instruction; the Luks encryption block decrypting and obtaining the key value required for Luks encryption and decryption from the subkey, and generating a Luks encryption key pair based on the key value; the Luks encryption block generating a context based on the encryption key pair, and encrypting the storage disk using the context to obtain the encrypted disk.

[0021] In one possible implementation, the key management unit is used to manage and back up keys in a trusted computing environment; the step of backing up keys in the trusted computing environment includes: a backup virtual machine creating a backup master key and sending the backup master key to a service virtual machine; the service virtual machine creating a service master key and encrypting service files according to the service master key; the service virtual machine creating and running a backup command, importing the backup master key according to the backup command, and generating a backup key pair according to the backup master key and the service master key; when the service virtual machine fails, the backup virtual machine imports the backup key pair and decrypts the service files according to the backup key pair.

[0022] Secondly, embodiments of this application provide a trusted computing environment management method based on the OpenStack platform, applied to a trusted computing environment management system, which includes: a remote authentication unit, a communication security unit, a data security unit, and a key management unit;

[0023] The remote verification unit is used to remotely verify whether the virtual machine is trustworthy; the communication security unit is used to establish encrypted communication between the client and the server; the data security unit is used to create an encrypted disk; and the key management unit is used to manage and back up keys in the trusted computing environment.

[0024] The steps for the remote verification unit to verify whether the virtual machine is trustworthy include:

[0025] The nova-api component sends a remote certification request to the CA certification center;

[0026] The CA certification center obtains the PCR list from the virtual machine during registration and generates a random number;

[0027] The CA certification center sends the PCR list and the random number to the nova-api component;

[0028] The nova-api component generates a remote authentication request based on the PCR manifest and the random number, and sends the remote authentication request to the virtual machine;

[0029] The virtual machine invokes the virtual machine's remote authentication service to parse the remote authentication request and generate a remote authentication report for the virtual machine.

[0030] The virtual machine sends the remote proof report to the nova-compute component;

[0031] The nova-compute component calls the remote proof service of the host machine to obtain the remote proof report of the host machine, merges the remote proof report of the virtual machine and the remote proof report of the host machine to generate a remote proof report, and sends the remote proof report to the CA certification center;

[0032] The CA certification center verifies the remote proof report, generates a remote verification result, and sends the remote verification result to the nova-compute component;

[0033] The nova-compute component saves the remote verification results to the database to enable remote authentication of the virtual machine.

[0034] In one possible implementation, the virtual machine invokes the virtual machine's remote proof service to parse the remote authentication request and generate a remote proof report for the virtual machine, including: the virtual machine obtaining the private key from the asymmetric key pair; invoking the virtual machine's remote proof service to parse the remote authentication request and obtain the random number and PCR list from the remote authentication request; encrypting the random number and the PCR list using the private key from the asymmetric key pair to generate a remote proof report for the virtual machine.

[0035] In one possible implementation, the step of establishing encrypted communication between the client and the server by the communication security unit includes: a CA key center creating a CA root key and creating a CA root certificate based on the CA root key; the CA key center sending the CA root certificate to the server and the client; the server creating a server key pair and creating a server certificate request based on the server key pair, wherein the server key pair includes a server private key and a server public key; the server signing the server certificate request based on the server private key and the CA root certificate to generate a server certificate, wherein the server certificate includes information about the server public key; and the client creating a client key pair and creating a client certificate request based on the client key pair, wherein the client key pair includes information about the client private key. The client and the server jointly establish a mutual authentication relationship (PER). The client sends the client certificate to the server. The server sends the server certificate to the client to establish a mutual authentication relationship (PER). If the mutual authentication is successful, the server generates a first shared key pair based on the server's private key and the client's public key. The client generates a second shared key pair based on the client's private key and the server's public key. If the first and second shared key pairs are identical, the server and the client communicate encrypted using the shared keys.

[0036] In one possible implementation, the step of the data security unit creating an encrypted disk includes: the tpm module creating a master key and generating a subkey based on the master key; the tpm module generating a key value required for Luks encryption and decryption, and encapsulating the key value into the subkey; the tpm module persisting the subkey encapsulating the key value to a register address of the tpm module; the Luks encryption block obtaining the subkey from the register address via a decryption instruction; the Luks encryption block decrypting and obtaining the key value required for Luks encryption and decryption from the subkey, and generating a Luks encryption key pair based on the key value; the Luks encryption block generating a context based on the encryption key pair, and encrypting the storage disk using the context to obtain the encrypted disk.

[0037] In one possible implementation, the key management unit is used to manage and back up keys in a trusted computing environment; the step of backing up keys in the trusted computing environment includes: a backup virtual machine creating a backup master key and sending the backup master key to a service virtual machine; the service virtual machine creating a service master key and encrypting service files according to the service master key; the service virtual machine creating and running a backup command, importing the backup master key according to the backup command, and generating a backup key pair according to the backup master key and the service master key; when the service virtual machine fails, the backup virtual machine imports the backup key pair and decrypts the service files according to the backup key pair.

[0038] The trusted computing environment management system and method based on the OpenStack platform provided in this application compares the current virtual machine's PCR value with the virtual machine's PCR value stored by a CA certification center to determine whether the virtual machine is trustworthy and secure, thus achieving remote authentication. Communication security is achieved by establishing encrypted communication between the server and client. Data security is improved by encrypting the virtual machine's disk, both local and shared disks. Key security is enhanced by introducing key management and key backup. These four components ensure that the virtual machine runs in a reliable environment, improving the security of trusted computing. Attached Figure Description

[0039] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0040] Figure 1 A schematic diagram illustrating the scenario created for the trusted computing environment provided in the embodiments of this application;

[0041] Figure 2 A schematic diagram illustrating the establishment of encrypted communication by the communication security unit provided in the embodiments of this application;

[0042] Figure 3 A schematic diagram illustrating the creation of an encrypted disk for the data security unit provided in the embodiments of this application;

[0043] Figure 4 A schematic diagram illustrating key management backup performed by the key management unit provided in this application embodiment;

[0044] Figure 5 This is a schematic diagram of the remote proof process in the trusted computing environment management method provided in the embodiments of this application.

[0045] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0046] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0047] First, let me explain the terms used in this application:

[0048] The nova-api component is part of the OpenStack Nova service and is primarily responsible for providing RESTful API interfaces. These API interfaces act as a bridge for communication between clients and the Nova service, enabling users to manage and manipulate computing resources in the cloud environment via HTTP requests. nova-api receives requests from clients, forwards them to other components within the Nova service for processing, and finally returns the results to the client.

[0049] The nova-compute component is one of the core components of the OpenStack Nova service. It runs on compute nodes and is responsible for creating, terminating, and managing virtual machine instances. Through nova-compute, users can perform operations such as starting, shutting down, migrating, and taking snapshots of virtual machine instances.

[0050] pcr: pcr is an important component in the Java Virtual Machine, used to store the address of the bytecode instruction that the current thread is executing.

[0051] Trusted computing is a more secure computing technology that provides additional protection and security guarantees during data processing and storage. Virtualization technology is a technique that creates multiple logical computing environments on physical computing resources through software or hardware. It can divide a physical computer into multiple virtual computing environments, each of which can independently run an operating system and applications. Introducing trusted computing technology into virtualization environments can build a more secure and reliable virtualization platform. In existing technologies, trusted computing technology uses special hardware or hardware extensions to create a trusted execution environment. Virtual machines running code and data in a trusted execution environment are less susceptible to tampering or data theft by viruses or attackers. However, existing trusted computing technologies involve multiple complex components and protocols, making them vulnerable to attacks during multi-party data interactions, thus reducing the security of trusted computing performed by virtual machines.

[0052] To address the aforementioned technical problems, this application proposes the following technical concept: The inventors considered creating a trusted computing environment management system based on the OpenStack platform, including: a remote authentication unit, a communication security unit, a data security unit, and a key management unit. Remote authentication is achieved by comparing the current virtual machine's PCR value with the virtual machine's PCR value stored by the CA certification center to determine whether the virtual machine is trustworthy and secure. Communication security is achieved by establishing encrypted communication between the server and client. Data security is improved by encrypting the virtual machine's disk, both local and shared. Key security is improved by introducing key management and key backup. These four components enable the virtual machine to run in a reliable environment, improving the security of trusted computing compared to existing technologies. Detailed embodiments are described below.

[0053] Figure 1 A schematic diagram of the structure of the trusted computing environment management system based on the OpenStack platform provided in the embodiments of this application is shown below. Figure 1 As shown, the trusted computing environment management system includes: a remote verification unit 10, a communication security unit 20, a data security unit 30, a key management unit 40, a virtual machine 50, and a nova component 60.

[0054] Among them, nova component 60 includes, but is not limited to, nova-api component, nova-compute component and other nova components.

[0055] The nova-api component sends a remote certification request to a CA (Certificate Authority).

[0056] In this embodiment, when the virtual machine is running, the CA-agent service calls the tpm-tool to export the remote verification report of the virtual machine, sends the remote verification report to the CA certification center, and compares it with the baseline remote verification report of the virtual machine at the time of registration stored in the CA certification center. If they are the same, the virtual machine is considered to be running trustworthy.

[0057] The CA certification center obtains the PCR list from the virtual machine during registration and generates a random number.

[0058] In this embodiment, the random number generated by the CA certification center is denoted as nonce.

[0059] In this embodiment, the generated random number corresponds to the remote proof request sent by the nova-api component. A different corresponding random number is generated for each remote proof request sent.

[0060] The CA certification center sends a PCR list and a random number to the nova-api component.

[0061] Specifically, the CA certification center sends the PCR list and random number to the nova-api component via wireless communication.

[0062] The nova-api component generates a remote authentication request based on the PCR manifest and a random number, and sends the remote authentication request to the virtual machine.

[0063] Specifically, the nova-api component sends remote authentication requests to the virtual machine via wireless communication.

[0064] In this embodiment, the remote authentication request includes a pcr list and a random number.

[0065] The virtual machine calls the virtual machine's remote authentication service to parse the remote authentication request and generate the virtual machine's remote authentication report.

[0066] Specifically, the virtual machine calls the tpm2-tool tool through the tpm-vm-agent service to parse the remote authentication request, obtain the random number, the virtual machine's UUID and PCR list, and encrypt the random number and PCR list with the public key in the asymmetric key pair to generate the virtual machine's remote authentication report.

[0067] The virtual machine sends a remote proof report to the nova-compute component.

[0068] The nova-compute component calls the host machine's remote proof service to obtain the host machine's remote proof report, merges the virtual machine's remote proof report and the host machine's remote proof report to generate a new remote proof report, and sends the remote proof report to the CA certification center.

[0069] Specifically, the nova-compute component calls the tpm-host-agent service to obtain the remote authentication report from the host machine.

[0070] The CA certification center verifies the remote certification report, generates a remote verification result, and sends the remote verification result to the nova-compute component.

[0071] Specifically, the CA certification center receives the remote verification report sent by the nova-compute component via wireless communication, obtains the public key from the asymmetric key pair generated by the endorsement key, decrypts the remote verification report, obtains the virtual machine UUID, random number nonce, and PCR list from the report, and calls the tpm2-tool to verify whether the nonce value and PCR list value are consistent with the stored values. If they are the same, it proves that the virtual machine is a trusted virtual machine and generates a remote verification result.

[0072] The CA certification center verifies the remote certification report, generates a remote verification result, and sends the remote verification result to the nova-compute component.

[0073] The nova-compute component saves remote verification results to a database to enable remote verification of virtual machines.

[0074] Furthermore, it should be noted that the CA certification center primarily compares the exported remote certification report with the baseline certification report to achieve remote certification of virtual machines. Based on the above business process, the public key, signature information, signature file, and random number (nonce) of the virtual machine remote certification report need to be persisted. Specifically, two layers of encryption are implemented: the disk is encrypted using Luks to encrypt the data written to disk; the baseline report files (public key, signature information, signature file, random number (nonce), and file) of all remotely certified virtual machines are encrypted and decrypted using OpenSSL, with the key encrypt_passwd stored in the TPM register. Each time the baseline report files of different virtual machines need to be encrypted and decrypted, the OpenSSL key is first exported from the VTPM, and then the file is encrypted and decrypted.

[0075] In addition, it should be noted that the key for a single virtual machine needs to be destroyed. Locate the corresponding encrypted file stored by the virtual machine and then manually delete it. Also, the encryption key files for multiple virtual machines, as well as the ncrypt_passwd of openssl stored in vtpm, need to be destroyed.

[0076] As can be seen from the above embodiments, remote authentication is achieved by comparing the current virtual machine's PCR value with the virtual machine's PCR value stored by the CA certification center to determine whether the virtual machine is trustworthy and secure. Communication security is achieved by establishing encrypted communication between the server and client. Data security is improved by encrypting the virtual machine's disk, both local and shared, and by introducing key management and key backup. These four aspects ensure that the virtual machine runs in a reliable environment, thus improving the security of trusted computing.

[0077] In one embodiment of this application, the virtual machine invokes the virtual machine's remote authentication service to parse the remote authentication request and generate a remote authentication report for the virtual machine, including:

[0078] The virtual machine retrieves the private key from the asymmetric key pair.

[0079] In this embodiment, the private key in the asymmetric key pair is generated from the endorsement key.

[0080] In this embodiment, the private key in the asymmetric key pair is generated by the virtual machine device during the registration process and stored in a fixed path within the virtual machine.

[0081] The virtual machine's remote authentication service is invoked to parse the remote authentication request and obtain the random number and PCR list from the remote authentication request.

[0082] In this embodiment, the random number is generated by the CA certification center after receiving the remote verification request.

[0083] Specifically, the tpm-vm-agent remote authentication service of the virtual machine is invoked, and the tpm2-tool command is invoked to parse the remote authentication request and obtain the random number nonce, the virtual machine's UUID, and the PCR list from the remote authentication request.

[0084] In this embodiment, the firmware state stored in the virtual machine's TPM has 24 lines, or 24 banks. The first 10 lines store the hash value of the firmware state. The values ​​of the 10 defined banks are extracted to generate the PCR manifest.

[0085] A remote proof report for the virtual machine is generated by encrypting random numbers and a PCR manifest using the private key in the asymmetric key pair.

[0086] Specifically, the random number, the virtual machine's UUID, and the PCR manifest are signed and encrypted using the private key in the asymmetric key pair, and a remote proof report for generating the virtual machine is exported.

[0087] As can be seen from the above embodiments, by obtaining the private key from the asymmetric key pair, encrypting random numbers and PCR lists with the private key, generating a remote proof report, and transmitting the remote proof report to the nova-compute component, the security of the data is improved.

[0088] In one embodiment of this application, the step of establishing encrypted communication between the client and the server by the communication security unit includes:

[0089] The CA key center creates the CA root key and then creates the CA root certificate based on the CA root key.

[0090] In this embodiment, the CA root certificate (ca-cert.pem) is created and signed using the CA root key (ca-key.pem).

[0091] The CA root key is created at the CA key center.

[0092] The CA key center sends the CA root certificate to both the server and the client.

[0093] Specifically, the CA root certificate is sent to the server and client via wireless communication.

[0094] The server creates a server key pair and then creates a server certificate request based on the server key pair, which includes the server private key and the server public key.

[0095] In this embodiment, the server creates a server key pair (server-key.pem) and uses the server key to create a server certificate request (server-csr.pem).

[0096] In this embodiment, the public and private keys in the server key pair are asymmetric keys.

[0097] The server signs the server certificate request based on the server's private key and the CA root certificate, and generates a server certificate, which includes information about the server's public key.

[0098] In this embodiment, the server uses the CA root certificate and the server's private key to sign the server certificate request and generate a server certificate (server-cert.pem).

[0099] The client creates a client key pair and then creates a client certificate request based on the client key pair, which includes the client's private key and client's public key.

[0100] In this embodiment, the client creates a client key pair (client-key.pem) and uses the client key to create a client certificate request (client-csr.pem).

[0101] In this embodiment, the public and private keys in the client key pair are asymmetric keys.

[0102] The client generates a client certificate by signing the client certificate request based on the client's private key and the CA root certificate. The client certificate includes information about the client's public key.

[0103] In this embodiment, the client uses the CA root certificate and the client's private key to sign the client certificate request and generate a client certificate (client-cert.pem).

[0104] The client sends its certificate to the server.

[0105] Specifically, the client certificate is sent to the server via wireless communication.

[0106] The server sends its certificate to the client to establish two-way authentication between the client and the server.

[0107] Specifically, the server certificate is sent to the client via wireless communication.

[0108] If the two-way authentication between the client and the server passes, the server generates the first shared key pair based on the server's private key and the client's public key.

[0109] In this embodiment, the first shared key pair is a symmetric key pair.

[0110] The client generates a second shared key pair based on its private key and the server's public key.

[0111] In this embodiment, the second shared key pair is a symmetric key pair.

[0112] If the first shared key pair and the second shared key pair are the same, the server and the client will communicate encryptedly based on the shared key.

[0113] Specifically, encrypted communication is achieved between the virtual machine and the host machine by encrypting files communicated between them using a shared key.

[0114] Figure 2 A schematic diagram illustrating the establishment of encrypted communication by the communication security unit provided in the embodiments of this application.

[0115] like Figure 2 As shown, the CA key center sends the CA root certificate to the virtual machine and the host machine. The virtual machine and the host machine create a shared key pair by exchanging public keys and encrypt communication using the shared key.

[0116] In addition, it should be noted that when the host machine and the CA certification center communicate, a key pair is created between the CA certification center and the host machine. The CA certification center and the host exchange public keys to create a shared key, which is used to encrypt files during communication.

[0117] Furthermore, it's important to note that when a virtual machine and the host machine, or the host machine and a CA (Certificate Authority) need to communicate encrypted, TLS and two-way authentication using identity keys are added on top of the socket to ensure secure transmission. When both parties require encrypted communication, they first request a key pair from the CA. The CA sends the key pair and a signature file to the requester after signing it. Once the requester receives the signed key pair, they first verify its integrity using the CA root certificate. If it hasn't been altered, they exchange keys via TLS+DH to generate a shared key. If the shared keys of both parties are equal, encrypted communication proceeds. If the encrypted channel connection is broken and the key needs to be destroyed, the key pair can be deleted directly to destroy the key.

[0118] As can be seen from the above embodiments, by creating a CA root certificate server through a CA key center and generating server certificates and client certificates respectively, exchanging public keys with each other through two-way authentication to form a shared key, and using the shared key to encrypt files during communication, the security of communication is improved.

[0119] In one embodiment of this application, the step of creating an encrypted disk by the data security unit includes:

[0120] The tpm module creates a master key and generates subkeys based on the master key.

[0121] Specifically, the tpm module first obtains the endorsement key, creates a master key from the endorsement key, and then generates a subkey based on the master key.

[0122] The tpm module generates the key value required for LUKS encryption and decryption, and encapsulates the key value required for LUKS encryption and decryption into a subkey.

[0123] Specifically, the tpm module uses the generated key value as the encryption key of luks, appending it to the beginning or end of the subkey, or interspersing it in the subkey according to pre-set rules.

[0124] The tpm module persists the subkey that encapsulates the key value required for LUK encryption and decryption to the register address of the tpm module.

[0125] In this embodiment, the register that stores the subkey required for the encapsulation of the key value for LUK encryption and decryption is a non-volatile (nv) register.

[0126] The Luks encryption block retrieves the subkey from the register address using decryption instructions.

[0127] Specifically, the Luks encryption block extracts the subkey stored in the tpm register using the tpm2_unseal command.

[0128] The Luks encryption block is decrypted to obtain the key value required for Luks encryption and decryption from the subkey, and a Luks encryption key pair is generated based on the key value required for Luks encryption and decryption.

[0129] In this embodiment, the Luks encryption key pair is an asymmetric key pair.

[0130] The Luks encryption block generates a context based on the encryption key pair, and then uses the context to encrypt the storage disk, resulting in an encrypted disk.

[0131] Specifically, a context is generated using the public key in the Luks encryption key, the disk is encrypted using the context, and the generated encrypted disk is then formatted and mounted.

[0132] In this embodiment, the transmission data, trusted reports, and trusted computing data of the virtual machine, the host machine, and the CA certification center are stored on an encrypted disk.

[0133] Figure 3 A schematic diagram illustrating the creation of an encrypted disk for the data security unit provided in this application embodiment.

[0134] like Figure 3 As shown, after the virtual machine is created, the raw storage device / dev / vda is discovered using the fdisk command. Data encryption is implemented using tpm and Lusk to ensure that the data written to disk is ciphertext.

[0135] Furthermore, it's worth noting that the virtual machine protects the storage device by encrypting the data written to disk using Luks, thus ensuring the stored data is encrypted. The Luks key is persistently stored in the hardware register space of tpm. When a Luks disk is created, the Luks key is read using the tpm-tool command, and tpm protects the Luks key, thereby improving its security.

[0136] In addition, it should be noted that the key data stored in the NV register of the TPM can be destroyed by exporting the data and then resetting the register address.

[0137] As can be seen from the above embodiments, by storing the LUKS encryption key value in the TPM register, when LUKS encrypts or decrypts the storage logic unit, the key value required to generate the LUKS key is exported from the TPM register, thereby realizing hardware protection of the encryption key. The disk is encrypted using the LUKS key, which improves data security.

[0138] In one embodiment of this application, a key management unit is used to manage and back up keys in a trusted computing environment; the step of backing up keys in the trusted computing environment includes:

[0139] The backup virtual machine creates a backup master key and sends the backup master key to the business virtual machine.

[0140] Figure 4 This is a schematic diagram illustrating the key management backup performed by the key management unit provided in this embodiment of the application.

[0141] In this embodiment, the backup virtual machine is a Vtpm or tpm device in another operating environment.

[0142] Specifically, the backup virtual machine sends the backup master key to the business virtual machine via wireless communication.

[0143] The business virtual machine creates a business master key and encrypts business files based on the business master key.

[0144] Specifically, the virtual machine creates a business master key, which generates an RSA-type asymmetric key pair. The asymmetric key pair is used to encrypt the business.

[0145] The business virtual machine creates and runs a backup command, imports the backup master key according to the backup command, and generates a backup key pair based on the backup master key and the business master key.

[0146] Specifically, create a session that allows backups, run the backup session, import the backup master key, and use the tpm2_duplicate command to generate a backup key pair from the backup master key and the business master key.

[0147] When a business virtual machine fails, the backup virtual machine imports the backup key pair and decrypts the business files based on the backup key pair.

[0148] Specifically, when a business virtual machine fails, the backup virtual machine imports the backup key pair into the backup master key context to generate a decryption context, which is then used to decrypt the encrypted business files of the business virtual machine.

[0149] In this embodiment, the backup master key context is denoted as new_parent.pub, and the decryption context is denoted as dup.ctx.

[0150] In addition, it should be noted that the keys managed by vtpm inside the virtual machine, including the business master key and the RSA type encrypted business key generated by vtpm, can be destroyed by calling the tpm-clear command to delete all key trees under the entire storage key seed or by manually deleting the key file after backing up the virtual machine's key management file.

[0151] As can be seen from the above embodiments, by generating a backup key through the backup virtual machine and sending it to the business virtual machine, and using the business virtual machine to generate a backup key pair, the encrypted files of the business virtual machine can be decrypted through the backup key pair when the business virtual machine fails, thereby improving the security of the key.

[0152] Figure 5 This is a flowchart illustrating the remote verification process in the trusted computing environment management method based on the OpenStack platform provided in this embodiment. The executing entity in this embodiment can be a trusted computing environment management system based on the OpenStack platform. The trusted computing environment management system based on the OpenStack platform includes: a remote verification unit, a communication security unit, a data security unit, and a key management unit. The remote verification unit is used to remotely verify whether the virtual machine is trustworthy; the communication security unit is used to establish encrypted communication between the client and the server; the data security unit is used to create encrypted disks; and the key management unit is used to manage and back up keys in the trusted computing environment. No special limitations are imposed in this embodiment. Figure 5 As shown, the method includes:

[0153] S501: The nova-api component sends a remote authentication request to the CA certification center.

[0154] S502: The CA certification center obtains the PCR list from the virtual machine during registration and generates a random number.

[0155] S503: The CA certification center sends a pcr list and a random number to the nova-api component.

[0156] S504: The nova-api component generates a remote authentication request based on the PCR manifest and a random number, and sends the remote authentication request to the virtual machine.

[0157] S505: The virtual machine calls the virtual machine's remote authentication service to parse the remote authentication request and generate the virtual machine's remote authentication report.

[0158] S506: The virtual machine sends a remote proof report to the nova-compute component.

[0159] S507: The nova-compute component calls the host machine's remote proof service to obtain the host machine's remote proof report, merges the virtual machine's remote proof report and the host machine's remote proof report to generate a remote proof report, and sends the remote proof report to the CA certification center.

[0160] S508: The CA certification center verifies the remote certification report, generates the remote verification result, and sends the remote verification result to the nova-compute component.

[0161] S509: The nova-compute component saves remote verification results to the database to enable remote verification of virtual machines.

[0162] As can be seen from the above embodiments, remote authentication is achieved by comparing the current virtual machine's PCR value with the virtual machine's PCR value stored by the CA certification center to determine whether the virtual machine is trustworthy and secure. Communication security is achieved by establishing encrypted communication between the server and client. Data security is improved by encrypting the virtual machine's disk, both local and shared, and by introducing key management and key backup. These four aspects ensure that the virtual machine runs in a reliable environment, thus improving the security of trusted computing.

[0163] In one embodiment of this application, step S505 includes:

[0164] S5051: The virtual machine retrieves the private key from the asymmetric key pair.

[0165] S5052: Call the virtual machine's remote authentication service to parse the remote authentication request and obtain the random number and PCR list from the remote authentication request.

[0166] S5053: Generate a remote proof report for a virtual machine by encrypting random numbers and a pcr list using the private key in the asymmetric key pair.

[0167] As can be seen from the above embodiments, by obtaining the private key from the asymmetric key pair, encrypting random numbers and PCR lists with the private key, generating a remote proof report, and transmitting the remote proof report to the nova-compute component, the security of the data is improved.

[0168] In one embodiment of this application, the step of establishing encrypted communication between the client and the server by the communication security unit includes:

[0169] S601: The CA Key Center creates a CA root key and a CA root certificate based on the CA root key.

[0170] S602: The CA key center sends the CA root certificate to the server and client.

[0171] S603: The server creates a server key pair and creates a server certificate request based on the server key pair, wherein the server key pair includes the server private key and the server public key.

[0172] S604: The server signs the server certificate request based on the server's private key and the CA root certificate, and generates a server certificate, which includes information about the server's public key.

[0173] S605: The client creates a client key pair and creates a client certificate request based on the client key pair, which includes the client private key and the client public key.

[0174] S606: The client generates a client certificate by signing the client certificate request based on the client's private key and the CA root certificate, wherein the client certificate includes information about the client's public key.

[0175] S607: The client sends its client certificate to the server.

[0176] S608: The server sends its certificate to the client to establish two-way authentication between the client and the server.

[0177] S609: If the two-way authentication between the client and the server passes, the server generates a first shared key pair based on the server's private key and the client's public key.

[0178] S610: The client generates a second shared key pair based on the client's private key and the server's public key.

[0179] S611: If the first shared key pair and the second shared key pair are the same, the server and the client will communicate encrypted based on the shared key.

[0180] As can be seen from the above embodiments, by creating a CA root certificate server through a CA key center and generating server certificates and client certificates respectively, exchanging public keys with each other through two-way authentication to form a shared key, and using the shared key to encrypt files during communication, the security of communication is improved.

[0181] In one embodiment of this application, the data security unit includes a vtpm module and a Luks encryption block; the step of the data security unit creating an encrypted disk includes:

[0182] S7011: The tpm module creates a master key and generates subkeys based on the master key.

[0183] S702: The tpm module generates the key value required for LUKS encryption and decryption, and encapsulates the key value required for LUKS encryption and decryption into a subkey.

[0184] S703: The tpm module persists the subkey that encapsulates the key value required for LUK encryption and decryption to the register address of the tpm module.

[0185] S704: The Luks encryption block obtains the subkey from the register address through a decryption instruction.

[0186] S705: Decrypt the Luks encryption block and obtain the key value required for Luks encryption and decryption from the subkey, and generate a Luks encryption key pair based on the key value required for Luks encryption and decryption.

[0187] S706: The Luks encryption block generates a context based on the encryption key pair, and encrypts the storage disk using the context to obtain the encrypted disk.

[0188] As can be seen from the above embodiments, by storing the LUKS encryption key value in the TPM register, when LUKS encrypts or decrypts the storage logic unit, the key value required to generate the LUKS key is exported from the TPM register, thereby realizing hardware protection of the encryption key. The disk is encrypted using the LUKS key, which improves data security.

[0189] In one embodiment of this application, the key management unit is used to store the service key and generate a backup key for the service key; generating the backup key for the service key includes:

[0190] S801: Backup virtual machine creates backup master key and sends backup master key to business virtual machine.

[0191] S802: The business virtual machine creates a business master key and encrypts business files based on the business master key.

[0192] S803: The business virtual machine creates and runs a backup command, imports the backup master key according to the backup command, and generates a backup key pair based on the backup master key and the business master key.

[0193] S804: When a business virtual machine fails, the backup virtual machine imports the backup key pair and decrypts the business files based on the backup key pair.

[0194] As can be seen from the above embodiments, by generating a backup key through the backup virtual machine and sending it to the business virtual machine, and using the business virtual machine to generate a backup key pair, the encrypted files of the business virtual machine can be decrypted through the backup key pair when the business virtual machine fails, thereby improving the security of the key.

[0195] Finally, it should be noted that other embodiments of the invention will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This invention is intended to cover any variations, uses, or adaptations of the invention that follow the general principles of the invention and include common knowledge or customary techniques in the art not disclosed herein, and is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of the invention is limited only by the appended claims.

Claims

1. A trusted computing environment management system based on the OpenStack platform, characterized in that, include: Remote authentication unit, communication security unit, data security unit, and key management unit; The remote verification unit is used to remotely verify whether the virtual machine is trustworthy; The communication security unit is used to establish encrypted communication between the client and the server; The data security unit is used to create an encrypted disk; The key management unit is used to manage and back up keys in the trusted computing environment; The steps for the remote verification unit to verify whether the virtual machine is trustworthy include: The nova-api component sends a remote certification request to the CA certification center; The CA certification center obtains the PCR list from the virtual machine during registration and generates a random number; The CA certification center sends the PCR list and the random number to the nova-api component; The nova-api component generates a remote authentication request based on the PCR manifest and the random number, and sends the remote authentication request to the virtual machine; The virtual machine invokes the virtual machine's remote authentication service to parse the remote authentication request and generate a remote authentication report for the virtual machine. The virtual machine sends the remote proof report to the nova-compute component; The nova-compute component calls the remote proof service of the host machine to obtain the remote proof report of the host machine, merges the remote proof report of the virtual machine and the remote proof report of the host machine to generate a remote proof report, and sends the remote proof report to the CA certification center; The CA certification center verifies the remote proof report, generates a remote verification result, and sends the remote verification result to the nova-compute component; The nova-compute component saves the remote verification results to the database to enable remote authentication of the virtual machine.

2. The system according to claim 1, characterized in that, The virtual machine invokes the virtual machine's remote authentication service to parse the remote authentication request and generate a virtual machine remote authentication report, including: The virtual machine obtains the private key from the asymmetric key pair; The remote authentication request is parsed by calling the virtual machine's remote authentication service, and the random number and PCR list in the remote authentication request are obtained. The random number and the PCR list are encrypted using the private key in the asymmetric key pair to generate a remote proof report for the virtual machine.

3. The system according to claim 1, characterized in that, The steps for establishing encrypted communication between the client and server by the communication security unit include: The CA key center creates a CA root key and creates a CA root certificate based on the CA root key; The CA key center sends the CA root certificate to the server and the client; The server creates a server key pair and creates a server certificate request based on the server key pair, wherein the server key pair includes a server private key and a server public key; The server signs the server certificate request based on the server private key and the CA root certificate, and generates a server certificate, wherein the server certificate includes information about the server public key; The client creates a client key pair and creates a client certificate request based on the client key pair, wherein the client key pair includes a client private key and a client public key; The client signs the client certificate request based on the client private key and the CA root certificate, and generates a client certificate, wherein the client certificate includes information about the client public key; The client sends the client certificate to the server; The server sends its certificate to the client to establish two-way authentication between the client and the server. If the two-way authentication between the client and the server passes, the server generates a first shared key pair based on the server's private key and the client's public key. The client generates a second shared key pair based on the client's private key and the server's public key; If the first shared key pair and the second shared key pair are the same, then the server and the client communicate encrypted based on the shared key.

4. The system according to claim 1, characterized in that, The steps for creating an encrypted disk using the data security unit include: The tpm module creates a master key and generates subkeys based on the master key; The tpm module generates the key value required for LUKs encryption and decryption, and encapsulates the key value required for LUKs encryption and decryption into the subkey; The tpm module persists the subkey that encapsulates the key value required for the LUK encryption and decryption to the register address of the tpm module; The Luks encryption block obtains the subkey from the register address through decryption instructions; The Luks encryption block is decrypted to obtain the key value required for Luks encryption and decryption in the subkey, and a Luks encryption key pair is generated based on the key value required for Luks encryption and decryption. The Luks encryption block generates a context based on the encryption key pair, and encrypts the storage disk using the context to obtain the encrypted disk.

5. The system according to any one of claims 1 to 4, characterized in that, The key management unit is used to manage and back up keys in the trusted computing environment; The step of backing up the key in the trusted computing environment includes: The backup virtual machine creates a backup master key and sends the backup master key to the business virtual machine; The business virtual machine creates a business master key and encrypts business files based on the business master key; The business virtual machine creates and runs a backup command, imports the backup master key according to the backup command, and generates a backup key pair according to the backup master key and the business master key; When the business virtual machine fails, the backup virtual machine imports the backup key pair and decrypts the business file according to the backup key pair.

6. A trusted computing environment management method based on the OpenStack platform, characterized in that, An application is made in a trusted computing environment management system, which includes: a remote authentication unit, a communication security unit, a data security unit, and a key management unit; The remote verification unit is used to remotely verify whether the virtual machine is trustworthy; the communication security unit is used to establish encrypted communication between the client and the server; the data security unit is used to create an encrypted disk; and the key management unit is used to manage and back up keys in the trusted computing environment. The steps for the remote verification unit to verify whether the virtual machine is trustworthy include: The nova-api component sends a remote certification request to the CA certification center; The CA certification center obtains the PCR list from the virtual machine during registration and generates a random number; The CA certification center sends the PCR list and the random number to the nova-api component; The nova-api component generates a remote authentication request based on the PCR manifest and the random number, and sends the remote authentication request to the virtual machine; The virtual machine invokes the virtual machine's remote authentication service to parse the remote authentication request and generate a remote authentication report for the virtual machine. The virtual machine sends the remote proof report to the nova-compute component; The nova-compute component calls the remote proof service of the host machine to obtain the remote proof report of the host machine, merges the remote proof report of the virtual machine and the remote proof report of the host machine to generate a remote proof report, and sends the remote proof report to the CA certification center; The CA certification center verifies the remote proof report, generates a remote verification result, and sends the remote verification result to the nova-compute component; The nova-compute component saves the remote verification results to the database to enable remote authentication of the virtual machine.

7. The method according to claim 6, characterized in that, The virtual machine invokes the virtual machine's remote authentication service to parse the remote authentication request and generate a virtual machine remote authentication report, including: The virtual machine obtains the private key from the asymmetric key pair; The remote authentication request is parsed by calling the virtual machine's remote authentication service, and the random number and PCR list in the remote authentication request are obtained. The random number and the PCR list are encrypted using the private key in the asymmetric key pair to generate a remote proof report for the virtual machine.

8. The method according to claim 6, characterized in that, The steps for establishing encrypted communication between the client and server by the communication security unit include: The CA key center creates a CA root key and creates a CA root certificate based on the CA root key; The CA key center sends the CA root certificate to the server and the client; The server creates a server key pair and creates a server certificate request based on the server key pair, wherein the server key pair includes a server private key and a server public key; The server signs the server certificate request based on the server private key and the CA root certificate, and generates a server certificate, wherein the server certificate includes information about the server public key; The client creates a client key pair and creates a client certificate request based on the client key pair, wherein the client key pair includes a client private key and a client public key; The client signs the client certificate request based on the client private key and the CA root certificate, and generates a client certificate, wherein the client certificate includes information about the client public key; The client sends the client certificate to the server; The server sends its certificate to the client to establish two-way authentication between the client and the server. If the two-way authentication between the client and the server passes, the server generates a first shared key pair based on the server's private key and the client's public key. The client generates a second shared key pair based on the client's private key and the server's public key; If the first shared key pair and the second shared key pair are the same, then the server and the client communicate encrypted based on the shared key.

9. The method according to claim 6, characterized in that, The steps for creating an encrypted disk using the data security unit include: The tpm module creates a master key and generates subkeys based on the master key; The tpm module generates the key value required for LUKs encryption and decryption, and encapsulates the key value required for LUKs encryption and decryption into the subkey; The tpm module persists the subkey that encapsulates the key value required for the LUK encryption and decryption to the register address of the tpm module; The Luks encryption block obtains the subkey from the register address through decryption instructions; The Luks encryption block is decrypted to obtain the key value required for Luks encryption and decryption in the subkey, and a Luks encryption key pair is generated based on the key value required for Luks encryption and decryption. The Luks encryption block generates a context based on the encryption key pair, and encrypts the storage disk using the context to obtain the encrypted disk.

10. The method according to any one of claims 6 to 9, characterized in that, The key management unit is used to manage and back up keys in the trusted computing environment; The step of backing up the key in the trusted computing environment includes: The backup virtual machine creates a backup master key and sends the backup master key to the business virtual machine; The business virtual machine creates a business master key and encrypts business files based on the business master key; The business virtual machine creates and runs a backup command, imports the backup master key according to the backup command, and generates a backup key pair according to the backup master key and the business master key; When the business virtual machine fails, the backup virtual machine imports the backup key pair and decrypts the business file according to the backup key pair.

Citation Information

Patent Citations

  • Disk encryption method and system based on trusted chip

    CN114239091A

  • Remote attestation of cloud infrastructure

    US20190138729A1