- What is this Stuff?
- General
- Intel Management Enginge
- AMD PSP
- UEFI
- Exploiting Stuff
- Firmware Analysis
- Speculative Execution Flaws/Writeups
- Miscellaneous Things
- Timeline of Low level software and hardware attack papers
- Dr Sergei Skorobogatov - Researcher in hardware based attacks, good stuff
- Advanced Threat Research - Intel
- 101
- Articles/Blogposts/Writeups
- How to hack a disabled computer or run code in Intel ME
- Intel Management Engine Secrets by Igor Skochinsky
- Security Evaluation of Intel's Active Management Technology
- Security Evaluation of Intel's Active Management Technology
- Disabling Intel ME 11 via undocumented mode - ptsecurity
- Reverse Engineering Intels Management Engine
- On every intel chip core2duo and newer
- Papers
- General
- Tools
- me-tools
- Tools for working with Intel ME
- me-tools
- Miscellaneous
- 101
- Articles/Blogposts/Writeups
- Technical Overview of Windows UEFI Startup Process
- Windows UEFI startup – A technical overview
- Through this analysis paper we’ll give a look at Windows 8 (and 8.1) UEFI startup mechanisms and we’ll try to understand their relationship with the underlying hardware platform.
- Understanding AMT, UEFI BIOS and Secure boot relationships
- Easily create UEFI applications using Visual Studio 2013
- The Empire Strikes Back Apple – how your Mac firmware security is completely broken
- Writeup on compromise of UEFI on apple hardware.
- Papers
- General
- Tools
- Debug Agent Based UEFI Debugging
- The Intel® System Debugger now supports non-JTAG based debug of UEFI BIOS, this requires the use of a target-side debug agent and a USB or serial connection to the debug agent. This article takes you through the steps necessary and the the debug methodology used bey the Intel® System Debugger to use this method to supplement the pure JTAG based UEFI debug method it also supports
- VisualUEFI
- A project for allowing EDK-II Development with Visual Studio
- UDKToolbox
- An toolbox to help adopt Visual Studio for UEFI development.
- ida-uefiutils
- Some scripts for IDA Pro to assist with reverse engineering EFI binaries
- UEFITool
- UEFITool is a cross-platform C++/Qt program for parsing, extracting and modifying UEFI firmware images. It supports parsing of full BIOS images starting with the flash descriptor or any binary files containing UEFI volumes.
- UEFI Firmware Parser
- The UEFI firmware parser is a simple module and set of scripts for parsing, extracting, and recreating UEFI firmware volumes. This includes parsing modules for BIOS, OptionROM, Intel ME and other formats too. Please use the example scripts for parsing tutorials.
- UEFI_RETool
- A tool for UEFI firmware reverse engineering. The tool consists of a plugin for IDA and a set of scripts for UEFI firmware analysing
- Debug Agent Based UEFI Debugging
- 101
- Articles/Blogposts/Writeups
- Exploiting UEFI boot script table vulnerability
- Building reliable SMM backdoor for UEFI based platforms
- From SMM to userland in a few bytes
- Getting Physical: Extreme abuse of Intel based Paging Systems - Part 1
- SMM Rootkits:A New Breed of OS Independent Malware
- In this paper, we draw attention to a different but related threat that exists on many commodity systems in operation today: The System Management Mode based rootkit (SMBR). System Management Mode (SMM) is a relatively obscure mode on Intel processors used for low-level hardware control. It has its own private memory space and execution environment which is generally invisible to code running outside (e.g., the Operating System). Furthermore, SMM code is completely non-preemptible, lacks any concept of privilege level, and is immune to memory protection mechanisms. These features make it a potentially attractive home for stealthy rootkits. In this paper, we present our development of a proof of concept SMM rootkit. In it, we explore the potential of System Management Mode for malicious use by implementing a chipset level keylogger and a network backdoor capable of directly interacting with the network card to send logged keystrokes to a remote machine via UDP. The rootkit hides its memory footprint and requires no changes to the existing Operating System. It is compared and contrasted with VMBRs. Finally, techniques to defend against these threats are explored. By taking an offensive perspective we hope to help security researchers better understand the depth and scope of the problems posed by an emerging class of OS independent malware.
- Papers
- System Management Mode Hack Using SMM for "Other Purposes)
- The research provided in this paper describes in details how to reverse engineer and modify System Management Interrupt (SMI) handlers in the BIOS system firmware and how to implement and detect SMM keystroke logger. This work also presents proof of concept code of SMM keystroke logger that uses I/O Trap based keystroke interception and a code for detection of such keystroke logger.
- A Real SMM Rootkit: Reversing and Hooking BIOS SMI Handlers - Filip Wecherowski
- The research provided in this paper describes in details how to reverse engineer and modify System Management Interrupt (SMI) handlers in the BIOS system firmware and how to implement and detect SMM keystroke logger. This work also presents proof of concept code of SMM keystroke logger that uses I/O Trap based keystroke interception and a code for detection of such keystroke logger.
- Attacking UEFI Boot Script
- Abstract—UEFI Boot Script is a data structure interpreted by UEFI firmware during S3 resume. We show that on many systems, an attacker with ring0 privileges can alter this data structure. As a result, by forcing S3 suspend/resume cycle, an attacker can run arbitrary code on a platform that is not yet fully locked. The consequences include ability to overwrite the flash storage and take control over SMM.
- Bootkit Threats: In Depth Reverse Engineering & Defense- Eugene Rodionov&Aleksandr Matrosov
- Attacks on UEFI Security - Rafal Wojtczuk&Corey Kallenberg
- Attacking and Defending BIOS in 2015
- System Management Mode Hack Using SMM for "Other Purposes)
- Presentations/Slides
- Attacking Intel ® Trusted Execution Technology Rafal Wojtczuk and Joanna Rutkowska
- Stoned Bootkit - BH USA09
- Attacking Intel BIOS - BHUSA09
- 20 Ways Past Secure Boot - Job de Haas - Troopers14
- I Boot when U-Boot, Bernardo Maia Rodrigues (@bernardomr) & Vincent Ruijter (
@_evict
) - Extreme Privelege Escalataion on Windows8 UEFI Systems
- Slides
- Summary by stormehh from reddit: In this whitepaper (and accompanying Defcon/Blackhat presentations), the authors demonstrate vulnerabilities in the UEFI "Runtime Service" interface accessible by a privileged userland process on Windows 8. This paper steps through the exploitation process in great detail and demonstrates the ability to obtain code execution in SMM and maintain persistence by means of overwriting SPI flash
- All Your Boot Are Belong To Us - Intel Security
- How Many Million BIOSes Would you Like to Infect?
- This talk is going to be all about how the automation of BIOS vulnerability exploitation and leveraging of built-in capabilities can yield highly portable UEFI firmware malware. And how millions of systems will be vulnerable for years, because no one cares enough to patch the BIOS bugs we’ve found. So you think you’re doing OPSEC right, right? You’re going to crazy lengths to protect yourself, reinstalling your main OS every month, or using a privacy-conscious live DVD like TAILS. Guess what? BIOS malware doesn’t care! BIOS malware doesn’t give a shit
- Hacking Measured Boot and UEFI - Defcon20
- There's been a lot buzz about UEFI Secure Booting, and the ability of hardware and software manufacturers to lock out third-party loaders (and rootkits). Even the NSA has been advocating the adoption of measured boot and hardware-based integrity checks. But what does this trend mean to the open source and hacker communities? In this talk I'll demonstrate measured boot in action. I'll also be releasing my new Measured Boot Tool which allows you to view Trusted Platform Module (TPM) boot data and identify risks such as unsigned early-boot drivers. And, I'll demonstrate how measured boot is used for remote device authentication. Finally, I'll discuss weaknesses in the system (hint: bootstrapping trust is still hard), what this technology means to the consumerization trend in IT, and what software and services gaps exist in this space for aspiring entrepreneurs.
- Attacks on UEFI security, inspired by Darth Venamis's misery and Speed Racer
- On modern Intel based computers there exists two powerful and protected code regions: the UEFI firmware and System Management Mode (SMM). UEFI is the replacement for conventional BIOS and has the responsibility of initializing the platform. SMM is a powerful mode of execution on Intel CPUs that is even more privileged than a hypervisor. Because of their powerful positions, SMM and UEFI are protected by a variety of hardware mechanisms. In this talk, Rafal Wojtczuk and Corey Kallenberg team up to disclose several prevalent vulnerabilities that result in SMM runtime breakin as well as arbitrary reflash of the UEFI firmware.
- Using Intel TXT to Attack BIOSes
- Detecting BadBIOS, Evil Maids, Bootkits and Other Firmware Malware - Paul English and Lee Fisher
- For attackers, platform firmware is the new Software. Most systems include hundreds of firmwares - UEFI or BIOS, PCIe expansion ROMs, USB controller drivers, storage controller host and disk/SSD drivers. Firmware-level hosted malware, bare-metal or virtualized, is nearly invisible to normal security detection tools, has full control of your system, and can often continue running even when the system is "powered off". Security Firms (eg, "Hacking Team" sell UEFI 0days to the highest bidder), and government agencies include firmware-level malware (eg, Wikileak'ed Vault7 CIA EFI malware). Defenders need to catch-up, and learn to defend their systems against firmware-level malware. In this presentation, we'll cover the NIST SP (147,147b,155,193) secure firmware guidance, for citizens, rather than vendors/enterprises. We'll discuss the problem of firmware-level malware, and cover some open source tools (FlashROM, CHIPSEC, etc.) to help detect malware on your system. We'll be discussing a new open source tool we've just released to help make it easier for you to do this check. You'll also get a nice paper tri-fold copy of our CHIPSEC Quick Reference for Sysadmins [note: we're all sysadmins for our own personal systems(!)], and some scary looking BadBIOS stickers for your laptop.
- Detecting BadBIOS, Evil Maids, Bootkits, and Other Firmware Malware
- BIOS Chronomancy: Fixing the Core Root of Trust for Measurement - BlackHat 2013
- Tools
- CHIPSEC module that exploits UEFI boot script table vulnerability
- ThinkPwn
- Lenovo ThinkPad System Management Mode arbitrary code execution exploit
- Hyper-V backdoor for UEFI
- 101
- Intel® System Studio – UEFI BIOS Debugging
- Debug SPI BIOS after Power Up Sequence
- [An Introduction to Firmware Analysis30c3
- This talk gives an introduction to firmware analysis: It starts with how to retrieve the binary, e.g. get a plain file from manufacturer, extract it from an executable or memory device, or even sniff it out of an update process or internal CPU memory, which can be really tricky. After that it introduces the necessary tools, gives tips on how to detect the processor architecture, and explains some more advanced analysis techniques, including how to figure out the offsets where the firmware is loaded to, and how to start the investigation.
- Analyzing and Running binaries from Firmware Images - Part 1
- Debug Methodology Under UEFI
- Reverse Engineering UEFI Firmware
- Articles/Blogposts/Writeups
- SIMET Box Firmware Analysis: Embedded Device Hacking & Forensics
- Reverse Engineering Router Firmware Writeup - secforce
- Ewon Flexy IoT Router. A Deep dive - Stuart Kennedy
- Firmware Reverse Engineering
- Notes and tools from my experiences reverse engineering firmware
- Papers
- General
- Tools
- Binwalk
- Binwalk is a fast, easy to use tool for analyzing, reverse engineering, and extracting firmware images.
- hw0lat_detector
- A system hardware latency detector Linux Kernel Module. This patch introduces a new hardware latency detector module that can be used to detect high hardware-induced latencies within the system. It was originally written for use in the RT kernel, but has wider applications.
- me-tools
- Tools for working with Intel ME
- Ghidra Firmware Utilities
- Various modules for Ghidra to assist with PC firmware reverse engineering
- Binwalk
- General
- Meltdown and Spectre - Vulnerabilities in modern computers leak passwords and sensitive data.
- Meltdown and Spectre exploit critical vulnerabilities in modern processors. These hardware vulnerabilities allow programs to steal data which is currently processed on the computer. While programs are typically not permitted to read data from other programs, a malicious program can exploit Meltdown and Spectre to get hold of secrets stored in the memory of other running programs. This might include your passwords stored in a password manager or browser, your personal photos, emails, instant messages and even business-critical documents. Meltdown and Spectre work on personal computers, mobile devices, and in the cloud. Depending on the cloud provider's infrastructure, it might be possible to steal data from other customers.
- Reading privileged memory with a side-channel
- KPTI-PoC-Collection
- Meltdown/Spectre PoC src collection.
- Meltdown PoC for Reading Google Chrome Passwords
- Meltdown and Spectre - Vulnerabilities in modern computers leak passwords and sensitive data.
- Meltdown
- Meltdown
- The security of computer systems fundamentally relies on memory isolation, e.g., kernel address ranges are marked as non-accessible and are protected from user access. In this paper, we present Meltdown. Meltdown exploits side effects of out-of-order execution on modern processors to read arbitrary kernel-memory locations including personal data and passwords. Out-of-order execution is an indispensable performance feature and present in a wide range of modern processors. The attack is independent of the operating system, and it does not rely on any software vulnerabilities. Meltdown breaks all security assumptions given by address space isolation as well as paravirtualized environments and, thus, every security mechanism building upon this foundation. On affected systems, Meltdown enables an adversary to read memory of other processes or virtual machines in the cloud without any permissions or privileges, affecting millions of customers and virtually every user of a personal computer. We show that the KAISER defense mechanism for KASLR [8] has the important (but inadvertent) side effect of impeding Meltdown. We stress that KAISER must be deployed immediately to prevent large-scale exploitation of this severe information leakage
- Testing
- Am-I-affected-by-Meltdown
- Meltdown Exploit / Proof-of-concept / checks whether system is affected by Variant 3: rogue data cache load (CVE-2017-5754), a.k.a MELTDOWN.
- Meltdown Proof-of-Concept
- This repository contains several applications, demonstrating the Meltdown bug. For technical information about the bug, refer to the paper:
- Meltdown by Lipp, Schwarz, Gruss, Prescher, Haas, Mangard, Kocher, Genkin, Yarom, and Hamburg
- The applications in this repository are built with libkdump, a library we developed for the paper. This library simplifies exploitation of the bug by automatically adapting to certain properties of the environment.
- This repository contains several applications, demonstrating the Meltdown bug. For technical information about the bug, refer to the paper:
- Meltdown Exploit PoC
- Am-I-affected-by-Meltdown
- Meltdown
- Spectre
- Spectre Attacks: Exploiting Speculative Execution
- Modern processors use branch prediction and speculative execution to maximize performance. For example, if the destination of a branch depends on a memory value that is in the process of being read, CPUs will try guess the destination and attempt to execute ahead. When the memory value finally arrives, the CPU either discards or commits the speculative computation. Speculative logic is unfaithful in how it executes,can access to the victim’s memory and registers, and can perform operations with measurable side effects. Spectre attacks involve inducing a victim to speculatively perform operations that would not occur during correct program execution and which leak the victim’s confidential information via a side channel to the adversary. This paper describes practical attacks that combine methodology from side channel attacks, fault attacks, and return-oriented programming that can read arbitrary memory from the victim’s process. More broadly, the paper shows that speculative execution implementations violate the security assumptions underpinning numerous software security mechanisms, including operating system process separation, static analysis, containerization, just-in-time (JIT) compilation, and countermeasures to cache timing/side-channel attacks. These attacks repre- sent a serious threat to actual systems, since vulnerable speculative execution capabilities are found in microprocessors from Intel, AMD, and ARM that are used in billions of devices. While makeshift processor-specific countermeasures are possible in some cases, sound solutions will require fixes to processor designs as well as updates to instruction set architectures (ISAs) to give hardware architects and software developers a common understanding as to what computation state CPU implementations are (and are not) permitted to leak.
- Testing
- spec_poc_arm
- PoC code implementing variant 3a of the Meltdown attack for AArch64. This allows reading all (potentially excluding registers whose read has side effects - not verified) system registers from user mode, including those which should only be accessible from the EL1 (kernel), EL2 (hypervisor) and EL3 (secure monitor) modes.
- SpectrePoC
- Proof of concept code for the Spectre CPU exploit.
- spectre-attack
- Example of using revealed "Spectre" exploit (CVE-2017-5753 and CVE-2017-5715)
- SpecuCheck
- SpecuCheck is a Windows utility for checking the state of the software mitigations against CVE-2017-5754 (Meltdown) and hardware mitigations against CVE-2017-5715 (Spectre)
- SpectreExploit
- SpectreExploit POC For educational purposes. I am not responsible for any damages or any loss.
- spec_poc_arm
- Spectre Attacks: Exploiting Speculative Execution
- Notes on Intel Microcode Updates
- BIOS Mods - mydigitallife
- MDL Projects and Applications
- Advice for writing a Bootloader? - reddit
- How to develop your own Boot Loader
- WindSLIC SLIC injectors
- includes UEFI, NTFS, bootmgr SLIC injectors and installers.
- Firmware Modifcation kit
- This kit is a collection of scripts and utilities to extract and rebuild linux based firmware images.
-
To-Do
- Add rowhammer related materials
-
GOD MODE UNLOCKED - Hardware Backdoors in x86 CPUs - Christopher Domas
- This talk will demonstrate what everyone has long feared but never proven: there are hardware backdoors in some x86 processors, and they're buried deeper than we ever imagined possible. While this research specifically examines a third-party processor, we use this as a stepping stone to explore the feasibility of more widespread hardware backdoors. https://chaos.mimoja.de/p/BkzDbBgsV#/ http://build.mimoja.de/AMD%20x86_64%20Firmware.html
-
Behind the Scenes of Intel Security and Manageability Engine - Shai Hasarfaty, Yanai Moyal
BMC Related
- The Unbearable Lightness of BMCs | Matias Soler & Nico Waisman (BHUSA2018)
- Remotely Attacking System Firmware - Alex Bazhaniuk, Jesse Michael, Mickey Shkatov(BHUSA2018)
- Turning your BMC into a revolving door - Alexandre Gazet, Fabien Perigaud 0xf4b, Joffrey Czarny - ZeroNights2018
- Subverting your server through its BMC: the HPE iLO4 case - Fabien Periguad, Alexandre Gazet, Joffrey Czarny
- ilo4_toolbox - Subverting your server through its BMC: the HPE iLO4 case
- CVE-2017-12542 - skelsec
- Test and exploit for CVE-2017-12542
- Turning your BMC into a revolving door - Alexandre Gazet, Fabien Perigaud 0xf4b, Joffrey Czarny - ZeroNights 2018
- Unmonitored and unpatched BMC (remote administration hardware feature for servers) are an almost certain source of chaos. They have the potential to completely undermined the security of complex network infrastructures and data centers. Our on-going effort to analyze HPE iLO systems (4 and 5) resulted in the discovery of many vulnerabilities, the last one having the capacity to fully compromise the iLO chip from the host system itself. This talk will show how a combination of these vulnerabilities can turn an iLO BMC into a revolving door between an administration network and the production network.
- Slides
- How Does an Intel Processor Boot? - BinaryDebt
- Understanding L1 Terminal Fault aka Foreshadow: What you need to know - Jon Masters
- GuardION - Android GuardION patches to mitigate DMA-based Rowhammer attacks on ARM
- This software is the open-source component of our paper "GuardION: Practical Mitigation of DMA-based Rowhammer Attacks on ARM", published in the Conference on Detection of Intrusions and Malware & Vulnerability Assessment (DIMVA) 2018. It allows you to patch an Android kernel so that DMA allocations are guarded with empty rows, resulting in the isolation of bitflips and thus mitigation of Drammer-like attacks.
Intel VISA * https://www.blackhat.com/asia-19/briefings/schedule/#intel-visa-through-the-rabbit-hole-13513 * https://www.zdnet.com/article/researchers-discover-and-abuse-new-undocumented-feature-in-intel-chipsets/ * https://www.theregister.co.uk/2019/03/29/intel_visa_hack/ * https://github.com/ptresearch/IntelVISA-BH2019
-
Attacking Hardware Root of Trust from UEFI Firmware - Alex Matrosov(OffensiveCon19)
-
CPU security bugs caused by speculative execution
- This repo is an attempt to collect information on the class of information disclosure vulnerabilities caused by CPU speculative execution that were disclosed on January 3rd, 2018.
-
- One-stop shop for UEFI/BIOS specifications/utilities by UEFI.Tech community
-
uefi_specs_personal_collections
- "This repo contains some UEFI learning documents collected by individuals. Although these documents are not comprehensive enough, they are still helpful for beginner developers." https://www.coalfire.com/The-Coalfire-Blog/April-2019/The-Death-Metal-Suite