lief 0.17.2__cp312-cp312-manylinux2014_aarch64.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.
- lief/ART/__init__.pyi +102 -0
- lief/Android/__init__.pyi +33 -0
- lief/COFF/__init__.pyi +708 -0
- lief/DEX/__init__.pyi +518 -0
- lief/ELF/__init__.pyi +5801 -0
- lief/MachO/__init__.pyi +3098 -0
- lief/OAT/__init__.pyi +351 -0
- lief/PE/__init__.pyi +4710 -0
- lief/PE/unwind_aarch64/__init__.pyi +58 -0
- lief/PE/unwind_x64/__init__.pyi +53 -0
- lief/VDEX/__init__.pyi +56 -0
- lief/__init__.py +16 -0
- lief/__init__.pyi +600 -0
- lief/_lief.so +0 -0
- lief/assembly/__init__.pyi +121 -0
- lief/assembly/aarch64/__init__.pyi +22326 -0
- lief/assembly/aarch64/operands/__init__.pyi +48 -0
- lief/assembly/arm/__init__.pyi +9034 -0
- lief/assembly/ebpf/__init__.pyi +1038 -0
- lief/assembly/mips/__init__.pyi +5836 -0
- lief/assembly/powerpc/__init__.pyi +5826 -0
- lief/assembly/riscv/__init__.pyi +28636 -0
- lief/assembly/x86/__init__.pyi +45477 -0
- lief/assembly/x86/operands/__init__.pyi +32 -0
- lief/dsc/__init__.pyi +226 -0
- lief/dwarf/__init__.pyi +306 -0
- lief/dwarf/editor/__init__.pyi +138 -0
- lief/dwarf/parameters/__init__.pyi +14 -0
- lief/dwarf/types/__init__.pyi +167 -0
- lief/logging/__init__.pyi +44 -0
- lief/objc/__init__.pyi +89 -0
- lief/pdb/__init__.pyi +336 -0
- lief/pdb/types/__init__.pyi +69 -0
- lief/py.typed +0 -0
- lief-0.17.2.dist-info/METADATA +85 -0
- lief-0.17.2.dist-info/RECORD +37 -0
- lief-0.17.2.dist-info/WHEEL +5 -0
lief/DEX/__init__.pyi
ADDED
|
@@ -0,0 +1,518 @@
|
|
|
1
|
+
from collections.abc import Sequence
|
|
2
|
+
import enum
|
|
3
|
+
import io
|
|
4
|
+
import os
|
|
5
|
+
from typing import Iterator, Optional, Union, overload
|
|
6
|
+
|
|
7
|
+
import lief
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class ACCESS_FLAGS(enum.Enum):
|
|
11
|
+
UNKNOWN = 0
|
|
12
|
+
|
|
13
|
+
PUBLIC = 1
|
|
14
|
+
|
|
15
|
+
PRIVATE = 2
|
|
16
|
+
|
|
17
|
+
PROTECTED = 4
|
|
18
|
+
|
|
19
|
+
STATIC = 8
|
|
20
|
+
|
|
21
|
+
FINAL = 16
|
|
22
|
+
|
|
23
|
+
SYNCHRONIZED = 32
|
|
24
|
+
|
|
25
|
+
VOLATILE = 64
|
|
26
|
+
|
|
27
|
+
BRIDGE = 64
|
|
28
|
+
|
|
29
|
+
TRANSIENT = 128
|
|
30
|
+
|
|
31
|
+
VARARGS = 128
|
|
32
|
+
|
|
33
|
+
NATIVE = 256
|
|
34
|
+
|
|
35
|
+
INTERFACE = 512
|
|
36
|
+
|
|
37
|
+
ABSTRACT = 1024
|
|
38
|
+
|
|
39
|
+
STRICT = 2048
|
|
40
|
+
|
|
41
|
+
SYNTHETIC = 4096
|
|
42
|
+
|
|
43
|
+
ANNOTATION = 8192
|
|
44
|
+
|
|
45
|
+
ENUM = 16384
|
|
46
|
+
|
|
47
|
+
CONSTRUCTOR = 65536
|
|
48
|
+
|
|
49
|
+
DECLARED_SYNCHRONIZED = 131072
|
|
50
|
+
|
|
51
|
+
@overload
|
|
52
|
+
def parse(filename: str) -> Optional[File]: ...
|
|
53
|
+
|
|
54
|
+
@overload
|
|
55
|
+
def parse(raw: Sequence[int], name: str = '') -> Optional[File]: ...
|
|
56
|
+
|
|
57
|
+
@overload
|
|
58
|
+
def parse(obj: Union[str | io.IOBase | os.PathLike | bytes | list[int]], name: str = '') -> Optional[File]: ...
|
|
59
|
+
|
|
60
|
+
class File(lief.Object):
|
|
61
|
+
class it_classes:
|
|
62
|
+
def __getitem__(self, arg: int, /) -> Class: ...
|
|
63
|
+
|
|
64
|
+
def __len__(self) -> int: ...
|
|
65
|
+
|
|
66
|
+
def __iter__(self) -> File.it_classes: ...
|
|
67
|
+
|
|
68
|
+
def __next__(self) -> Class: ...
|
|
69
|
+
|
|
70
|
+
class it_methods:
|
|
71
|
+
def __getitem__(self, arg: int, /) -> Method: ...
|
|
72
|
+
|
|
73
|
+
def __len__(self) -> int: ...
|
|
74
|
+
|
|
75
|
+
def __iter__(self) -> File.it_methods: ...
|
|
76
|
+
|
|
77
|
+
def __next__(self) -> Method: ...
|
|
78
|
+
|
|
79
|
+
class it_strings:
|
|
80
|
+
def __getitem__(self, arg: int, /) -> str: ...
|
|
81
|
+
|
|
82
|
+
def __len__(self) -> int: ...
|
|
83
|
+
|
|
84
|
+
def __iter__(self) -> File.it_strings: ...
|
|
85
|
+
|
|
86
|
+
def __next__(self) -> str: ...
|
|
87
|
+
|
|
88
|
+
class it_types:
|
|
89
|
+
def __getitem__(self, arg: int, /) -> Type: ...
|
|
90
|
+
|
|
91
|
+
def __len__(self) -> int: ...
|
|
92
|
+
|
|
93
|
+
def __iter__(self) -> File.it_types: ...
|
|
94
|
+
|
|
95
|
+
def __next__(self) -> Type: ...
|
|
96
|
+
|
|
97
|
+
class it_prototypes:
|
|
98
|
+
def __getitem__(self, arg: int, /) -> Prototype: ...
|
|
99
|
+
|
|
100
|
+
def __len__(self) -> int: ...
|
|
101
|
+
|
|
102
|
+
def __iter__(self) -> File.it_prototypes: ...
|
|
103
|
+
|
|
104
|
+
def __next__(self) -> Prototype: ...
|
|
105
|
+
|
|
106
|
+
class it_fields:
|
|
107
|
+
def __getitem__(self, arg: int, /) -> Field: ...
|
|
108
|
+
|
|
109
|
+
def __len__(self) -> int: ...
|
|
110
|
+
|
|
111
|
+
def __iter__(self) -> File.it_fields: ...
|
|
112
|
+
|
|
113
|
+
def __next__(self) -> Field: ...
|
|
114
|
+
|
|
115
|
+
@property
|
|
116
|
+
def version(self) -> int: ...
|
|
117
|
+
|
|
118
|
+
@property
|
|
119
|
+
def header(self) -> Header: ...
|
|
120
|
+
|
|
121
|
+
@property
|
|
122
|
+
def classes(self) -> File.it_classes: ...
|
|
123
|
+
|
|
124
|
+
def has_class(self, classname: str) -> bool: ...
|
|
125
|
+
|
|
126
|
+
@overload
|
|
127
|
+
def get_class(self, classname: str) -> Class: ...
|
|
128
|
+
|
|
129
|
+
@overload
|
|
130
|
+
def get_class(self, classname: int) -> Class: ...
|
|
131
|
+
|
|
132
|
+
@property
|
|
133
|
+
def methods(self) -> File.it_methods: ...
|
|
134
|
+
|
|
135
|
+
@property
|
|
136
|
+
def fields(self) -> File.it_fields: ...
|
|
137
|
+
|
|
138
|
+
@property
|
|
139
|
+
def strings(self) -> File.it_strings: ...
|
|
140
|
+
|
|
141
|
+
@property
|
|
142
|
+
def types(self) -> File.it_types: ...
|
|
143
|
+
|
|
144
|
+
@property
|
|
145
|
+
def prototypes(self) -> File.it_prototypes: ...
|
|
146
|
+
|
|
147
|
+
@property
|
|
148
|
+
def map(self) -> MapList: ...
|
|
149
|
+
|
|
150
|
+
def raw(self, deoptimize: bool = True) -> list[int]: ...
|
|
151
|
+
|
|
152
|
+
name: str
|
|
153
|
+
|
|
154
|
+
location: str
|
|
155
|
+
|
|
156
|
+
@property
|
|
157
|
+
def dex2dex_json_info(self) -> str: ...
|
|
158
|
+
|
|
159
|
+
def save(self, output: str = '', deoptimize: bool = True) -> str: ...
|
|
160
|
+
|
|
161
|
+
def __str__(self) -> str: ...
|
|
162
|
+
|
|
163
|
+
class Header(lief.Object):
|
|
164
|
+
@property
|
|
165
|
+
def magic(self) -> list[int]: ...
|
|
166
|
+
|
|
167
|
+
@property
|
|
168
|
+
def checksum(self) -> int: ...
|
|
169
|
+
|
|
170
|
+
@property
|
|
171
|
+
def signature(self) -> list[int]: ...
|
|
172
|
+
|
|
173
|
+
@property
|
|
174
|
+
def file_size(self) -> int: ...
|
|
175
|
+
|
|
176
|
+
@property
|
|
177
|
+
def header_size(self) -> int: ...
|
|
178
|
+
|
|
179
|
+
@property
|
|
180
|
+
def endian_tag(self) -> int: ...
|
|
181
|
+
|
|
182
|
+
@property
|
|
183
|
+
def map_offset(self) -> int: ...
|
|
184
|
+
|
|
185
|
+
@property
|
|
186
|
+
def strings(self) -> tuple[int, int]: ...
|
|
187
|
+
|
|
188
|
+
@property
|
|
189
|
+
def link(self) -> tuple[int, int]: ...
|
|
190
|
+
|
|
191
|
+
@property
|
|
192
|
+
def types(self) -> tuple[int, int]: ...
|
|
193
|
+
|
|
194
|
+
@property
|
|
195
|
+
def prototypes(self) -> tuple[int, int]: ...
|
|
196
|
+
|
|
197
|
+
@property
|
|
198
|
+
def fields(self) -> tuple[int, int]: ...
|
|
199
|
+
|
|
200
|
+
@property
|
|
201
|
+
def methods(self) -> tuple[int, int]: ...
|
|
202
|
+
|
|
203
|
+
@property
|
|
204
|
+
def classes(self) -> tuple[int, int]: ...
|
|
205
|
+
|
|
206
|
+
@property
|
|
207
|
+
def data(self) -> tuple[int, int]: ...
|
|
208
|
+
|
|
209
|
+
@property
|
|
210
|
+
def nb_classes(self) -> int: ...
|
|
211
|
+
|
|
212
|
+
@property
|
|
213
|
+
def nb_methods(self) -> int: ...
|
|
214
|
+
|
|
215
|
+
def __str__(self) -> str: ...
|
|
216
|
+
|
|
217
|
+
class Class(lief.Object):
|
|
218
|
+
class it_methods:
|
|
219
|
+
def __getitem__(self, arg: int, /) -> Method: ...
|
|
220
|
+
|
|
221
|
+
def __len__(self) -> int: ...
|
|
222
|
+
|
|
223
|
+
def __iter__(self) -> Class.it_methods: ...
|
|
224
|
+
|
|
225
|
+
def __next__(self) -> Method: ...
|
|
226
|
+
|
|
227
|
+
class it_fields:
|
|
228
|
+
def __getitem__(self, arg: int, /) -> Field: ...
|
|
229
|
+
|
|
230
|
+
def __len__(self) -> int: ...
|
|
231
|
+
|
|
232
|
+
def __iter__(self) -> Class.it_fields: ...
|
|
233
|
+
|
|
234
|
+
def __next__(self) -> Field: ...
|
|
235
|
+
|
|
236
|
+
class it_named_methods:
|
|
237
|
+
def __getitem__(self, arg: int, /) -> Method: ...
|
|
238
|
+
|
|
239
|
+
def __len__(self) -> int: ...
|
|
240
|
+
|
|
241
|
+
def __iter__(self) -> Class.it_named_methods: ...
|
|
242
|
+
|
|
243
|
+
def __next__(self) -> Method: ...
|
|
244
|
+
|
|
245
|
+
class it_named_fields:
|
|
246
|
+
def __getitem__(self, arg: int, /) -> Field: ...
|
|
247
|
+
|
|
248
|
+
def __len__(self) -> int: ...
|
|
249
|
+
|
|
250
|
+
def __iter__(self) -> Class.it_named_fields: ...
|
|
251
|
+
|
|
252
|
+
def __next__(self) -> Field: ...
|
|
253
|
+
|
|
254
|
+
@property
|
|
255
|
+
def fullname(self) -> str: ...
|
|
256
|
+
|
|
257
|
+
@property
|
|
258
|
+
def pretty_name(self) -> str: ...
|
|
259
|
+
|
|
260
|
+
@property
|
|
261
|
+
def name(self) -> str: ...
|
|
262
|
+
|
|
263
|
+
@property
|
|
264
|
+
def source_filename(self) -> str: ...
|
|
265
|
+
|
|
266
|
+
@property
|
|
267
|
+
def package_name(self) -> str: ...
|
|
268
|
+
|
|
269
|
+
@property
|
|
270
|
+
def has_parent(self) -> bool: ...
|
|
271
|
+
|
|
272
|
+
@property
|
|
273
|
+
def parent(self) -> Class: ...
|
|
274
|
+
|
|
275
|
+
@property
|
|
276
|
+
def methods(self) -> Class.it_methods: ...
|
|
277
|
+
|
|
278
|
+
def get_method(self, name: str) -> Class.it_named_methods: ...
|
|
279
|
+
|
|
280
|
+
@property
|
|
281
|
+
def fields(self) -> Class.it_fields: ...
|
|
282
|
+
|
|
283
|
+
def get_field(self, name: str) -> Class.it_named_fields: ...
|
|
284
|
+
|
|
285
|
+
@property
|
|
286
|
+
def access_flags(self) -> list[ACCESS_FLAGS]: ...
|
|
287
|
+
|
|
288
|
+
@property
|
|
289
|
+
def dex2dex_info(self) -> dict[Method, dict[int, int]]: ...
|
|
290
|
+
|
|
291
|
+
@property
|
|
292
|
+
def index(self) -> int: ...
|
|
293
|
+
|
|
294
|
+
def has(self, flag: ACCESS_FLAGS) -> bool: ...
|
|
295
|
+
|
|
296
|
+
def __str__(self) -> str: ...
|
|
297
|
+
|
|
298
|
+
class Method(lief.Object):
|
|
299
|
+
@property
|
|
300
|
+
def name(self) -> str: ...
|
|
301
|
+
|
|
302
|
+
@property
|
|
303
|
+
def index(self) -> int: ...
|
|
304
|
+
|
|
305
|
+
@property
|
|
306
|
+
def has_class(self) -> bool: ...
|
|
307
|
+
|
|
308
|
+
@property
|
|
309
|
+
def cls(self) -> Class: ...
|
|
310
|
+
|
|
311
|
+
@property
|
|
312
|
+
def code_offset(self) -> int: ...
|
|
313
|
+
|
|
314
|
+
@property
|
|
315
|
+
def bytecode(self) -> list[int]: ...
|
|
316
|
+
|
|
317
|
+
@property
|
|
318
|
+
def is_virtual(self) -> bool: ...
|
|
319
|
+
|
|
320
|
+
@property
|
|
321
|
+
def prototype(self) -> Prototype: ...
|
|
322
|
+
|
|
323
|
+
@property
|
|
324
|
+
def access_flags(self) -> list[ACCESS_FLAGS]: ...
|
|
325
|
+
|
|
326
|
+
def has(self, flag: ACCESS_FLAGS) -> bool: ...
|
|
327
|
+
|
|
328
|
+
def insert_dex2dex_info(self, pc: int, index: int) -> None: ...
|
|
329
|
+
|
|
330
|
+
@property
|
|
331
|
+
def code_info(self) -> CodeInfo: ...
|
|
332
|
+
|
|
333
|
+
def __str__(self) -> str: ...
|
|
334
|
+
|
|
335
|
+
class Field(lief.Object):
|
|
336
|
+
@property
|
|
337
|
+
def name(self) -> str: ...
|
|
338
|
+
|
|
339
|
+
@property
|
|
340
|
+
def index(self) -> int: ...
|
|
341
|
+
|
|
342
|
+
@property
|
|
343
|
+
def has_class(self) -> bool: ...
|
|
344
|
+
|
|
345
|
+
@property
|
|
346
|
+
def cls(self) -> Class: ...
|
|
347
|
+
|
|
348
|
+
@property
|
|
349
|
+
def is_static(self) -> bool: ...
|
|
350
|
+
|
|
351
|
+
@property
|
|
352
|
+
def type(self) -> Type: ...
|
|
353
|
+
|
|
354
|
+
@property
|
|
355
|
+
def access_flags(self) -> list[ACCESS_FLAGS]: ...
|
|
356
|
+
|
|
357
|
+
def has(self, flag: ACCESS_FLAGS) -> bool: ...
|
|
358
|
+
|
|
359
|
+
def __str__(self) -> str: ...
|
|
360
|
+
|
|
361
|
+
class Prototype(lief.Object):
|
|
362
|
+
class it_params:
|
|
363
|
+
def __getitem__(self, arg: int, /) -> Type: ...
|
|
364
|
+
|
|
365
|
+
def __len__(self) -> int: ...
|
|
366
|
+
|
|
367
|
+
def __iter__(self) -> Prototype.it_params: ...
|
|
368
|
+
|
|
369
|
+
def __next__(self) -> Type: ...
|
|
370
|
+
|
|
371
|
+
@property
|
|
372
|
+
def return_type(self) -> Type: ...
|
|
373
|
+
|
|
374
|
+
@property
|
|
375
|
+
def parameters_type(self) -> Prototype.it_params: ...
|
|
376
|
+
|
|
377
|
+
def __str__(self) -> str: ...
|
|
378
|
+
|
|
379
|
+
class Type(lief.Object):
|
|
380
|
+
class TYPES(enum.Enum):
|
|
381
|
+
UNKNOWN = 0
|
|
382
|
+
|
|
383
|
+
ARRAY = 3
|
|
384
|
+
|
|
385
|
+
PRIMITIVE = 1
|
|
386
|
+
|
|
387
|
+
CLASS = 2
|
|
388
|
+
|
|
389
|
+
class PRIMITIVES(enum.Enum):
|
|
390
|
+
VOID_T = 1
|
|
391
|
+
|
|
392
|
+
BOOLEAN = 2
|
|
393
|
+
|
|
394
|
+
BYTE = 3
|
|
395
|
+
|
|
396
|
+
SHORT = 4
|
|
397
|
+
|
|
398
|
+
CHAR = 5
|
|
399
|
+
|
|
400
|
+
INT = 6
|
|
401
|
+
|
|
402
|
+
LONG = 7
|
|
403
|
+
|
|
404
|
+
FLOAT = 8
|
|
405
|
+
|
|
406
|
+
DOUBLE = 9
|
|
407
|
+
|
|
408
|
+
@property
|
|
409
|
+
def type(self) -> Type.TYPES: ...
|
|
410
|
+
|
|
411
|
+
@property
|
|
412
|
+
def value(self) -> object: ...
|
|
413
|
+
|
|
414
|
+
@property
|
|
415
|
+
def dim(self) -> int: ...
|
|
416
|
+
|
|
417
|
+
@property
|
|
418
|
+
def underlying_array_type(self) -> Type: ...
|
|
419
|
+
|
|
420
|
+
@staticmethod
|
|
421
|
+
def pretty_name(primitive: Type.PRIMITIVES) -> str: ...
|
|
422
|
+
|
|
423
|
+
def __str__(self) -> str: ...
|
|
424
|
+
|
|
425
|
+
class MapList(lief.Object):
|
|
426
|
+
class it_items_t:
|
|
427
|
+
def __getitem__(self, arg: int, /) -> MapItem: ...
|
|
428
|
+
|
|
429
|
+
def __len__(self) -> int: ...
|
|
430
|
+
|
|
431
|
+
def __iter__(self) -> MapList.it_items_t: ...
|
|
432
|
+
|
|
433
|
+
def __next__(self) -> MapItem: ...
|
|
434
|
+
|
|
435
|
+
@property
|
|
436
|
+
def items(self) -> MapList.it_items_t: ...
|
|
437
|
+
|
|
438
|
+
def has(self, type: MapItem.TYPES) -> bool: ...
|
|
439
|
+
|
|
440
|
+
def get(self, type: MapItem.TYPES) -> MapItem: ...
|
|
441
|
+
|
|
442
|
+
def __getitem__(self, arg: MapItem.TYPES, /) -> MapItem: ...
|
|
443
|
+
|
|
444
|
+
def __str__(self) -> str: ...
|
|
445
|
+
|
|
446
|
+
class MapItem(lief.Object):
|
|
447
|
+
class TYPES(enum.Enum):
|
|
448
|
+
@staticmethod
|
|
449
|
+
def from_value(arg: int, /) -> MapItem.TYPES: ...
|
|
450
|
+
|
|
451
|
+
def __eq__(self, arg, /) -> bool: ...
|
|
452
|
+
|
|
453
|
+
def __ne__(self, arg, /) -> bool: ...
|
|
454
|
+
|
|
455
|
+
def __int__(self) -> int: ...
|
|
456
|
+
|
|
457
|
+
HEADER = 0
|
|
458
|
+
|
|
459
|
+
STRING_ID = 1
|
|
460
|
+
|
|
461
|
+
TYPE_ID = 2
|
|
462
|
+
|
|
463
|
+
PROTO_ID = 3
|
|
464
|
+
|
|
465
|
+
FIELD_ID = 4
|
|
466
|
+
|
|
467
|
+
METHOD_ID = 5
|
|
468
|
+
|
|
469
|
+
CLASS_DEF = 6
|
|
470
|
+
|
|
471
|
+
CALL_SITE_ID = 7
|
|
472
|
+
|
|
473
|
+
METHOD_HANDLE = 8
|
|
474
|
+
|
|
475
|
+
MAP_LIST = 4096
|
|
476
|
+
|
|
477
|
+
TYPE_LIST = 4097
|
|
478
|
+
|
|
479
|
+
ANNOTATION_SET_REF_LIST = 4098
|
|
480
|
+
|
|
481
|
+
ANNOTATION_SET = 4099
|
|
482
|
+
|
|
483
|
+
CLASS_DATA = 8192
|
|
484
|
+
|
|
485
|
+
CODE = 8193
|
|
486
|
+
|
|
487
|
+
STRING_DATA = 8194
|
|
488
|
+
|
|
489
|
+
DEBUG_INFO = 8195
|
|
490
|
+
|
|
491
|
+
ANNOTATION = 8196
|
|
492
|
+
|
|
493
|
+
ENCODED_ARRAY = 8197
|
|
494
|
+
|
|
495
|
+
ANNOTATIONS_DIRECTORY = 8198
|
|
496
|
+
|
|
497
|
+
@property
|
|
498
|
+
def type(self) -> MapItem.TYPES: ...
|
|
499
|
+
|
|
500
|
+
@property
|
|
501
|
+
def offset(self) -> int: ...
|
|
502
|
+
|
|
503
|
+
@property
|
|
504
|
+
def size(self) -> int: ...
|
|
505
|
+
|
|
506
|
+
def __str__(self) -> str: ...
|
|
507
|
+
|
|
508
|
+
class CodeInfo(lief.Object):
|
|
509
|
+
@property
|
|
510
|
+
def nb_registers(self) -> int: ...
|
|
511
|
+
|
|
512
|
+
def __str__(self) -> str: ...
|
|
513
|
+
|
|
514
|
+
@overload
|
|
515
|
+
def version(file: str) -> int: ...
|
|
516
|
+
|
|
517
|
+
@overload
|
|
518
|
+
def version(raw: Sequence[int]) -> int: ...
|