SlideShare a Scribd company logo
Lars Kurth
Community Manager, Xen Project
Chairman, Xen Project Advisory Board
lars_kurth
Platform Security Summit 18: Xen Security Weather Report 2018
Platform Security Summit 18: Xen Security Weather Report 2018
Meltdown (SP3)
• XPTI: Recommended mitigation
• Followed by XPTI performance improvements – more to follow
Spectre (SP2)
• x86: By default, Xen will pick the most appropriate mitigations based on compiled in
support, loaded microcode, and hardware details, and will virtualise appropriate
mitigations for guests to use.
– Command line controls via the spec-ctrl command line option are available
– 10% net/disk performance improvements in some production scenarios
– 50s boot time improvement on some servers
Spectre (SP2)
• Arm32: Mitigation for Cortex-A15, Cortex-A12, Cortex-A17 are present in Xen 4.7 and
later (requires updated firmware)
• Arm64: SMCCC 1.1 based mitigation for Cortex-A57, Cortex-A72, Cortex-A72, Cortex-
A75 for Xen 4.10 and later.
Spectre (SP1/SP4)
• Attacker needs a suitable "gadget" running inside of the Hypervisor
• Xen has nothing similar to eBPF and no other gadgets. Static analysis by large vendors
in the community has also not yet shown anything
• SP4: microcode based mitigations are available via spec_ctrl=ssbd to enable guest
operating systems and applications to make use of microcode based mitigations
Disaggregation
• Desktop: OpenXT, SecureView, QubesOS
• Embedded: Virtuosity (Q2-Q4 2018), Crucible
• Automotive: EPAM Fusion, GlobalLogic Nautilus
Virtual Machine Introspection
• Server Virtualization: Bitdefender HVI, Zazen, AIS IntroVirt
• Security Software: Cuckoo Sandbox, DRAKVUF
Live Patching
• Server Virtualization: Citrix, Oracle, Huawei
• Cloud Computing: AWS, Oracle, Huawei, IBM Softlayer, Rackspace, … ~50% of pre-disclosure list
These technologies are well understood by a critical mass of Xen Project upstream
maintainers and committers.
Support Status
• Driver Domains: Security supported with caveats (stemming from PCI Passthrough caveats)
• Device Model Stub Domains: Vulnerabilities of a device model stub domain to a hostile driver
domain (either compromised or untrusted) are excluded from security support
Missing upstream Pieces
• Upstream Multi-Domain Build Support: OpenXT, various vendors, … do their own different things
➜ ViryaOS could be the way forward (see lists.xenproject.org/archives/html/xen-devel/2018-
05/msg01097.html)
• Lack of upstream integration testing: looking for contributions or commitment to test RCs
➜ see https://lists.xenproject.org/archives/html/xen-devel/2018-05/msg00976.html
• Linux stub domains: waiting for Invisible Things Labs contribution
Upstream support could be better if there was more active engagement from down streams
This is generally the case for security features with the exception of LP and VMI
➜ more leadership/engagement from security community needed
Measured Boot: TPM/TXT (x86) & OP-TEE (Arm)
• Desktop: OpenXT, SecureView, QubesOS (optional via Anti Evil Maid)
• Embedded: Virtuosity (Q2-Q4 2018), Crucible
• Automotive: EPAM Fusion – actively working on OP-TEE integration with Xen
• Cloud Computing: Oracle (in progress)
Not well understood by upstream maintainers and committers.
XSM:FLASK
• Desktop: OpenXT, SecureView
• Embedded: Virtuosity, Crucible
• Automotive: EPAM Fusion
Not well understood by upstream maintainers and committers. There is a desire to get XSM to a point
where we would like XSM to be supported and could recommend average users to enable; possibly
even having it on by default.
Disaggregation involves breaking up Dom0 into several domains
• These perform actions normally reserved to Dom0 ➜ meaning more permissions are needed
• XSM:FLASK is then used to relax permissions of domains that would be DomU’s
Risks from the viewpoint of the Xen Project
• High risk to enable XSM with a policy that makes the system less safe by allowing 'normal' domains to
do things they weren't able to do before
• Using XSM requires expert capability that most users will not have
• Need a way of guaranteeing that XSM + the "default policy" is at least as safe as no XSM
• Also see XSA-77 (Disaggregated domain management security status)
Possible Solutions
• A test based approach ➜ cumbersome and does not protect users modifying the policy
• An approach that allows starting privileged domains and uses XSM:FLASK to restrict permissions
• Not alone sufficient to become a supported feature
Support.md
xenbits.xenproject.org/docs/unstable/support-matrix.html
• Formalize support and security support status for Xen Functionality
• This highlighted some gaps, such as VMI, XSM, XSM:FLASK
• Some partially security supported features such as Driver Domains, Device Model Stub Domains,
Device Passthrough have raised concerns
What is needed for Features to be (security) supported
• Functional completeness, sufficient automated testing, interface stability ➜ supported
– Automated testing via OSSTEST can be waived if there is a commitment by a community member to run
their own automated tests on Xen RCs
• In most cases this is sufficient to be security supported
– But: in cases where the security team does not have the capability to fix issues, we need commitment
from outside experts to work with the team under embargo in a timely fashion
➜ Example: ARINC635 scheduler
Become a CNA
• Applied to MITRE after a an informal agreement in mid 2017
• Responsibility for awarding CNA status for FOSS projects has been moved to DWF
(so far unresponsive)
Security Process Review
• Performed analysis of Security Process with some recommendations
• Available for review at: lists.xenproject.org/archives/html/xen-devel/2018-05/msg01127.html
Observation
• Very few Security/Embedded companies are on the pre-disclosure list despite qualifying:
Only AIS, BitDefender, Invisible Things Lab are on the list
• I do not understand whether there is a valid reason or this is simply an oversight
Platform Security Summit 18: Xen Security Weather Report 2018
Basic Idea: Remove Sensitive Data from the Hypervisor
• Follow-up on Spectre/Meltdown issues to reduce the risk of data leakage
• The problem: all state from all VMs is currently mapped into the hypervisor
➜ so an attacker can see secrets belonging to other VMs.
• Solution: reorganise the mappings so the absolute minimum amount of data is mapped
➜ an attacker can't access data pertaining to other VMs.
– Get rid of Directmap, etc.
– Per domain heaps
– Reduce non-relevant data that is mapped into Hypervisor context
This will be a hot topic at the Xen Project Developer Summit in Nanjing, China
Status at release of Xen 4.11
• PVH DomU (no passthrough, QEMU not required) – supported
• PVH Dom0 – experimental
• PVH Shim (backwards compatibility) – supported primarily because it has received significant testing
and was used as Meltdown mitigation
• PV / HVM code path separation: progress at around 60% through the code
Future
• Add PCI passthrough support for PVH DomU
• Performance tuning of PVH Dom0 (hypercall performance of PVH guests compared to PV)
• Complete PV / HVM code path separation
– KCONFIG configuration for PV and PVH/HVM modes (CONFIG_PV and CONFIG_HVM)
➜ significant attack surface reduction
• Make all relevant components supported
Possibilities, once PVH work has been completed
Today (Coverity based on standard x86 build) K SLOC
Xen x86 with everything enabled 237
QEMU Upstream x86 / QEMU Traditional x86 1,005 / 125
Estimates (based on manual inspection) K SLOC
x86 PVH for Intel only (no AMD)
No Server features
No XSM, No VMI
128
Additionally remove __init code (which get discarded once
hypervisor is fully set up) and additional components which are not needed for
a more static system as expected in embedded/automotive applications
110
Substantial code size and thus attack surface reduction is possible, but would require significant effort.
A more comprehensive study on x86 code size would be needed.
wiki.xenproject.org/wiki/
Category:Safety_Certification
Items I am aware of (not a complete list)
• PV drivers: input, sound & DRM (EPAM)
• Xen OP-TEE support (EPAM)
• Co-processor (GPU) sharing framework (EPAM)
• Hard real-time support (EPAM)
• Power Management & HMP (Aggios, XILINX)
• Startup latency: Boot multiple VMs in parallel from Device Tree (XILINX)
• RTOS Dom0 / Dom0-less system (Multiple)
• Code size reduction for Safety certification (Multiple)
• Inter-VM communication primitives for hypervisor mediated data exchange (BAE)
• Virtual TPMs for Xen in OpenEmbedded meta-virtualization (BrainTrust)
Full ARM 64 build with standard configuration (via make cloc) is ∼58.5K SLOC
Excludes:
• ACPI (not enabled in default config)
• Dom0
• Key Dom0 components
• Toolstack
Renesas Rcar-3 Kconfig is ∼48K SLOC today.
See lists.xenproject.org/archives/html/xen-devel/2018-04/msg01453.html for a patch under
discussion.
Potentially Feasible:
A smaller Xen configuration of around
45K SLOC may be achievable,
by disabling some core functionality
➜ not clear whether desirable and
the effort required
Cost Example: DO-178C, per 10K SLOC
DAL E (0.11 h/SLOC): ∼0.6 man years … ASIL-A
DAL C (0.20 h/SLOC): ∼1 man years … ASIL-B/C
DAL A (0.67 h/SLOC): ∼3.3 man years … ASIL-D
Hours for vendor with certification experience
Based on data from Dornerworks
Stage 2:
Create shared certification artefacts under the guidance/with support from certification partner
Adapt development processes, where feasible.
4 Complete MISRA
compliance work for
majority of issues.
MISRA Compliance
1 Identify compliance
partner that is willing to
work with the project ➜
PRQA
2 WIP: Formalize
relationship between
vendor and the project
3 Iteratively address
compliance issues within
the Xen Project
community: start with
potentially controversial
and high impact issues.
Certification Partners
1 WIP: Identify possible
certification partners and
understand the
framework they are
willing to work with.
Note: Dornerworks is a
possible partner given
past certification
experience on Xen
2 Formalize relationship
between vendor(s) and
the project
Dom0
RTOS (e.g. FreeRTOS) as
Dom0, and/or Dom0-less
stack with minimal
management tools.
Lead Community
Members
• EPAM, XILINX
• Dornerworks and Star
Lab as possible
collaborators
Minimal Xen
Create minimal Kbuild for
Xen as a reference, using
Renesas R-Car as starting
point (WIP)
Lead Community
Members
• Stefano Stabellini
• EPAM, Dornerworks,
XILINX and others as
collaborators
Reliable data about achievable minimal code size and
community challenges that need to be resolved
Note: Dom0 and Minimal Xen do not need to be
complete to get sufficient data
FreeRTOS based Dom0
• Lead: EPAM
• Commercial safety certified version called SafeRTOS
• Baseline for a Renesas FreeRTOS build: 9 SKLOC
• Would need Xenbus, Xenstore and a Toolstack (most functionality in XL is not needed)
• Hardware domains (or other similar disaggregation techniques) would be needed for drivers
• Working first prototype expected in Q3’2018
Dom0-less option
• Lead: Stefano (Xilinx) & Praveen Kumar (Washington University)
• Much less clear on how this may work, how much work it is and whether such an approach fulfils
safety requirements
• Could build on “Boot multiple VMs in parallel from Device Tree” ➜ clearly has disadvantages for x86
• Demonstrate that after boot Dom0 cannot affect the system anymore
A new proposal for a sub-project: development work has started
around 6 months ago to have something concrete when launching
• A Flexible build system
• A Secure Xen based runtime
• Containers supported natively
• Supports ARM and x86
• Targeted at Embedded and IoT
Proposal open for discussion @ lists.xenproject.org/archives/html/xen-
devel/2018-05/msg01097.html
• A multi-domain build system
• Builds multiple domains in one go
• Creates a runnable SD Card image from multiple domain builds
• Each domain build is independent and runs in a container
• Pre-configured Device Assignments
Dom0 – Alpine Linux Userspace
Dom0 – Kernel Yocto
Dom1 – Driver D Yocto
Dom2 – Driver D Alpine
apks
Image .gz
rootfs
apks
Image
format
generator
SD Card
image
Build processes and interim build
images are docker containers
➜ ease of integration for 3rd party
build systems
• Uses disaggregation, service domains and driver domains
• Measured Boot
• Supports VMs and containers
• Containers are run securely, transparently as Xen VMs
– Issue: port stage-1 Xen to Docker
See www.slideshare.net/xen_com_mgr/xpdss17-keynote-secure-
containers-with-xen-and-coreos-rkt-stefano-stabellini-aporeto
Dom0
DomS
Domain
Manager
DomU
Secure Stage-1
Xen Container
Containderd
creates
request creation (via TBD API)
Platform Security Summit 18: Xen Security Weather Report 2018
L4Re (GPLv2 – dual license) by KernKonzept
• Microvisor with solid feature set
• No public repositories (only code snapshots)
• Requires CLA (Grant of © and patent license)
ACRN (3-BSD license) by Intel
• x86 only supporting some SKUs; no Arm support; no code separation
• Seems to be mostly a copy of the Xen architecture with some differences (e.g. virtio)
➜ Fundamentally a validation of Xen
• Will probably need some time before it becomes mature and complete
• Code size just under 25 SKLOC
Zircon/Fuchsia (BSD/MIT license) by Google
• Not much information available
• PATENTS file prohibits source-code modifications
Platform Security Summit 18: Xen Security Weather Report 2018
Supporting Development
• Development contributions
• Assign engineers to review design RFCs and patches on upstream mailing list
(to make this easier we could add R: tags to MAINTAINERS)
• Test contributions ➜ in particular for unsupported features
• Documentation contributions ➜ some security functionality is not well documented
• Help guide some of our larger projects / initiatives
Funding
• Advisory Board membership
• Sponsoring Events and/or Interns
• Donating Hardware for the Test Lab ➜ e.g. Renesas
• Donate/sponsor Services ➜ e.g. Rackspace
• Travel for engineers to attend community events
Marketing
• User stories, articles, talks at industry events, research …
• The Xen Project can help, but do inform us when you do something
lars.kurth@xenproject.org
Picture by Lars Kurth

