lief 0.16.7__cp314-cp314-musllinux_1_2_x86_64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of lief might be problematic. Click here for more details.

@@ -0,0 +1,44 @@
1
+ import enum
2
+ from typing import Iterator, Optional, Union
3
+
4
+
5
+ class LEVEL(enum.Enum):
6
+ OFF = 0
7
+
8
+ TRACE = 1
9
+
10
+ DEBUG = 2
11
+
12
+ CRITICAL = 6
13
+
14
+ ERROR = 5
15
+
16
+ WARN = 4
17
+
18
+ INFO = 3
19
+
20
+ def disable() -> None: ...
21
+
22
+ def enable() -> None: ...
23
+
24
+ def set_level(level: LEVEL) -> None: ...
25
+
26
+ def get_level() -> LEVEL: ...
27
+
28
+ def set_path(path: str) -> None: ...
29
+
30
+ def log(level: LEVEL, msg: str) -> None: ...
31
+
32
+ def debug(msg: str) -> None: ...
33
+
34
+ def info(msg: str) -> None: ...
35
+
36
+ def warn(msg: str) -> None: ...
37
+
38
+ def err(msg: str) -> None: ...
39
+
40
+ def critical(msg: str) -> None: ...
41
+
42
+ def enable_debug() -> None: ...
43
+
44
+ def reset() -> None: ...
lief/objc/__init__.pyi ADDED
@@ -0,0 +1,89 @@
1
+ from typing import Iterator, Optional, Union
2
+
3
+
4
+ class DeclOpt:
5
+ def __init__(self) -> None: ...
6
+
7
+ show_annotations: bool
8
+
9
+ class Metadata:
10
+ def to_decl(self, opt: DeclOpt = ...) -> str: ...
11
+
12
+ @property
13
+ def classes(self) -> Iterator[Optional[Class]]: ...
14
+
15
+ @property
16
+ def protocols(self) -> Iterator[Optional[Protocol]]: ...
17
+
18
+ def get_class(self, name: str) -> Optional[Class]: ...
19
+
20
+ def get_protocol(self, name: str) -> Optional[Protocol]: ...
21
+
22
+ class Class:
23
+ @property
24
+ def name(self) -> str: ...
25
+
26
+ @property
27
+ def demangled_name(self) -> str: ...
28
+
29
+ @property
30
+ def super_class(self) -> Optional[Class]: ...
31
+
32
+ @property
33
+ def is_meta(self) -> bool: ...
34
+
35
+ @property
36
+ def methods(self) -> Iterator[Optional[Method]]: ...
37
+
38
+ @property
39
+ def protocols(self) -> Iterator[Optional[Protocol]]: ...
40
+
41
+ @property
42
+ def properties(self) -> Iterator[Optional[Property]]: ...
43
+
44
+ @property
45
+ def ivars(self) -> Iterator[Optional[IVar]]: ...
46
+
47
+ def to_decl(self, opt: DeclOpt = ...) -> str: ...
48
+
49
+ class IVar:
50
+ @property
51
+ def name(self) -> str: ...
52
+
53
+ @property
54
+ def mangled_type(self) -> str: ...
55
+
56
+ class Protocol:
57
+ @property
58
+ def mangled_name(self) -> str: ...
59
+
60
+ @property
61
+ def optional_methods(self) -> Iterator[Optional[Method]]: ...
62
+
63
+ @property
64
+ def required_methods(self) -> Iterator[Optional[Method]]: ...
65
+
66
+ @property
67
+ def properties(self) -> Iterator[Optional[Property]]: ...
68
+
69
+ def to_decl(self, opt: DeclOpt = ...) -> str: ...
70
+
71
+ class Method:
72
+ @property
73
+ def name(self) -> str: ...
74
+
75
+ @property
76
+ def mangled_type(self) -> str: ...
77
+
78
+ @property
79
+ def address(self) -> int: ...
80
+
81
+ @property
82
+ def is_instance(self) -> bool: ...
83
+
84
+ class Property:
85
+ @property
86
+ def name(self) -> str: ...
87
+
88
+ @property
89
+ def attribute(self) -> str: ...
lief/pdb/__init__.pyi ADDED
@@ -0,0 +1,102 @@
1
+ import enum
2
+ from typing import Iterator, Optional, Union
3
+
4
+ from . import types as types
5
+ import lief
6
+
7
+
8
+ def load(path: str) -> Optional[DebugInfo]: ...
9
+
10
+ class Type:
11
+ class KIND(enum.Enum):
12
+ UNKNOWN = 0
13
+
14
+ CLASS = 1
15
+
16
+ POINTER = 2
17
+
18
+ SIMPLE = 3
19
+
20
+ ENUM = 4
21
+
22
+ FUNCTION = 5
23
+
24
+ MODIFIER = 6
25
+
26
+ BITFIELD = 7
27
+
28
+ ARRAY = 8
29
+
30
+ UNION = 9
31
+
32
+ STRUCTURE = 10
33
+
34
+ INTERFACE = 11
35
+
36
+ @property
37
+ def kind(self) -> Type.KIND: ...
38
+
39
+ class DebugInfo(lief.DebugInfo):
40
+ @property
41
+ def age(self) -> int: ...
42
+
43
+ @property
44
+ def guid(self) -> str: ...
45
+
46
+ @staticmethod
47
+ def from_file(filepath: str) -> Optional[DebugInfo]: ...
48
+
49
+ def find_type(self, name: str) -> Optional[Type]: ...
50
+
51
+ def find_public_symbol(self, name: str) -> Optional[PublicSymbol]: ...
52
+
53
+ @property
54
+ def public_symbols(self) -> Iterator[Optional[PublicSymbol]]: ...
55
+
56
+ @property
57
+ def compilation_units(self) -> Iterator[Optional[CompilationUnit]]: ...
58
+
59
+ @property
60
+ def types(self) -> Iterator[Optional[Type]]: ...
61
+
62
+ class PublicSymbol:
63
+ @property
64
+ def name(self) -> str: ...
65
+
66
+ @property
67
+ def section_name(self) -> str: ...
68
+
69
+ @property
70
+ def RVA(self) -> int: ...
71
+
72
+ @property
73
+ def demangled_name(self) -> str: ...
74
+
75
+ class CompilationUnit:
76
+ @property
77
+ def module_name(self) -> str: ...
78
+
79
+ @property
80
+ def object_filename(self) -> str: ...
81
+
82
+ @property
83
+ def sources(self) -> Iterator[str]: ...
84
+
85
+ @property
86
+ def functions(self) -> Iterator[Optional[Function]]: ...
87
+
88
+ class Function:
89
+ @property
90
+ def name(self) -> str: ...
91
+
92
+ @property
93
+ def RVA(self) -> int: ...
94
+
95
+ @property
96
+ def code_size(self) -> int: ...
97
+
98
+ @property
99
+ def section_name(self) -> str: ...
100
+
101
+ @property
102
+ def debug_location(self) -> lief.debug_location_t: ...
@@ -0,0 +1,69 @@
1
+ from typing import Iterator, Optional, Union as _Union
2
+
3
+ import lief.pdb
4
+
5
+
6
+ class Simple(lief.pdb.Type):
7
+ pass
8
+
9
+ class Array(lief.pdb.Type):
10
+ pass
11
+
12
+ class BitField(lief.pdb.Type):
13
+ pass
14
+
15
+ class ClassLike(lief.pdb.Type):
16
+ @property
17
+ def attributes(self) -> Iterator[Optional[Attribute]]: ...
18
+
19
+ @property
20
+ def methods(self) -> Iterator[Optional[Method]]: ...
21
+
22
+ @property
23
+ def unique_name(self) -> str: ...
24
+
25
+ @property
26
+ def name(self) -> str: ...
27
+
28
+ @property
29
+ def size(self) -> int: ...
30
+
31
+ class Class(ClassLike):
32
+ pass
33
+
34
+ class Structure(ClassLike):
35
+ pass
36
+
37
+ class Interface(ClassLike):
38
+ pass
39
+
40
+ class Attribute:
41
+ @property
42
+ def name(self) -> str: ...
43
+
44
+ @property
45
+ def type(self) -> Optional[lief.pdb.Type]: ...
46
+
47
+ @property
48
+ def field_offset(self) -> int: ...
49
+
50
+ class Method:
51
+ @property
52
+ def name(self) -> str: ...
53
+
54
+ class Enum(lief.pdb.Type):
55
+ pass
56
+
57
+ class Function(lief.pdb.Type):
58
+ pass
59
+
60
+ class Modifier(lief.pdb.Type):
61
+ @property
62
+ def underlying_type(self) -> Optional[lief.pdb.Type]: ...
63
+
64
+ class Pointer(lief.pdb.Type):
65
+ @property
66
+ def underlying_type(self) -> Optional[lief.pdb.Type]: ...
67
+
68
+ class Union(ClassLike):
69
+ pass
lief/py.typed ADDED
File without changes
@@ -0,0 +1,85 @@
1
+ Metadata-Version: 2.2
2
+ Name: lief
3
+ Version: 0.16.7
4
+ Summary: Library to instrument executable formats
5
+ Keywords: parser,elf,pe,macho,reverse-engineering
6
+ Author-Email: Romain Thomas <contact@lief.re>
7
+ License: Apache License 2.0
8
+ Classifier: Development Status :: 4 - Beta
9
+ Classifier: Programming Language :: Python :: 3
10
+ Classifier: Programming Language :: C++
11
+ Classifier: Topic :: Software Development :: Libraries
12
+ Project-URL: homepage, https://lief-project.github.io/
13
+ Project-URL: documentation, https://lief-project.github.io/doc/latest/
14
+ Project-URL: repository, https://github.com/lief-project/LIEF
15
+ Project-URL: changelog, https://lief-project.github.io/doc/latest/changelog.html
16
+ Project-URL: Funding, https://github.com/sponsors/lief-project
17
+ Project-URL: Tracker, https://github.com/lief-project/LIEF/issues
18
+ Requires-Python: >=3.8
19
+ Description-Content-Type: text/x-rst
20
+
21
+ About
22
+ =====
23
+
24
+ The purpose of this project is to provide a cross platform library that can parse, modify and
25
+ abstract ELF, PE and MachO formats.
26
+
27
+ Main features:
28
+
29
+ * **Parsing**: LIEF can parse ELF, PE, MachO, OAT, DEX, VDEX, ART and provides an user-friendly API to access to format internals.
30
+ * **Modify**: LIEF enables to modify some parts of these formats
31
+ * **Abstract**: Three formats have common features like sections, symbols, entry point... LIEF factors them.
32
+ * **API**: LIEF can be used in C, C++, Python and Rust
33
+
34
+ LIEF Extended:
35
+
36
+ * DWARF/PDB Support
37
+ * Objective-C Metadata
38
+ * dyld shared cache
39
+
40
+ Checkout: https://lief.re/doc/latest/extended/intro.html for the details
41
+
42
+ Getting Started
43
+ ================
44
+
45
+ .. code-block:: console
46
+
47
+ $ pip install lief
48
+
49
+ .. code-block:: python
50
+
51
+ import lief
52
+
53
+ elf = lief.ELF.parse("/bin/ls")
54
+ for section in elf.sections:
55
+ print(section.name, len(section.content))
56
+
57
+ pe = lief.PE.parse("cmd.exe")
58
+ for imp in pe.imports:
59
+ print(imp.name)
60
+
61
+ fat = lief.MachO.parse("/bin/dyld")
62
+ for macho in fat:
63
+ for sym in macho.symbols:
64
+ print(sym)
65
+
66
+ Documentation
67
+ =============
68
+
69
+ * `Main documentation <https://lief.re/doc/latest/index.html>`_
70
+ * `API <https://lief.re/doc/latest/api/python/index.html>`_
71
+
72
+ Contact
73
+ =======
74
+
75
+ * **Mail**: contact at lief.re
76
+ * **Discord**: `LIEF <https://discord.gg/jGQtyAYChJ>`_
77
+
78
+ Authors
79
+ =======
80
+
81
+ Romain Thomas `@rh0main <https://x.com/rh0main>`_
82
+
83
+ ----
84
+
85
+ LIEF is provided under the `Apache 2.0 license <https://github.com/lief-project/LIEF/blob/0.15.1/LICENSE>`_
@@ -0,0 +1,33 @@
1
+ lief/ART/__init__.pyi,sha256=wcaWKcum8r6tBF6IHOrbIfNYuT8J53Lj4sFPUiCxaRw,1912
2
+ lief/Android/__init__.pyi,sha256=H01bnBakndPhjeV76KbniMaqCfOg6h06oMP3T-AcUrg,567
3
+ lief/DEX/__init__.pyi,sha256=hXt4zosga31XqX8qMyJDzRRcvE0T7t2eU00icErII5s,9783
4
+ lief/ELF/__init__.pyi,sha256=Oex62GWRsPz2bPCCoLY8grwqE7X4HlFwO9TsIqnTKYQ,98341
5
+ lief/MachO/__init__.pyi,sha256=kne_34xkjldhoo9c_47cEssEA519WKyE1yvsDTyj4e4,54873
6
+ lief/OAT/__init__.pyi,sha256=eKZOFvGBYwIR-drcQo3XE53LEZFBcWHO5CaAMbBYGeg,6845
7
+ lief/PE/__init__.pyi,sha256=kwmd9BtUOBSi1KpM--cBJ3zhAsstVv0BGS4sRsqKklc,70293
8
+ lief/VDEX/__init__.pyi,sha256=4qH3jj0b7WDiWrdM9PqdTIt8hEftcfQJust55L0ofjA,1133
9
+ lief/__init__.py,sha256=sOMCNwqJ22NGeTiw6U8ZGdU974xKMcPJeVrqw_IuAFo,643
10
+ lief/__init__.pyi,sha256=7PQ_GxS0gx1mp_HnrV_6eJDS8NycgTzcgSwFm8O-E6c,11122
11
+ lief/_lief.so,sha256=W4pBm0y1lrxsaWViJCqIKaEnqDxgrlXMGXigSL1lKd0,9137296
12
+ lief/assembly/__init__.pyi,sha256=9lEo2ZtNqce4cdVzkV1_mQ3P2PFGbMwBchjFFIe3gl0,1914
13
+ lief/assembly/aarch64/__init__.pyi,sha256=5ZgBsf4rjAH4n40GOaHDIkGC8CLVZ5_s_1Wlnp9pOhY,250909
14
+ lief/assembly/aarch64/operands/__init__.pyi,sha256=5bBLVZlgVYC9kFhYHICw0vvzvcAWKD7RVDupIlXKZD4,1019
15
+ lief/assembly/arm/__init__.pyi,sha256=lQ9V6J2ExKNC7iKKB5GBPQinjYK-5gG7snxbPLmv27M,108148
16
+ lief/assembly/ebpf/__init__.pyi,sha256=7YpNeTioVhmI7yRei0hEiR7AxaYqXOJJhECmbXQoGD8,10781
17
+ lief/assembly/mips/__init__.pyi,sha256=hV9qFxLW71mbaz-rPrKYGPxGf9h_1LTask1JEhfFsOw,63719
18
+ lief/assembly/powerpc/__init__.pyi,sha256=1lTlXrHAGJAwAC7sawErWoafSnSoz0iS0RQnOoIx3M0,59827
19
+ lief/assembly/riscv/__init__.pyi,sha256=1U5wTzboVa1lPS7wYE3MAxn7Tfn2kImROyf2apsFEXI,491259
20
+ lief/assembly/x86/__init__.pyi,sha256=ziUTbPDjF0fFp6nP5g6uFQhNWxlMIrcCkX7hGCxj2V8,537269
21
+ lief/assembly/x86/operands/__init__.pyi,sha256=eTJFLYTL4KJaFXslpxJHTEqjpeAeY1CY5RBsSb-LPRw,720
22
+ lief/dsc/__init__.pyi,sha256=YBNEJfg-3nSypc4dHfZvquzjRkGbi2QdYcIqatt4LzY,4162
23
+ lief/dwarf/__init__.pyi,sha256=o-h98w8pTJB7W5EkTL-Fyc2hAs14bxJIu-z-XJRCboY,5342
24
+ lief/dwarf/parameters/__init__.pyi,sha256=YhxhncJ50xFEHBw2KRby9W-03Bg1ik0QnvKAW8TmaHw,274
25
+ lief/dwarf/types/__init__.pyi,sha256=s355OsV05G3CLGVYoEwMhwNVN5iHsI5YCOGnRvX6BMA,3525
26
+ lief/logging/__init__.pyi,sha256=t4zzsGm3YMxftAFFlIc7Q_tPJOaCh2AYvsAjmDZuy6o,626
27
+ lief/objc/__init__.pyi,sha256=qQKrV5tj-sjXw-uRO3hLq8w6o-qpldXUEdWGeEiy-9E,1854
28
+ lief/pdb/__init__.pyi,sha256=qbn8HYU4_qJfCa849ZL_oQIOcTUNdVgJ5-HgaYiyhuk,1849
29
+ lief/pdb/types/__init__.pyi,sha256=YcQvpRNCxwVEMXAbDvQdbF-_EacqyUc6TwfmcFiPOdY,1198
30
+ lief/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
31
+ lief-0.16.7.dist-info/METADATA,sha256=RP9fDZ8rS7nZy9CpWnBtPitBREwIbXZlJLzdyhLsusw,2423
32
+ lief-0.16.7.dist-info/WHEEL,sha256=mZLaY1lDx4maY_4rVz8T1v5CXObwVmA_3NtCQq7De3c,117
33
+ lief-0.16.7.dist-info/RECORD,,
@@ -0,0 +1,5 @@
1
+ Wheel-Version: 1.0
2
+ Generator: scikit-build-core 0.11.1
3
+ Root-Is-Purelib: false
4
+ Tag: cp314-cp314-musllinux_1_2_x86_64
5
+