Secure Zero-Copy Packet Forwarding via Hypervisor DMA Buffer

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In virtualized computer systems, device assignment for secure communication between a guest and a physical device exposes the entire memory space of the guest to the physical device, compromising security and disrupting hardware abstraction, while conventional para-virtualized networking interfaces incur performance degradation due to additional copy operations.

Innovation Solution

Implementing secure zero-copy packet forwarding using a para-virtualized networking interface like VirtIO ring, where the hypervisor establishes a shared memory space accessible via direct memory access (DMA) by the physical device, allowing direct communication without exposing the entire guest memory, thus preserving hardware abstraction and improving security and performance.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If device assignment is used to enable direct communication between guest and physical device, then communication performance is improved, but security is compromised due to exposure of entire guest memory space

Engineering Contradiction:
Improvecommunication performanceVSAvoidsecurity
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent segments the memory space by creating a dedicated DMA buffer region that is separate from the guest's entire memory space. This buffer is the only portion of memory exposed to the physical device via DMA, while the rest of the guest memory remains protected. The segmentation isolates the data transfer pathway, allowing high-performance direct device access without compromising overall guest memory security.

Inventive Principle:
Principle #1Segmentation

2Reliability

If conventional para-virtualized networking interfaces are used, then security is improved by avoiding memory exposure, but performance degrades due to additional copy operations

Engineering Contradiction:
ImprovesecurityVSAvoidcommunication performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent introduces a DMA buffer as an intermediary structure that mediates between the guest memory and physical device. This buffer acts as a secure gateway that enables direct memory access without requiring data to be copied through the hypervisor, thus eliminating the performance penalty of conventional para-virtualized interfaces while maintaining security through controlled memory exposure.

Inventive Principle:
Principle #24Intermediary (Mediator)

3Productivity

If device assignment is implemented, then hardware abstraction is disrupted requiring hardware-specific drivers, but direct device access performance is achieved

Engineering Contradiction:
Improvedevice access performanceVSAvoiddriver complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent creates a universal DMA buffer interface that can be used with different physical devices without requiring device-specific driver implementations. The standardized buffer structure and DMA configuration allow the same mechanism to serve multiple device types, maintaining hardware abstraction while achieving direct access performance. This eliminates the need for hardware-specific drivers by providing a device-agnostic interface layer.

Inventive Principle:
Principle #6Universality (Multi-functionality)

Applied Scientific Principles

This section explains which scientific principles are used to turn an abstract innovation direction into a practical engineering solution.

Function Achieved in This Case

This approach enhances hypervisor security and performance by eliminating additional copy operations and enabling wire-speed packet forwarding without the need for hardware-specific drivers, while maintaining secure communication between virtual and physical devices.

Implementation Method 1

The hypervisor may then configure the shared memory space so that the physical device may access this shared memory space directly (e.g., using direct memory access (DMA) operations) without involving any additional intervention by the hypervisor.

Methodology Applied
Scientific EffectDirect memory access (DMA):

Data Source

PatentUS10540294B2Secure zero-copy packet forwarding
Publication Date: 2020.01.21 RED HAT ISRAEL
  • US10540294B2 patent drawing
  • US10540294B2 patent drawing
  • US10540294B2 patent drawing

AI summary

A hypervisor detects a virtual device configured by a virtual machine, generates a para-virtualized networking interface between the virtual device and a memory space within hypervisor memory, maps the memory space to a peripheral component interconnect (PCI) memory space of the virtual machine, and configures the memory space to be accessible to a physical device via direct memory access (DMA), where the physical device is associated with the virtual device of the virtual machine. The hypervisor then transfer packets between the virtual machine and the physical device using the para-virtualized networking interface.