More Related Content

PDF
XPDDS18: Xen Project Weather Report 2018
PDF
Fosdem 18: Securing embedded Systems using Virtualization
PDF
XDF18: Heterogeneous Real-Time SoC Software Architecture - Stefano Stabellini...
PDF
XPDDS19: Client Virtualization Toolstack in Go - Nick Rosbrook & Brendan Kerr...
PDF
XPDDS19: How TrenchBoot is Enabling Measured Launch for Open-Source Platform ...
PPTX
OSSJP/ALS19: The Road to Safety Certification: How the Xen Project is Making...
PDF
XPDDS19 Keynote: Xen in Automotive - Artem Mygaiev, Director, Technology Solu...
PDF
Xen Project 15 Years down the Line
XPDDS18: Xen Project Weather Report 2018
Fosdem 18: Securing embedded Systems using Virtualization
XDF18: Heterogeneous Real-Time SoC Software Architecture - Stefano Stabellini...
XPDDS19: Client Virtualization Toolstack in Go - Nick Rosbrook & Brendan Kerr...
XPDDS19: How TrenchBoot is Enabling Measured Launch for Open-Source Platform ...
OSSJP/ALS19: The Road to Safety Certification: How the Xen Project is Making...
XPDDS19 Keynote: Xen in Automotive - Artem Mygaiev, Director, Technology Solu...
Xen Project 15 Years down the Line

