With the rise of the cloud, computation has become highly distributed. Workloads can be running on many compute nodes and often span multiple data centers. A workload consists of a combination of code and data, and both are often valuable and sensitive. A data center is often managed by a third-party, such as Cloud Service Provider (CSP), and may reside in a different legal jurisdiction to the workload’s owner. The need to host increasingly sensitive workloads in the cloud has driven the need for Confidential computing. This is a model where a workload can be deployed on third-party infrastructure, with a high degree of confidence that no third party can compromise its confidentiality nor its integrity.
While today this model is most often used to describe properties that are desirable in a public cloud, there is growing interest in several other markets. Modern vehicle design seeks to consolidate multiple workloads from different suppliers onto a single in-car server. The consumerization of IT has led to a mix of personal and corporate data on personal computers. These are both examples of applications that have similar security requirements to the public cloud, and where the same underlying security technologies can be reused.
Several challenges must be solved to construct a platform that supports Confidential computing, but the main challenge has been how to protect data and code while it is being processed. By comparison, it is relatively easy to protect data at rest and data in motion by using strong encryption, digital signatures, and careful key management.
With the recent publication of the first open-source patches that support the Realm Management Extension (RME), now is a great time to look at the latest developments and features for Confidential computing on Arm. In this blog I, provide a brief overview of the techniques that can be used to build a computing platform that supports Confidential computing. This includes a summary of the newest features Arm has added to the Armv9-A Architecture, and details of Arm’s supporting reference software architecture.
The designers of any platform providing Confidential computing must analyze the threats and risks that need to be defended and those which are acceptable and therefore considered to be out of scope. Example threats that are typically considered in this analysis include:
Mitigating these and other threats often requires a fundamental change to the familiar model of computer security that relies on a hierarchy of privilege levels, whereby each level implicitly trusts the more privileged layers of infrastructure here.
Figure 1: An example of the traditional hierarchy of privilege
Examples of components that often have the greatest privilege and that must therefore be trusted by end users include platform firmware and where relevant, a virtualization hypervisor. This infrastructure often has unfettered access to workloads and is trusted to not abuse this privilege. This can cause concern if the privileged code is considered likely to contain exploitable security vulnerabilities. Removing or reducing the need to trust this privileged infrastructure, that maybe invisible to users, can be achieved in a variety of different ways, including:
Arm introduced processor support for virtualization, including stage-two translation tables, in the Armv7-A Architecture. These features provide effective hardware-backed address space isolation between virtual machines that share a platform. It is possible to use this and other features of the A-Profile Architecture to build a platform that supports Confidential computing. Where virtualization is used, the hypervisor typically has sufficient privilege to access user workloads, but controls can be put in place to provide assurance that the hypervisor will not abuse that privilege. For example, the risk of a bad hypervisor can be mitigated by making the hypervisor small, open, and verifiable. Formal methods can be used to demonstrate the hypervisor functions correctly and a secure root of trust can then be used to prevent unauthorized changes to the platform and to underpin attestation. The root of trust is typically a dedicated secure microprocessor that controls the boot process by loading and verifying the system firmware before releasing a main system CPU from reset.
In 2021, Arm announced the Realm Management Extension (RME) as a major addition to the Armv9-A Architecture, and the Arm Confidential Compute Architecture (Arm CCA). Arm is working with several partners on the first silicon implementations of RME.
RME is an isolation architecture that allows hypervisors to create and manage special execution environments for workloads called Realms. A Realm is a protected environment that is designed to provide additional security to workloads such as virtual machines. When a virtual machine runs within a Realm, a hypervisor has the same powers to create, destroy, schedule, add, or remove resources such memory and devices as they do for traditional virtual machines. The key difference is that a hypervisor cannot access the code or memory of a Realm. In this sense the hypervisor is deprivileged, and a workload can use attestation to verify that this deprivileging has occurred before it loads any sensitive code or data. We expect RME to become a mainstream feature in future generations of CPU. RME provides another tool that can help security architects reduce the amount of code that has access to workloads and can be used to further harden a platform that supports virtualization. RME also standardizes support for memory encryption and attestation.
Arm announces updates to the A-Profile Architecture annually, and in 2022, we announced enhancements to RME to support a wider range of use cases with Memory Encryption Contexts (MEC) and Device Assignment (DA).
The specification for RME incorporating MEC can be found in version J.a of the Arm Architecture Reference Manual and the specification for DA will be published shortly. See https://www.arm.com/armcca for further information.
When Arm delivers new architectural features that are implemented in hardware, we also think about what is needed to make use of those features in a complete system. Some partners prefer to take Arm’s hardware architecture and create their own software that is tailored to their specific market and needs, while others appreciate the option of a more complete solution that includes software. For this reason, we created the Arm Confidential Compute Architecture (Arm CCA) that includes RME.
Figure 2: Arm CCA builds on RME to provide a reference software security architecture.
Arm CCA builds on RME by providing an optional reference firmware and software security architecture that can be used to implement a hypervisor-based platform that supports Confidential computing. By choosing Arm CCA in addition to RME, Arm’s partners benefit from an established software architecture that supports popular open-source projects including Trusted Firmware-A, Linux, and KVM. Arm CCA is an open architecture that is being actively assessed using formal methods, helping partners to demonstrate that their security technologies follow established best practice. The use of a standard software architecture improves portability, and reduces the burden of long-term maintenance, and can also lead to greater transparency of implementation. You can read more about Arm CCA at developer.arm.com.
I am delighted that Arm has just published the first Arm CCA “Request for Comments” patches for the Linux stack with contributions to the Linux kernel and KVM. Following review, I hope these contributions will be accepted by the upstream projects. This helps a broad range of service providers offer secure Confidential computing on Arm-based systems without the cost and complexity of developing their own custom solutions. You can find the Request for Comments for the Arm CCA Linux stack here. The first EDK2 patches for guest firmware are available.