Registry / serialization / uefi-firmware

uefi-firmware

JSON →
library1.16pypypi✓ verified 86d ago

Python library for parsing and manipulating UEFI firmware volumes, files, sections, and capsules. It supports common UEFI structures like FFS, FV, FFSv3, compressed sections, and more. The latest version on PyPI is 1.11, but the GitHub repo has releases up to 1.13. Active development with occasional updates.

pip install uefi-firmware
INSTALL
IMPORT
SIG · UEFI-FIRMWARE
U
uefi-firmware
serializationpythonv1.16
Install
2.1s avg
Import
89ms
Disk
21MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.16 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.086s · 23.1MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 2.1s · import 0.092s · 24MB
21MB installed
● package 21MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

AutoParser
from uefi_firmware import AutoParser
from uefi_firmware.parser import AutoParser
AutoParser is a top-level class, not in a submodule.
FirmwareVolume
from uefi_firmware.volume import FirmwareVolume
Common usage for low-level access.

Parses a firmware file using AutoParser and lists all recognized objects.

import os from uefi_firmware import AutoParser # Path to a UEFI firmware image (e.g., a BIOS update file) firmware_path = os.environ.get('FIRMWARE_PATH', 'test.rom') with open(firmware_path, 'rb') as f: data = f.read() parser = AutoParser(data) print(f"Parsed {len(parser.objects)} objects") for obj in parser.objects: print(type(obj).__name__)
uefi-firmware --version
Debug
Known issues
breakingPython 2 support was dropped in version 1.8. If you are still on Python 2, pin to <1.8.
fix
Use Python 3.6+ or pin to 'uefi-firmware<1.8'.
affects: >=1.8
deprecatedThe 'construct' dependency is optional but old examples may try to import directly from 'uefi_firmware.constructs'. Use 'construct' package directly if needed.
fix
Install 'construct' separately if needed, and import from the 'construct' package, not from 'uefi_firmware'.
affects: all
gotchaAutoParser may not detect all structures in fragmented or corrupted firmware images. It will raise exceptions for invalid data.
fix
Wrap parsing in try-except to handle parse failures, and consider using lower-level classes if AutoParser fails.
affects: all
Errors
Common errors & fixes
ImportError: No module named 'uefi_firmware.constructs'
Trying to import constructs submodule that doesn't exist in modern versions.
fix
Use 'from construct import Container, Struct' etc., and install construct if needed.
uefi_firmware.AutoParser' object has no attribute 'objects'
AutoParser returns a list stored as 'result' attribute, not 'objects'.
fix
Access parser.result instead of parser.objects.
Upgrade
Version history
1.16latest on PyPI · released Jun 4, 2026
Audit
Dependencies
constructoptionalUsed for binary structure definitions and parsing.
pycryptodomeoptionalUsed for cryptographic operations (e.g., capsule authentication).
Agent activity
28 hits · last 30 days
node
24
OpenAI (training)
1
Resources
uefi-firmware — pip install uefi-firmware · libregistry