What's hot (20)

PDF
OSSA17 - Live patch, VMI, Security Mgmt (50 mins, no embedded demos)
PDF
Unikraft Landing Page Master Slides
PDF
OSSEU18: NVDIMM and Virtualization - George Dunlap, Citrix
PDF
XPDS16: A Paravirtualized Interface for Socket Syscalls - Dimitri Stiliadis, ...
PDF
XPDDS19 Keynote: Xen Project Weather Report 2019 - Lars Kurth, Director of Op...
PDF
XPDDS19 Keynote: Unikraft Weather Report
PDF
2018 Genivi Xen Overview Nov Update
PPTX
Scale17x: Thinking outside of the conceived tech comfort zone
PDF
OSSNA18: Xen Beginners Training
PPTX
OSSJP/ALS19: The Road to Safety Certification: Overcoming Community Challeng...
PPTX
XPDDS18: Windows PV Drivers Project: Status and Updates - Paul Durrant, Citri...
PDF
XPDS14 - Zero-Footprint Guest Memory Introspection from Xen - Mihai Dontu, Bi...
PPTX
Scale14x: Are today's foss security practices robust enough in the cloud era ...
PPTX
OSSEU17: How Open Source Project Xen Puts Security Software Vendors Ahead of ...
PPTX
XPDDS18: Design Session - SGX deep dive and SGX Virtualization Discussion, Ka...
PPTX
ALSS14: Xen Project Automotive Hypervisor (Demo)
PDF
Scale 12x Securing Your Cloud with The Xen Hypervisor
PDF
XPDS16: Xen Project Weather Report 2016
PDF
Securing your Cloud with Xen - SUSECon 2013
PDF
OSSEU18: From Handcraft to Unikraft: Simpler Unikernelization of Your Applica...
OSSA17 - Live patch, VMI, Security Mgmt (50 mins, no embedded demos)
Unikraft Landing Page Master Slides
OSSEU18: NVDIMM and Virtualization - George Dunlap, Citrix
XPDS16: A Paravirtualized Interface for Socket Syscalls - Dimitri Stiliadis, ...
XPDDS19 Keynote: Xen Project Weather Report 2019 - Lars Kurth, Director of Op...
XPDDS19 Keynote: Unikraft Weather Report
2018 Genivi Xen Overview Nov Update
Scale17x: Thinking outside of the conceived tech comfort zone
OSSNA18: Xen Beginners Training
OSSJP/ALS19: The Road to Safety Certification: Overcoming Community Challeng...
XPDDS18: Windows PV Drivers Project: Status and Updates - Paul Durrant, Citri...
XPDS14 - Zero-Footprint Guest Memory Introspection from Xen - Mihai Dontu, Bi...
Scale14x: Are today's foss security practices robust enough in the cloud era ...
OSSEU17: How Open Source Project Xen Puts Security Software Vendors Ahead of ...
XPDDS18: Design Session - SGX deep dive and SGX Virtualization Discussion, Ka...
ALSS14: Xen Project Automotive Hypervisor (Demo)
Scale 12x Securing Your Cloud with The Xen Hypervisor
XPDS16: Xen Project Weather Report 2016
Securing your Cloud with Xen - SUSECon 2013
OSSEU18: From Handcraft to Unikraft: Simpler Unikernelization of Your Applica...
Ad

