A reliable measurement method for the integrity of user-space executable objects in AMD SEV-SNP confidential virtual machines.

By employing a privilege separation architecture in the AMD SEV-SNP confidential virtual machine, separating the collection of execution permission grant events from the final integrity measurement and adjudication, the problem of integrity protection for user-space executable objects is solved. This enables integrity checks to be completed before execution permissions take effect, thereby improving the security and integrity of the confidential virtual machine.

CN123116254APending Publication Date: 2026-11-17BEIJING JIAOTONG UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611283764.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-24
Publication Date
2026-11-17

AI Technical Summary

Technical Problem

The existing AMD SEV-SNP confidential virtual machine lacks effective integrity checks before granting execution permissions in the integrity protection of user-space executable objects. This can lead to the loading or mapping of tampered or unintended executable content, and the guest kernel has difficulty directly identifying all execution permission granting events without obtaining the context.

Method used

The privilege separation architecture separates the collection of execution permission granting events for user-space executable objects from the final integrity measurement and adjudication. Events are captured and requests are constructed by client-side components in lower privilege domains, while components in higher privilege protection domains perform measurement and adjudication, and finally, an adjudication is generated before the execution permission takes effect.

Benefits of technology

It implements integrity protection for user-space executable objects, prevents objects that do not meet integrity criteria from obtaining execution permissions, and ensures that the final decision is made by a high-privilege domain, thereby improving the security and integrity of the AMD SEV-SNP confidential virtual machine.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123116254A_ABST
    Figure CN123116254A_ABST
Patent Text Reader

Abstract

This invention discloses a reliable integrity measurement method for user-space executable objects in AMD SEV-SNP confidential virtual machines, relating to the fields of computer technology and information security. It comprises a client-side integrity request component and a high-privilege integrity monitoring component. Based on the virtual machine privilege level mechanism, the method deploys the client-side integrity request component in the lower privilege domain of the AMD SEV-SNP confidential virtual machine and the high-privilege integrity monitoring component in the higher privilege protection domain. Specifically, the client-side integrity request component captures events and constructs an integrity processing request before the user-space executable object gains execution permissions. The high-privilege integrity monitoring component accesses and measures the target executable content, generating a final decision to allow or deny the granting of execution permissions. This invention addresses the problem of insufficient privilege isolation between the internal integrity mechanism of the AMD SEV-SNP confidential virtual machine guest operating system and the protected object, achieving integrity control before granting execution permissions to user-space executable objects.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the fields of computer technology and information security technology, specifically to runtime integrity protection technology for user-space executable objects in the AMD SEV-SNP confidential virtual machine, and particularly to a privilege separation integrity control method and system for user-space executable objects in the AMD SEV-SNP confidential virtual machine. Background Technology

[0002] With the development of cloud computing technology, more and more security-sensitive services are being deployed in cloud environments. AMD SEV-SNP confidential virtual machines reduce trust in the host operating system and virtual machine monitor through hardware-supported memory encryption, integrity protection, and isolation mechanisms, enabling business code and data to run in a protected client environment.

[0003] AMD SEV-SNP confidential virtual machines typically establish initial trust during the startup phase through startup metrics and remote authentication. However, after startup, the confidential virtual machine still loads user-space programs, program interpreters, and dynamically shared objects, and establishes new executable mappings or alters the execution permissions of existing memory mappings during runtime. Therefore, the metrics obtained during the startup phase cannot consistently reflect the state of user-space executable objects currently running on the confidential virtual machine. Without integrity checks before granting execution permissions, tampered or unexpected executable content may be loaded or mapped into user space and granted execution permissions.

[0004] The integrity measurement and control mechanisms within existing AMD SEV-SNP confidential virtual machine guest operating systems are typically handled by the guest kernel, which performs event capture, content measurement, and execution adjudication. Because the integrity mechanism and the protected object reside in the same or similar privilege domains, the guest kernel may influence the measurement criteria, results, or execution decisions, making it difficult to effectively isolate the final integrity authority from the measured object. Furthermore, the loading and memory mapping information of user-space executable objects is maintained by the guest operating system, making it difficult for higher privilege protection domains to directly identify all execution permission granting events without accessing the guest-side context.

[0005] Therefore, a control scheme for the integrity of executable objects in the user space of the AMD SEV-SNP confidential virtual machine is needed. Based on the virtual machine privilege level mechanism, the collection of execution permission granting events is separated from the final integrity measurement and adjudication. Events and target object context are collected by the lower privilege domain, while the target executable content is accessed and measured by the higher privilege protection domain, and a final adjudication is generated before the execution permission takes effect. Summary of the Invention

