The EFI System Partition (ESP) is a dedicated FAT32 partition present on every UEFI-booted drive. It stores bootloaders, firmware update capsules, and configuration files for all installed operating systems. Because the ESP is not automatically assigned a drive letter on Windows and may be mounted at an arbitrary path on Linux, finding it from application code requires firmware-level partition enumeration. TheDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/Rikitav/Unified.Firmware/llms.txt
Use this file to discover all available pages before exploring further.
EfiPartition static class and FirmwareInterface.SystemPartition property do that work for you.
FirmwareInterface.SystemPartition
FirmwareInterface.SystemPartition returns a DirectoryInfo pointing at the root of the ESP. It throws PlatformNotSupportedException if the system is not running in UEFI mode or if UEFI is unavailable.
SystemPartition delegates to EfiPartition.VolumePath, which queries the OS for the partition whose type GUID matches the ESP type.
EfiPartition static class
EfiPartition provides three static members that describe the ESP without going through FirmwareInterface.
EfiPartition.TypeID
The ESP type GUID as defined by the UEFI specification. This value is constant across all machines and partitioning tools:EfiPartition.VolumePath
AVolumePath struct that wraps both the unique partition identifier and the platform-specific full path string:
EfiPartition.Identificator
A shortcut toEfiPartition.VolumePath.Identificator — the unique GUID of this specific partition (not to be confused with the fixed type GUID):
VolumePath struct
VolumePath is an immutable record struct. Its FullPath format varies by platform:
| Platform | Example |
|---|---|
| Windows | \\?\Volume{3f7c96fe-1234-5678-abcd-0a1b2c3d4e5f}\ |
| Linux | /boot/efi or the actual mount point of the ESP |
On Windows,
VolumePath.FullPath uses the \\?\Volume{GUID}\ format, which requires Windows 8 or later and the calling process to have sufficient privileges to open a handle to the volume. The path is not a drive letter and cannot be passed to older APIs that only accept C:\-style paths — use DirectoryInfo or File methods instead.On Linux the library locates the ESP by scanning partition tables. The path returned in
VolumePath.FullPath is the directory where the ESP is currently mounted. If the ESP has not been mounted before calling EfiPartition.VolumePath, the operation will fail. Ensure the ESP is mounted (typically at /boot/efi) before invoking any EfiPartition member.EfiExecutableInfo
EfiExecutableInfo describes a single .efi binary on the ESP and exposes its architecture by reading the PE header — no external tools required.
Properties
| Property | Type | Description |
|---|---|---|
FullName | string | Absolute path to the .efi file |
Application | string | Name of the provider folder (e.g. ubuntu, Microsoft, Boot) |
Architecture | FirmwareApplicationArchitecture | Architecture parsed from the PE COFF header |
FileInfo | FileInfo | Lazily created FileInfo for the same path |
Constructors
From aFileInfo — use when you already have a reference to the file:
.efi if the extension is missing:
FirmwareApplicationArchitecture — looks up the default fallback bootloader (\EFI\Boot\boot{arch}.efi) on the ESP:
EFI\{ApplicationName}\{ApplicationFile}:
DriveInfo and architecture — for an EFI executable on a removable drive rather than the system ESP:
DriveInfo, application name, and file name:
FirmwareApplicationArchitecture enum
| Member | PE value | Description |
|---|---|---|
Ia32 | 0x014C | 32-bit x86 |
x64 | 0x8664 | AMD64 / Intel 64 |
Ia64 | 0x0200 | Intel Itanium 64 |
Arm | 0x01C2 | AArch32 |
AArch64 | 0xAA64 | AArch64 |
RISC_V32 | 0x5032 | RISC-V 32-bit |
RISC_V64 | 0x5064 | RISC-V 64-bit |
RISC_V128 | 0x5128 | RISC-V 128-bit |
Unknown | 0 | Unrecognized PE machine type |
Architecture property of EfiExecutableInfo reads two bytes at the PE header machine field offset and maps the value to this enum, returning Unknown for any unrecognized value.