- Palacios is
an operating system independent virtual machine monitor
targetting either IA32 or X86-64 architectures
-
Palacios
- xia.pdf
- non-paravirtualized
- uses shadow paging in the virtual
MMU model
- is capable of booting an unmodified Linux distribution
from either a physical hardware CD ROM drive, or a virtual
CD ramdisk image.
- 20 KLOC of C and assembly written from scratch
- 10 KLOC of C and assembly to implement necessary basic virtual devices
-
Compiling
Palacios generates a static library that can be linked to
either 32 or 64 bit executables and operating systems.
- The DMM maintains a hooked I/O list, a list of I/O
ports for which guest reads, writes, or both must be intercepted
by the DMM.
- Serial Port Debugging
- ability to do source-level debugging with gdb when Palacios is run under QEMU
- A modified version of the BOCHS BIOS and VGABIOS is used to bootstrap the guest OS
-
VPIO
-
Main Component : DMM : Device Monitor Model : VT & SVN Support
- It intercepts device
requests from the guest device driver, receives interrupts
from physical devices and delivers them to guests, drives
a internal device state model for each guest, and can determine
whether the device can be handed off to another
guest, and what host physical addresses a DMA operation
will involve.
-
List
- maintains an internal state-machine model
for each guest, which keeps track of the current status
(e.g, reusability, DMA operation started, etc) of the physical
device as seen from the guest
- The unhooked I/O list are those ports
which the model does not require; reads and writes to
those ports are not intercepted by the DMM
-
Targets
- whether the device is reusable
- whether a DMA is about to be initiated, and to where
- what device requests (e.g., I/O ports)
-
Checking Function
- A checking
function is called before a state transition occurs, and
must approve the state transition. If state transition is
denied, the device request fails, and no state transition
occurs
- can change the hooked I/O list.
- Memory Map Not Supported
-
DMA
- before DMA starts,
the guest device driver must set it up, using device requests
(I/O port reads/writes, currently)
-
Device multiplexing
- The device model determines when a
device is in a reusable state, and can be switched. If a
guest attempts to performan operation on a device it does
not currently hold, it is blocked until the device becomes
available.
-
Example
-
NE2000
- It supportsDMA for sends
and receives, including ring buffering
- DMM
- Device model for NE2000 NIC
-
QEMU
- runs as a user application on top of Linux and provides
virtual devices and an instruction emulator.
- Vancouver
-
Case Studied
- XED
- BOCHS BIOS
- VGABIOS
- self-virtualized devices
- shadow paging
- L4Linux
-
TCB
- The trusted computing base (TCB) is everything in a computing system
that provides a secure environment. This includes the operating system
and its provided security mechanisms, hardware,
physical locations, network hardware and software,
and prescribed procedures.
- recursive address-space model of L4
-
Type Of Virtualization
-
Full Virtualzation
- The full virtualization approach allows datacenters to run an unmodified guest operating
system, thus maintaining the existing investments in operating systems and applications and
providing a nondisruptive migration to virtualized environments. VMware uses a combination of
direct execution and binary translation techniques to achieve full virtualization of an x86
system . http://www.vmware.com/pdf/asplos235_adams.pdf
-
paravirtualization
- The full virtualization approach allows datacenters to run an unmodified guest operating
system, thus maintaining the existing investments in operating systems and applications and
providing a nondisruptive migration to virtualized environments. VMware uses a combination of
direct execution and binary translation techniques to achieve full virtualization of an x86
system . http://www.vmware.com/pdf/asplos235_adams.pdf
- hardware virtualization support
- Secure Co-Processor
-
Nova
- steinberg_eurosys2010.pdf
-
Targets
- Fine-grained functional decomposition of the virtualization
layer into a microhypervisor, root partition manager,
multiple virtual-machine monitors, device drivers, and
other system services.
- Enforcement of the principle of least privilege among all
of these components.
- We do not use paravirtualization in our system,
- If desired, explicit hypercalls from an enlightened
guest OS to the VMM are possible.
- not to use
binary translation
- approximately 9000 lines of source code
-
Kernel Objects
-
protection domains
- The memory space manages the page table
- the I/O space manages the I/O permission bitmap
- capability space controls access to kernel objects.
-
execution contexts
- Execution contexts abstract from the differences between threads and virtual CPUs
-
scheduling
contexts
- implements a preemptive prioritydriven round-robin scheduler with one runqueue per CPU
-
portals
- Communication between protection domains is governed by portals
- semaphores
-
Root Partition Manager
- The root
partition manager performs the initial resource allocation
decisions
-
VMM
-
Vancouver
- emulates sensitive instructions and provides virtual devices.
- manages the
guest-physical memory of its associated virtual machine by
mapping a subset of its own address space into the host
address space of the VM
- The VMM can also map any of
its I/O ports and MMIO regions into the virtual machine to
grant direct access to a hardware device
-
Device Emulation
- The virtual-machine monitor provides virtual devices for
its guest operating system.
- The virtual-machine monitor provides virtual devices for
its guest operating system.
-
BIOS Virtualization
- move the BIOS into the
virtual-machine monitor, which facilitates direct access to
the device models without expensive transitions between
the virtual machine and the VMM.
- The
different Vancouver instances communicate by IPC messages
-
Steps
- Topic
- If the Guest accesses an IO port, the CPU traps and signals the hypervisor (NOVA) of the
#VmExit. The VMM obtains an IPC from Nova with the fault state
and calls all virtual devices connected to a virtual bus. Each device registered to this bus
has to decide if it handles the given address. When it does, it updates its internal state
(set timer, modifying memory) and external behavior (triggering interrupts, changing
device register). Device drivers a realized as a separate Task from the VMM. These drivers
provide the back-ends for the virtual devices.
-
XEN
-
Domain Zero
- Xen uses a privileged
“domain zero”, which hosts Linux as a service OS. Dom0
implements management functions and host device drivers
with direct access to the platform hardware.
-
KVM
- adds support for hardware virtualization to
Linux and turns the Linux kernel with its device drivers into
a hypervisor
- relies on QEMU for implementing
virtual devices and instruction emulation
- management applications directly on
top of the Linux hypervisor in user mode
- Linux is part of the trusted
computing base of KVM and increases the attack surface
accordingly
- VMware ESXi
-
Microsoft Hyper-V
- Xenlike
architecture with a hypervisor
- SecVisor
- Bitvisor
-
Overshadow
-
Topic
- overshadow-asplos08.pdf
- protects the privacy and integrity of application data, even in the
event of a total OS compromise
-
Last Works About Application Security
- protects the privacy and integrity of application data, even in the
event of a total OS compromise
- protects the privacy and integrity of application data, even in the
event of a total OS compromise
- Refactoring applications into more-critical and lesscritical
pieces running in separate protection domains [8, 28] is
ultimately a compelling goal.
- it keeps the trusted computing base (TCB) small by running VMM and device drivers in user mode http://www.hypervisor.org/