[0006] In view of the above problems, this invention proposes a reliable measurement method for the integrity of user-space executable objects in AMD SEV-SNP confidential virtual machines. Based on the virtual machine privilege level mechanism, a lower privilege domain and a higher privilege protection domain are set in the AMD SEV-SNP confidential virtual machine. The collection of execution permission granting events for user-space executable objects is separated from the final integrity measurement and adjudication. Integrity processing is completed before the user-space executable object obtains execution permission.

[0007] (1) This invention provides a reliable measurement method for the integrity of user-space executable objects in AMD SEV-SNP confidential virtual machines, comprising: I. A privilege separation architecture supporting the method, the privilege separation architecture comprising: Within the AMD SEV-SNP confidential virtual machine, lower privilege domains and higher privilege protection domains are set up based on the virtual machine privilege level mechanism; Deploy a client-side integrity request component in the lower privilege domain to capture execution permission grant events, obtain the target object context, construct an integrity processing request, and forward the processing result. Deploy a high-privilege integrity monitoring component in the higher-privilege protection domain to access and measure the target executable content, and generate a final decision based on the integrity measurement results and integrity judgment criteria; The lower privilege domain cannot modify the integrity determination criteria maintained in the higher privilege protection domain.

[0008] II. A method for integrity processing before granting execution permissions, supporting the aforementioned method, the method comprising: Step 1: Before the execution permission of the executable object in user space takes effect, the client-side integrity request component detects the execution permission granting event and obtains the event type, target object role, and location information of the executable content to be measured. Step 2: The client-side integrity request component constructs an integrity processing request based on the acquired information and sends the integrity processing request to the high-privilege integrity monitoring component. Step 3: The high-privilege integrity monitoring component accesses the executable content to be measured based on the location information, performs integrity measurement on the executable content to be measured, and obtains the integrity measurement result. Step 4: The high-privilege integrity monitoring component generates a final decision to allow or deny the grant of execution permissions based on the integrity measurement results and the integrity judgment criteria maintained in the higher-privilege protection domain, and returns the final decision to the client-side integrity request component. Step 5: The client-side integrity request component continues the permission granting process when it receives an allow decision, and blocks the permission granting process when it receives a deny decision.

[0009] 3. A method for handling user-space executable objects that supports the method described above, wherein the user-space executable object includes a main executable program, a program interpreter, and a dynamic shared object; the execution permission granting event includes loading and executing a new program, creating a memory mapping with execution permission, and upgrading a non-executable mapping to an executable mapping.

[0010] IV. An integrity request and measurement method supporting the above method, wherein the client-side integrity request component determines the event type and target object role based on the program loading context or memory mapping context, obtains the file identity information of the target object and one or more executable content ranges to be measured, and encapsulates the information into an integrity processing request; the high-privilege integrity monitoring component accesses the executable content ranges to be measured according to the integrity processing request, forms the object-level measurement result of the target object, and generates a final decision based on the object-level measurement result.

[0011] (2) The present invention also provides a privilege separation integrity control system for user space executable objects of AMD SEV-SNP confidential virtual machines, including a client-side integrity request component, a high-privilege integrity monitoring component and a cross-privilege domain service communication interface; the client-side integrity request component is deployed in the lower privilege domain of the confidential virtual machine, the high-privilege integrity monitoring component is deployed in the higher privilege protection domain of the confidential virtual machine, and the cross-privilege domain service communication interface is used to transmit integrity processing requests and final decisions.

[0012] In one implementation, the higher privilege protection domain is VMPL0, the guest operating system and the guest-side integrity request component run at a virtual machine privilege level lower than VMPL0, and the high privilege integrity monitoring component is deployed on VMPL0 based on the security virtual machine service module, and the two communicate through the security virtual machine service call path.

[0013] The beneficial effects of the embodiments of this application are as follows: This application embodiment separates the collection of execution permission granting events from the final integrity measurement and adjudication by setting up mutually isolated lower privilege domains and higher privilege protection domains within the same confidential virtual machine. This ensures that the final integrity determination criteria and adjudication process are protected by the higher privilege protection domain. By completing the target content measurement and adjudication before the user-space executable object obtains execution permission, it can prevent executable objects that do not meet the integrity determination criteria from obtaining execution permission. By having the operating system execution context obtained by the client-side component and having the high-privilege component complete the trust measurement and final adjudication, the execution permission granting process for the main executable program, program interpreter, and dynamic shared objects can be uniformly processed.

[0014] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description

