--- id: pyelftools version: "0.33" license: Public domain license_treatment: permissive maintenance: active --- # pyelftools — Library for analyzing ELF files and DWARF debugging information License: permissive · Maintenance: active · Downloads: 16.0M/mo ## What it is and what it does pyelftools is a pure-Python library for reading and analyzing ELF (Executable and Linkable Format) binaries and their embedded DWARF debugging metadata. It requires only Python 3 and has no external dependencies, making it straightforward to integrate into tools that need to inspect compiled binaries, extract debug symbols, or analyze executable structure. The library is used in debuggers, disassemblers, binary analysis tools, and compiler infrastructure. It handles the low-level parsing of ELF headers, sections, segments, and symbol tables, as well as DWARF format data. Since it is pure Python, it can be embedded directly in projects without system library requirements, though it is also available on PyPI for standard installation. Use it for: - Extract debug symbols and line number information from compiled binaries for debugger integration - Analyze ELF binary structure to understand sections, segments, and symbol tables in reverse-engineering tools - Parse DWARF metadata to recover source-level information from stripped or optimized executables - Build binary analysis and instrumentation tools that need to read ELF metadata without external C libraries ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. pyelftools parses and analyzes ELF binary files and DWARF debugging information in pure Python, with no external dependencies. Yes. pyelftools is stable (production/stable status), actively maintained, has no dependencies, and is permissively licensed under public domain. It is the standard choice for Python-based ELF and DWARF parsing. Install it if you need to read or analyze ELF binaries or debug information from Python. ## Install pip install pyelftools uv add pyelftools poetry add pyelftools ## Installing pyelftools Before you install: Low friction: pure Python with no runtime dependencies, distributed as a wheel. Active maintenance with a recent release 77 days ago and 2270 repository stars. License in practice: Public domain license permits unrestricted use, modification, and distribution with no attribution or copyleft obligations. Quickstart: pip install pyelftools import pyelftools # See user's guide for detailed usage examples Requires Python 3.10 or later; input must be a valid ELF binary file. Verify before relying: - Specific DWARF versions or ELF variants supported beyond the general claim - Performance characteristics or file size limits for large binaries - Whether the library can be used without installation by adjusting PYTHONPATH as described ## Package facts - License: Public domain (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 16.0M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags ELF file parser, DWARF debugging information, binary file analysis, ELF format reader, debug symbol extraction, binary-analysis, debugging-tools [View on SkillFed](https://skillfed.io/packages/pyelftools) · [View on PyPI](https://pypi.org/project/pyelftools/)