Similar to Platform Security Summit 18: Xen Security Weather Report 2018 (20)

PDF
2018_GENIVI_XenOverview-123456789011.pdf
PDF
LCC17 - Securing Embedded Systems with the Hypervisor - Lars Kurth, Citrix
PDF
Rootlinux17: An introduction to Xen Project Virtualisation
PDF
Xen Hypervisor Update 2011
PDF
IITCC15: Xen Project 4.6 Update
PPTX
LFCOLLAB15: Xen 4.5 and Beyond
PDF
XPDS14: Xen 4.5 Roadmap - Konrad Wilk, Oracle
PDF
Using Xen Hypervisor for Functional Safety
PPS
Xen Euro Par07
PDF
Xen in Linux (aka PVOPS update)
PDF
Linaro connect : Introduction to Xen on ARM
PPTX
Xen Project Update LinuxCon Brazil
PDF
LF Collaboration Summit: Xen Project 4 4 Features and Futures
PPTX
LinuxCon Japan 13 : 10 years of Xen and Beyond
PDF
Xen in Safety-Critical Systems - Critical Summit 2022
ODP
Xen 4.3 Roadmap
PPTX
LinuxTag13: 10 years of Xen and beyond
PDF
Kernel Recipes 2014 - Xen as a foundation for cloud infrastructure
PDF
XPDSS19: Live-Updating Xen - Amit Shah & David Woodhouse, Amazon
PDF
XPDS13: SecureServe - A Multi-level Secure Server Virtualization Platform on ...
2018_GENIVI_XenOverview-123456789011.pdf
LCC17 - Securing Embedded Systems with the Hypervisor - Lars Kurth, Citrix
Rootlinux17: An introduction to Xen Project Virtualisation
Xen Hypervisor Update 2011
IITCC15: Xen Project 4.6 Update
LFCOLLAB15: Xen 4.5 and Beyond
XPDS14: Xen 4.5 Roadmap - Konrad Wilk, Oracle
Using Xen Hypervisor for Functional Safety
Xen Euro Par07
Xen in Linux (aka PVOPS update)
Linaro connect : Introduction to Xen on ARM
Xen Project Update LinuxCon Brazil
LF Collaboration Summit: Xen Project 4 4 Features and Futures
LinuxCon Japan 13 : 10 years of Xen and Beyond
Xen in Safety-Critical Systems - Critical Summit 2022
Xen 4.3 Roadmap
LinuxTag13: 10 years of Xen and beyond
Kernel Recipes 2014 - Xen as a foundation for cloud infrastructure
XPDSS19: Live-Updating Xen - Amit Shah & David Woodhouse, Amazon
XPDS13: SecureServe - A Multi-level Secure Server Virtualization Platform on ...
Ad