[0015] Figure 1 A schematic diagram of the system framework provided for an embodiment of this application; Detailed Implementation To make the purpose, technical solution and beneficial effects of this application clearer, the technical solution in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings.

[0016] like Figure 1 The diagram shown is a schematic of the system framework provided in an embodiment of this application. This embodiment uses an AMD Secure Encrypted Virtualization-Secure Nested Paging (SEV-SNP) confidential virtual machine to implement the integrity control method of this application. Within the AMD SEV-SNP confidential virtual machine, a higher privilege protection domain and a lower privilege domain are divided through Virtual Machine Privilege Level (VMPL). VMPL0 serves as the higher privilege protection domain, and the Linux guest operating system runs on VMPL1.

[0017] This embodiment includes the following two components: (1) The client-side integrity request component is deployed on VMPL1 where the Linux guest operating system is located. It includes an event interception unit, a request construction unit, and a bridging unit. The event interception unit is used to detect the execution permission granting event of the user space executable object; the request construction unit is used to collect the target object context and construct the integrity processing request; and the bridging unit is used to send the integrity processing request to the high-privilege integrity monitoring component and receive the final decision.

[0018] (2) The high-privilege integrity monitoring component, based on the Secure VM Service Module (SVSM), is deployed on VMPL0 and includes a policy unit, a measurement unit, and an adjudication unit. The policy unit is used to maintain the basis for integrity judgment; the measurement unit is used to access and measure the target executable content in VMPL1; and the adjudication unit is used to generate a final adjudication to allow or deny the granting of execution permissions based on the integrity measurement results.

[0019] VMPL0 and VMPL1 share the guest physical address space of the confidential virtual machine. The memory region where the high-privilege integrity monitoring component resides is not writable to VMPL1, but the high-privilege integrity monitoring component can access the target memory range of VMPL1 specified in the integrity processing request. The guest-side integrity request component communicates with the high-privilege integrity monitoring component through the SVSM service call path.

[0020] The steps for performing user-space executable object integrity control using this embodiment are as follows: Step 1: Initialize the client-side integrity request component and the high-privilege integrity monitoring component.

[0021] After the AMD SEV-SNP confidential virtual machine starts, SVSM and the high-privilege integrity monitoring components are loaded and initialized in VMPL0, and the Linux guest operating system is started in VMPL1 and the guest-side integrity request components are initialized. The high-privilege integrity monitoring component initializes the policy unit, measurement unit, and adjudication unit, and loads the integrity determination criteria in VMPL0. These criteria include integrity rules set for user-space executable objects and the default handling method used when a rule is not matched.

[0022] The client-side integrity request component initializes the event interception unit, request construction unit, and bridging unit, and sets interception points in the program execution path, executable file mapping path, and execution permission escalation path of the Linux guest operating system. These interception points are located before the execution permissions of the target object take effect.

[0023] Step 2: Detect the execution permission grant event.

[0024] During the operation of a Linux guest operating system, when a user-space executable object is about to obtain execution permissions, the event interception unit detects the corresponding execution permission granting event and suspends the original execution permission granting process before the integrity processing is completed.

[0025] In this embodiment, the user-space executable objects include the main executable program, the program interpreter or dynamic linker, and dynamic shared objects.

[0026] When the Linux guest operating system loads a new program through the program execution path, the event interception unit intercepts the program loading process before the main executable program and the program interpreter obtain execution permissions; when the Linux guest operating system creates a memory mapping with execution permissions, the event interception unit intercepts the mapping process before the mapping obtains execution permissions; when the Linux guest operating system upgrades an existing non-executable mapping to an executable mapping, the event interception unit intercepts the permission upgrade process before the permission change takes effect.

[0027] In this embodiment, the aforementioned execution permission granting paths respectively correspond to the paths in the Linux guest operating system. path, Path and Path. For non-executable-to-executable permission escalation events that do not have a file-backing object, the client-side integrity request component prevents the corresponding memory mapping from gaining execution permissions.

[0028] 3. Step 3: Capture the target context.

[0029] The event interception unit determines the event type and target object role based on the program loading context or memory mapping context, and sends the event type and target object role to the request construction unit.

[0030] For the program execution path, the request construction unit obtains the file identity information of the main executable program and the program interpreter respectively, and determines the executable loading segment in the corresponding executable file.

[0031] For creating a path that supports mapping of files with execute permissions, the request construction unit obtains the file identity information, file offset, and mapping range corresponding to the mapping.

[0032] For paths that are to be upgraded from non-executable mappings to executable mappings, the request construction unit obtains the file identity information corresponding to the mapping and the memory range to be upgraded.

