Skip to content

This is a laboratory experience on RISC-V cryptocore coprocessor driver developement, designed for the course Operating Systems, held by Professor Stefano DiCarlo, of Politecnico di Torino, IT

License

Notifications You must be signed in to change notification settings

TommiTerza/riscv64_cryptocore_edu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Laboratory Exercise Guidelines: Exploring Kernel Modules and QEMU Virtualization

The primary objective of this laboratory session is to provide insights into kernel modules and explore the powerful environment of QEMU, a robust and open-source machine emulator and virtualizer. This activity is designed to give engineering students a general understanding of these topics.

What is a Kernel Module?

Kernel modules are pieces of code that can be loaded and unloaded into the kernel upon demand. They extend the functionality of the kernel without the need to reboot the system. For example, one type of module is the device driver, which allows the kernel to access hardware connected to the system. Without modules, we would have to build monolithic kernels, resulting in larger kernels and requiring a reboot every time new functionality is added.

About QEMU

QEMU is an advanced and open-source tool for machine emulation and virtualization. In this laboratory activity, we will focus on two fundamental emulation features of QEMU:

System Emulation

QEMU can potentially emulate an entire machine, including the CPU, memory, and devices. Its main aim is to execute a guest operating system, supporting full CPU emulation. QEMU collaborates with hypervisors such as KVM, Xen, or Hypervisor, providing a framework for direct execution on the host CPU.

User Mode

QEMU has the capability of launching processes compiled for one CPU on another one, ensuring CPU emulation. Additionally, QEMU provides a suite of standalone command-line utilities, including qemu-img, a disk image tool facilitating the creation, conversion, and modification of disk images.

Prepare for hands-on activities during this laboratory experience to gain practical insights into kernel modules and QEMU virtualization.


Exploring Security Vulnerabilities in a Cryptocore Linux Device Driver on QEMU for ARM/RISC-V ISA

In this simulation, we will investigate potential security vulnerabilities in a Linux device driver for a cryptocore. Our focus will be on the ARM or RISC-V ISA architectures using the QEMU emulator. The objective is to comprehensively understand and identify security risks associated with device drivers and explore robust measures to mitigate these vulnerabilities.

Introduction

Device drivers play a critical role in facilitating communication between the operating system and hardware components. However, if not properly secured, they can become vulnerable to exploitation. This laboratory exercise is structured to simulate and analyze potential attacks on a Linux device driver responsible for managing a cryptocore.

Simulation Environment

The activities explained in this tutorial will be conducted in a controlled environment using the QEMU emulator for either the ARM or RISC-V ISA architecture. This approach ensures a general exploration of these potential attacks without posing any real-world risks to physical devices.

Conclusion

Through the steps of this tutorial, students will gain valuable insights into the potential vulnerabilities of Linux device drivers for cryptographic hardware while simulating it in a QEMU environment. This experience will lead to a much mature understanding of the security measures that need to be taken when dealing with the safeguarding of these critical components.

All the tutorial's steps to follow are available for the students here

About

This is a laboratory experience on RISC-V cryptocore coprocessor driver developement, designed for the course Operating Systems, held by Professor Stefano DiCarlo, of Politecnico di Torino, IT

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published