More from The Linux Foundation (20)

PDF
ELC2019: Static Partitioning Made Simple
PDF
XPDDS19 Keynote: Secret-free Hypervisor: Now and Future - Wei Liu, Software E...
PDF
XPDDS19 Keynote: Xen Dom0-less - Stefano Stabellini, Principal Engineer, Xilinx
PDF
XPDDS19 Keynote: Patch Review for Non-maintainers - George Dunlap, Citrix Sys...
PDF
XPDDS19: Memories of a VM Funk - Mihai Donțu, Bitdefender
PDF
XPDDS19: Speculative Sidechannels and Mitigations - Andrew Cooper, Citrix
PDF
XPDDS19: Keeping Coherency on Arm: Reborn - Julien Grall, Arm ltd
PDF
XPDDS19: QEMU PV Backend 'qdevification'... What Does it Mean? - Paul Durrant...
PDF
XPDDS19: Status of PCI Emulation in Xen - Roger Pau Monné, Citrix Systems R&D
PDF
XPDDS19: [ARM] OP-TEE Mediator in Xen - Volodymyr Babchuk, EPAM Systems
PDF
XPDDS19: Bringing Xen to the Masses: The Story of Building a Community-driven...
PDF
XPDDS19: Will Robots Automate Your Job Away? Streamlining Xen Project Contrib...
PDF
XPDDS19: Core Scheduling in Xen - Jürgen Groß, SUSE
PDF
XPDDS19: Implementing AMD MxGPU - Jonathan Farrell, Assured Information Security
PDF
XPDDS19: Support of PV Devices in Nested Xen - Jürgen Groß, SUSE
PDF
XPDDS19: Application Agnostic High Availability Solution On Hypervisor Level ...
PDF
XPDDS19: Xen API Archaeology: Creating a Full-Featured VMI Debugger for the...
PPTX
XPDDS19: Secure Unikraft Applications with Solo5 - Haibo Xu, ARM
PDF
XPDDS19: The Xen-Blanket for 2019 - Christopher Clark and Kelli Little, Star ...
PDF
XPDSS19: Improve the Reliability and Efficiency of Late Microcode Update - Ch...
ELC2019: Static Partitioning Made Simple
XPDDS19 Keynote: Secret-free Hypervisor: Now and Future - Wei Liu, Software E...
XPDDS19 Keynote: Xen Dom0-less - Stefano Stabellini, Principal Engineer, Xilinx
XPDDS19 Keynote: Patch Review for Non-maintainers - George Dunlap, Citrix Sys...
XPDDS19: Memories of a VM Funk - Mihai Donțu, Bitdefender
XPDDS19: Speculative Sidechannels and Mitigations - Andrew Cooper, Citrix
XPDDS19: Keeping Coherency on Arm: Reborn - Julien Grall, Arm ltd
XPDDS19: QEMU PV Backend 'qdevification'... What Does it Mean? - Paul Durrant...
XPDDS19: Status of PCI Emulation in Xen - Roger Pau Monné, Citrix Systems R&D
XPDDS19: [ARM] OP-TEE Mediator in Xen - Volodymyr Babchuk, EPAM Systems
XPDDS19: Bringing Xen to the Masses: The Story of Building a Community-driven...
XPDDS19: Will Robots Automate Your Job Away? Streamlining Xen Project Contrib...
XPDDS19: Core Scheduling in Xen - Jürgen Groß, SUSE
XPDDS19: Implementing AMD MxGPU - Jonathan Farrell, Assured Information Security
XPDDS19: Support of PV Devices in Nested Xen - Jürgen Groß, SUSE
XPDDS19: Application Agnostic High Availability Solution On Hypervisor Level ...
XPDDS19: Xen API Archaeology: Creating a Full-Featured VMI Debugger for the...
XPDDS19: Secure Unikraft Applications with Solo5 - Haibo Xu, ARM
XPDDS19: The Xen-Blanket for 2019 - Christopher Clark and Kelli Little, Star ...
XPDSS19: Improve the Reliability and Efficiency of Late Microcode Update - Ch...