[0033] The request constructor further determines one or more client physical memory ranges corresponding to the executable content to be measured, so that the high privileged integrity monitoring component can access the target content in VMPL1 based on the client physical memory range.

[0034] Step 4: Construct and send an integrity processing request.

[0035] The request construction unit constructs a unified integrity processing request based on the collected target object context. The integrity processing request includes the event type, target object role, file identity information, and location information of one or more executable content ranges to be measured.

[0036] For the program execution path, the request construction unit constructs integrity processing requests for the main executable program and the program interpreter respectively; for the path that supports mapping of files with execution permissions and the path that upgrades execution permissions, the request construction unit constructs integrity processing requests for the range of executable content to be measured corresponding to this mapping.

[0037] The bridging unit sends the integrity processing request to the high-privilege integrity monitoring component via the SVSM service call path. In this embodiment, the Linux guest operating system triggers virtual machine exit via a call path based on the Guest-Hypervisor Communication Block (GHCB) and switches the processing flow to SVSM in VMPL0.

[0038] The Linux guest operating system does not grant execute permissions to the target object until the high-privilege integrity monitoring component returns a final ruling.

[0039] Step 5: The high-privilege integrity monitoring component performs integrity measurements.

[0040] After receiving an integrity processing request, the high-privilege integrity monitoring component parses the event type, target object role, and location information of the scope of executable content to be measured in the integrity processing request.

[0041] The measurement unit accesses the client physical memory in VMPL1 based on the location information, reads one or more executable content ranges to be measured, and performs cryptographic digest operations on the read target content.

[0042] For the main executable and the program interpreter, the measurement unit measures the executable loading segment of the corresponding executable file; for those passing through... Files created using paths support dynamically shared objects and can be accessed via... The path upgrade execution permission file support mapping, and the metric unit measures the executable scope of the corresponding file.

[0043] In one implementation, the executable loading segment for both the main executable and the program interpreter is the executable file within the ELF file. When a target object comprises multiple executable content ranges to be measured, the measurement unit processes each executable content range in a predetermined order to form an object-level integrity measurement result corresponding to the target object.

[0044] 6. Step 6: The high-privilege integrity monitoring component generates the final ruling.

[0045] The measurement unit transmits the object-level integrity measurement results to the adjudication unit. The adjudication unit matches the event type, target object role, object-level integrity measurement results, and integrity judgment criteria maintained by the policy unit to generate a final adjudication that allows or denies granting the permission.

[0046] When the object-level integrity measurement result meets the corresponding allowable conditions, the adjudication unit generates an allowable adjudication; when the object-level integrity measurement result meets the rejection conditions, the adjudication unit generates a rejection adjudication; when no corresponding integrity rule is matched, the adjudication unit generates a final adjudication based on the default processing method in the integrity judgment criteria.

[0047] The final decision is generated by the high-privileged integrity monitoring component running on VMPL0. The client-side integrity request component is only responsible for event detection, context acquisition, request forwarding, and execution of the decision result; it does not generate the final permission decision.

[0048] 7. Step 7: Return to the final ruling and control the granting of execution permissions.

[0049] The high-privilege integrity monitoring component returns the final ruling to the client-side integrity request component via the SVSM service call return path.

[0050] Regarding the program execution path, if both the main executable program and the program interpreter receive a permission decision, the Linux guest operating system continues the program loading process; if either the main executable program or the program interpreter receives a denial decision, the Linux guest operating system terminates the current program loading.

[0051] When creating a mapping path with execute permissions, the Linux guest operating system first establishes a file mapping without execute permissions; when the high privilege integrity monitoring component returns a permission decision, the Linux guest operating system adds execute permissions to the mapping; when the high privilege integrity monitoring component returns a denial decision, the Linux guest operating system revokes the mapping and returns an error.

[0052] For paths that are being upgraded from non-executable to executable, the Linux guest operating system continues the privilege upgrade process when the high privilege integrity monitoring component returns a permission decision; when the high privilege integrity monitoring component returns a denial decision, the Linux guest operating system maintains the non-executable state of the mapping and returns an error.

[0053] Therefore, user-space executable objects only gain execution privileges after the high-privilege integrity monitoring component completes the object integrity measurement and returns a permission ruling.

[0054] The above examples are only used to illustrate the technical methods of the present invention and are not intended to limit it. Those skilled in the art can modify or make equivalent substitutions to the technical solutions of the present invention without departing from the spirit and scope of the present invention. The scope of protection of the present invention should be determined by the claims.