Recently uploaded (20)

PPTX
MYSQL Presentation for SQL database connectivity
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Empathic Computing: Creating Shared Understanding
PPT
Teaching material agriculture food technology
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
cuic standard and advanced reporting.pdf
PPTX
PA Analog/Digital System: The Backbone of Modern Surveillance and Communication
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Electronic commerce courselecture one. Pdf
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
A Presentation on Artificial Intelligence
PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
MYSQL Presentation for SQL database connectivity
Per capita expenditure prediction using model stacking based on satellite ima...
Understanding_Digital_Forensics_Presentation.pptx
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Empathic Computing: Creating Shared Understanding
Teaching material agriculture food technology
“AI and Expert System Decision Support & Business Intelligence Systems”
Review of recent advances in non-invasive hemoglobin estimation
Advanced methodologies resolving dimensionality complications for autism neur...
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
cuic standard and advanced reporting.pdf
PA Analog/Digital System: The Backbone of Modern Surveillance and Communication
Diabetes mellitus diagnosis method based random forest with bat algorithm
Unlocking AI with Model Context Protocol (MCP)
Electronic commerce courselecture one. Pdf
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
A Presentation on Artificial Intelligence
CIFDAQ's Market Insight: SEC Turns Pro Crypto

Platform Security Summit 18: Xen Security Weather Report 2018

  • 1. Lars Kurth Community Manager, Xen Project Chairman, Xen Project Advisory Board lars_kurth
  • 4. Meltdown (SP3) • XPTI: Recommended mitigation • Followed by XPTI performance improvements – more to follow Spectre (SP2) • x86: By default, Xen will pick the most appropriate mitigations based on compiled in support, loaded microcode, and hardware details, and will virtualise appropriate mitigations for guests to use. – Command line controls via the spec-ctrl command line option are available – 10% net/disk performance improvements in some production scenarios – 50s boot time improvement on some servers
  • 5. Spectre (SP2) • Arm32: Mitigation for Cortex-A15, Cortex-A12, Cortex-A17 are present in Xen 4.7 and later (requires updated firmware) • Arm64: SMCCC 1.1 based mitigation for Cortex-A57, Cortex-A72, Cortex-A72, Cortex- A75 for Xen 4.10 and later. Spectre (SP1/SP4) • Attacker needs a suitable "gadget" running inside of the Hypervisor • Xen has nothing similar to eBPF and no other gadgets. Static analysis by large vendors in the community has also not yet shown anything • SP4: microcode based mitigations are available via spec_ctrl=ssbd to enable guest operating systems and applications to make use of microcode based mitigations
  • 6. Disaggregation • Desktop: OpenXT, SecureView, QubesOS • Embedded: Virtuosity (Q2-Q4 2018), Crucible • Automotive: EPAM Fusion, GlobalLogic Nautilus Virtual Machine Introspection • Server Virtualization: Bitdefender HVI, Zazen, AIS IntroVirt • Security Software: Cuckoo Sandbox, DRAKVUF Live Patching • Server Virtualization: Citrix, Oracle, Huawei • Cloud Computing: AWS, Oracle, Huawei, IBM Softlayer, Rackspace, … ~50% of pre-disclosure list These technologies are well understood by a critical mass of Xen Project upstream maintainers and committers.
  • 7. Support Status • Driver Domains: Security supported with caveats (stemming from PCI Passthrough caveats) • Device Model Stub Domains: Vulnerabilities of a device model stub domain to a hostile driver domain (either compromised or untrusted) are excluded from security support Missing upstream Pieces • Upstream Multi-Domain Build Support: OpenXT, various vendors, … do their own different things ➜ ViryaOS could be the way forward (see lists.xenproject.org/archives/html/xen-devel/2018- 05/msg01097.html) • Lack of upstream integration testing: looking for contributions or commitment to test RCs ➜ see https://lists.xenproject.org/archives/html/xen-devel/2018-05/msg00976.html • Linux stub domains: waiting for Invisible Things Labs contribution Upstream support could be better if there was more active engagement from down streams This is generally the case for security features with the exception of LP and VMI ➜ more leadership/engagement from security community needed
  • 8. Measured Boot: TPM/TXT (x86) & OP-TEE (Arm) • Desktop: OpenXT, SecureView, QubesOS (optional via Anti Evil Maid) • Embedded: Virtuosity (Q2-Q4 2018), Crucible • Automotive: EPAM Fusion – actively working on OP-TEE integration with Xen • Cloud Computing: Oracle (in progress) Not well understood by upstream maintainers and committers. XSM:FLASK • Desktop: OpenXT, SecureView • Embedded: Virtuosity, Crucible • Automotive: EPAM Fusion Not well understood by upstream maintainers and committers. There is a desire to get XSM to a point where we would like XSM to be supported and could recommend average users to enable; possibly even having it on by default.
  • 9. Disaggregation involves breaking up Dom0 into several domains • These perform actions normally reserved to Dom0 ➜ meaning more permissions are needed • XSM:FLASK is then used to relax permissions of domains that would be DomU’s Risks from the viewpoint of the Xen Project • High risk to enable XSM with a policy that makes the system less safe by allowing 'normal' domains to do things they weren't able to do before • Using XSM requires expert capability that most users will not have • Need a way of guaranteeing that XSM + the "default policy" is at least as safe as no XSM • Also see XSA-77 (Disaggregated domain management security status) Possible Solutions • A test based approach ➜ cumbersome and does not protect users modifying the policy • An approach that allows starting privileged domains and uses XSM:FLASK to restrict permissions • Not alone sufficient to become a supported feature
  • 10. Support.md xenbits.xenproject.org/docs/unstable/support-matrix.html • Formalize support and security support status for Xen Functionality • This highlighted some gaps, such as VMI, XSM, XSM:FLASK • Some partially security supported features such as Driver Domains, Device Model Stub Domains, Device Passthrough have raised concerns What is needed for Features to be (security) supported • Functional completeness, sufficient automated testing, interface stability ➜ supported – Automated testing via OSSTEST can be waived if there is a commitment by a community member to run their own automated tests on Xen RCs • In most cases this is sufficient to be security supported – But: in cases where the security team does not have the capability to fix issues, we need commitment from outside experts to work with the team under embargo in a timely fashion ➜ Example: ARINC635 scheduler
  • 11. Become a CNA • Applied to MITRE after a an informal agreement in mid 2017 • Responsibility for awarding CNA status for FOSS projects has been moved to DWF (so far unresponsive) Security Process Review • Performed analysis of Security Process with some recommendations • Available for review at: lists.xenproject.org/archives/html/xen-devel/2018-05/msg01127.html Observation • Very few Security/Embedded companies are on the pre-disclosure list despite qualifying: Only AIS, BitDefender, Invisible Things Lab are on the list • I do not understand whether there is a valid reason or this is simply an oversight
  • 13. Basic Idea: Remove Sensitive Data from the Hypervisor • Follow-up on Spectre/Meltdown issues to reduce the risk of data leakage • The problem: all state from all VMs is currently mapped into the hypervisor ➜ so an attacker can see secrets belonging to other VMs. • Solution: reorganise the mappings so the absolute minimum amount of data is mapped ➜ an attacker can't access data pertaining to other VMs. – Get rid of Directmap, etc. – Per domain heaps – Reduce non-relevant data that is mapped into Hypervisor context This will be a hot topic at the Xen Project Developer Summit in Nanjing, China
  • 14. Status at release of Xen 4.11 • PVH DomU (no passthrough, QEMU not required) – supported • PVH Dom0 – experimental • PVH Shim (backwards compatibility) – supported primarily because it has received significant testing and was used as Meltdown mitigation • PV / HVM code path separation: progress at around 60% through the code Future • Add PCI passthrough support for PVH DomU • Performance tuning of PVH Dom0 (hypercall performance of PVH guests compared to PV) • Complete PV / HVM code path separation – KCONFIG configuration for PV and PVH/HVM modes (CONFIG_PV and CONFIG_HVM) ➜ significant attack surface reduction • Make all relevant components supported
  • 15. Possibilities, once PVH work has been completed Today (Coverity based on standard x86 build) K SLOC Xen x86 with everything enabled 237 QEMU Upstream x86 / QEMU Traditional x86 1,005 / 125 Estimates (based on manual inspection) K SLOC x86 PVH for Intel only (no AMD) No Server features No XSM, No VMI 128 Additionally remove __init code (which get discarded once hypervisor is fully set up) and additional components which are not needed for a more static system as expected in embedded/automotive applications 110 Substantial code size and thus attack surface reduction is possible, but would require significant effort. A more comprehensive study on x86 code size would be needed.
  • 17. Items I am aware of (not a complete list) • PV drivers: input, sound & DRM (EPAM) • Xen OP-TEE support (EPAM) • Co-processor (GPU) sharing framework (EPAM) • Hard real-time support (EPAM) • Power Management & HMP (Aggios, XILINX) • Startup latency: Boot multiple VMs in parallel from Device Tree (XILINX) • RTOS Dom0 / Dom0-less system (Multiple) • Code size reduction for Safety certification (Multiple) • Inter-VM communication primitives for hypervisor mediated data exchange (BAE) • Virtual TPMs for Xen in OpenEmbedded meta-virtualization (BrainTrust)
  • 18. Full ARM 64 build with standard configuration (via make cloc) is ∼58.5K SLOC Excludes: • ACPI (not enabled in default config) • Dom0 • Key Dom0 components • Toolstack Renesas Rcar-3 Kconfig is ∼48K SLOC today. See lists.xenproject.org/archives/html/xen-devel/2018-04/msg01453.html for a patch under discussion. Potentially Feasible: A smaller Xen configuration of around 45K SLOC may be achievable, by disabling some core functionality ➜ not clear whether desirable and the effort required Cost Example: DO-178C, per 10K SLOC DAL E (0.11 h/SLOC): ∼0.6 man years … ASIL-A DAL C (0.20 h/SLOC): ∼1 man years … ASIL-B/C DAL A (0.67 h/SLOC): ∼3.3 man years … ASIL-D Hours for vendor with certification experience Based on data from Dornerworks
  • 19. Stage 2: Create shared certification artefacts under the guidance/with support from certification partner Adapt development processes, where feasible. 4 Complete MISRA compliance work for majority of issues. MISRA Compliance 1 Identify compliance partner that is willing to work with the project ➜ PRQA 2 WIP: Formalize relationship between vendor and the project 3 Iteratively address compliance issues within the Xen Project community: start with potentially controversial and high impact issues. Certification Partners 1 WIP: Identify possible certification partners and understand the framework they are willing to work with. Note: Dornerworks is a possible partner given past certification experience on Xen 2 Formalize relationship between vendor(s) and the project Dom0 RTOS (e.g. FreeRTOS) as Dom0, and/or Dom0-less stack with minimal management tools. Lead Community Members • EPAM, XILINX • Dornerworks and Star Lab as possible collaborators Minimal Xen Create minimal Kbuild for Xen as a reference, using Renesas R-Car as starting point (WIP) Lead Community Members • Stefano Stabellini • EPAM, Dornerworks, XILINX and others as collaborators Reliable data about achievable minimal code size and community challenges that need to be resolved Note: Dom0 and Minimal Xen do not need to be complete to get sufficient data
  • 20. FreeRTOS based Dom0 • Lead: EPAM • Commercial safety certified version called SafeRTOS • Baseline for a Renesas FreeRTOS build: 9 SKLOC • Would need Xenbus, Xenstore and a Toolstack (most functionality in XL is not needed) • Hardware domains (or other similar disaggregation techniques) would be needed for drivers • Working first prototype expected in Q3’2018 Dom0-less option • Lead: Stefano (Xilinx) & Praveen Kumar (Washington University) • Much less clear on how this may work, how much work it is and whether such an approach fulfils safety requirements • Could build on “Boot multiple VMs in parallel from Device Tree” ➜ clearly has disadvantages for x86 • Demonstrate that after boot Dom0 cannot affect the system anymore
  • 21. A new proposal for a sub-project: development work has started around 6 months ago to have something concrete when launching • A Flexible build system • A Secure Xen based runtime • Containers supported natively • Supports ARM and x86 • Targeted at Embedded and IoT Proposal open for discussion @ lists.xenproject.org/archives/html/xen- devel/2018-05/msg01097.html
  • 22. • A multi-domain build system • Builds multiple domains in one go • Creates a runnable SD Card image from multiple domain builds • Each domain build is independent and runs in a container • Pre-configured Device Assignments Dom0 – Alpine Linux Userspace Dom0 – Kernel Yocto Dom1 – Driver D Yocto Dom2 – Driver D Alpine apks Image .gz rootfs apks Image format generator SD Card image Build processes and interim build images are docker containers ➜ ease of integration for 3rd party build systems
  • 23. • Uses disaggregation, service domains and driver domains • Measured Boot • Supports VMs and containers • Containers are run securely, transparently as Xen VMs – Issue: port stage-1 Xen to Docker See www.slideshare.net/xen_com_mgr/xpdss17-keynote-secure- containers-with-xen-and-coreos-rkt-stefano-stabellini-aporeto Dom0 DomS Domain Manager DomU Secure Stage-1 Xen Container Containderd creates request creation (via TBD API)
  • 25. L4Re (GPLv2 – dual license) by KernKonzept • Microvisor with solid feature set • No public repositories (only code snapshots) • Requires CLA (Grant of © and patent license) ACRN (3-BSD license) by Intel • x86 only supporting some SKUs; no Arm support; no code separation • Seems to be mostly a copy of the Xen architecture with some differences (e.g. virtio) ➜ Fundamentally a validation of Xen • Will probably need some time before it becomes mature and complete • Code size just under 25 SKLOC Zircon/Fuchsia (BSD/MIT license) by Google • Not much information available • PATENTS file prohibits source-code modifications
  • 27. Supporting Development • Development contributions • Assign engineers to review design RFCs and patches on upstream mailing list (to make this easier we could add R: tags to MAINTAINERS) • Test contributions ➜ in particular for unsupported features • Documentation contributions ➜ some security functionality is not well documented • Help guide some of our larger projects / initiatives
  • 28. Funding • Advisory Board membership • Sponsoring Events and/or Interns • Donating Hardware for the Test Lab ➜ e.g. Renesas • Donate/sponsor Services ➜ e.g. Rackspace • Travel for engineers to attend community events Marketing • User stories, articles, talks at industry events, research … • The Xen Project can help, but do inform us when you do something