Claims

1. A reliable measurement method for the integrity of user-space executable objects in AMD SEV-SNP confidential virtual machines, characterized in that, The AMD SEV-SNP confidential virtual machine includes a lower privilege domain and a higher privilege protection domain isolated based on a virtual machine privilege level mechanism. A client-side integrity request component is deployed in the lower privilege domain, and a high privilege integrity monitoring component is deployed in the higher privilege protection domain. The lower privilege domain cannot modify the integrity determination criteria maintained in the higher privilege protection domain. The method includes: Before the execution permission of the executable object in user space takes effect, the client-side integrity request component detects the execution permission granting event, obtains the event type, target object role and location information of the executable content to be measured, and constructs an integrity processing request based on the obtained information; The client-side integrity request component sends the integrity processing request to the high-privilege integrity monitoring component; The high-privilege integrity monitoring component accesses and measures the executable content to be measured based on the location information, generates a final decision to allow or deny the grant of execution permissions based on the obtained integrity measurement results and the integrity judgment criteria, and returns the final decision to the client-side integrity request component. The client-side integrity request component continues the permission granting process when it receives an allow decision, and blocks the permission granting process when it receives a deny decision.

2. The method of claim 1, wherein, The user-space executable objects include the main executable program, the program interpreter, and dynamic shared objects. The execution permission granting events include loading and executing a new program, creating a memory mapping with execution permissions, and upgrading a non-executable mapping to an executable mapping.

3. The method of claim 1, wherein, The client-side integrity request component determines the event type and target object role based on the program loading context or memory mapping context, obtains the target object's file identity information and one or more executable content ranges to be measured, and encapsulates the event type, target object role, file identity information, and location information for locating the executable content ranges to be measured into the integrity processing request.

4. The method of claim 1, wherein, The high-privileged integrity monitoring component accesses one or more executable content ranges to be measured based on the location information, performs cryptographic digest operations on the executable content ranges to be measured to form object-level measurement results, and generates the final decision based on the event type, target object role, object-level measurement results, and integrity judgment criteria; wherein, the executable content ranges to be measured for the main executable program and program interpreter include executable loading segments, and the executable content ranges to be measured for dynamically shared objects include memory-mapped ranges with execution permissions.

5. The method of claim 1, wherein, The higher privilege protection domain is VMPL0, and the lower privilege domain is a virtual machine privilege level lower than VMPL0. The guest operating system runs in the lower privilege domain. The high privilege integrity monitoring component is implemented based on the Secure Virtual Machine Service Module (SVSM). The guest-side integrity request component sends the integrity processing request through the Secure Virtual Machine Service call path and receives the final decision.

6. A method of reliable measurement of integrity of an AMD SEV-SNP confidential virtual machine user space executable object, the method comprising: This includes client-side integrity request components, high-privilege integrity monitoring components, and cross-privilege domain service communication interfaces; The client-side integrity request component is deployed in a lower privilege domain in the AMD SEV-SNP confidential virtual machine based on the virtual machine privilege level mechanism. It is used to detect the execution permission granting event before the execution permission of the user space executable object takes effect, obtain the event type, target object role and location information of the executable content to be measured, construct an integrity processing request, and send the integrity processing request through the cross-privilege domain service communication interface. The high-privilege integrity monitoring component is deployed in the AMD SEV-SNP confidential virtual machine in a higher-privilege protection domain divided based on the virtual machine privilege level mechanism. It is used to access and measure the executable content to be measured according to the location information, generate a final decision to allow or deny the grant of execution permissions based on the obtained integrity measurement results and the integrity judgment criteria maintained in the higher-privilege protection domain, and return the final decision through the cross-privilege domain service communication interface. The client-side integrity request component is used to continue the permission granting process when an allow decision is received, and to block the permission granting process when a denial decision is received.

7. The system of claim 6, wherein, The client-side integrity request component includes an event interception unit for detecting the execution permission granting event, a request construction unit for constructing the integrity processing request, and a bridging unit for sending the integrity processing request and receiving the final decision. The high-privileged integrity monitoring component includes a measurement unit for accessing and measuring the executable content to be measured, an adjudication unit for generating the final adjudication, and a strategy unit for maintaining the basis for the integrity determination. The client-side integrity request component is deployed at a lower virtual machine privilege level where the Linux guest operating system resides, and the high-privilege integrity monitoring component is deployed on VMPL0 based on the Security Virtual Machine Service module. The bridging unit communicates with the high-privilege integrity monitoring component through the Security Virtual Machine Service call path.