Pre-built packages from the [master](https://github.com/lief-project/LIEF/tree/master)'s **latest commit** are automatically uploaded in the [*lief-project/packages*](https://github.com/lief-project/packages) repository:
44
44
45
-
:warning: *master* **SDK** packages have a same name as *tagged* packages (e.g. ``LIEF-0.7.0-Linux.tar.gz``) :warning:
45
+
:warning: *master* **SDK** packages have a same name as *tagged* packages (e.g. ``LIEF-0.8.0-Linux.tar.gz``) :warning:
46
46
47
-
:warning: *master* **Python** package has ``dev`` suffix (e.g. ``pylief-0.7.0.dev.zip``) :warning:
47
+
:warning: *master* **Python** package has ``dev`` suffix (e.g. ``pylief-0.8.0.dev.zip``) :warning:
LIEF 0.8.0 mainly improves the MachO parser and the ELF builder. It comes with `Dockerfiles <https://github.com/lief-project/Dockerlief>`_ for `CentOS <https://github.com/lief-project/Dockerlief/blob/v0.1.0/dockerlief/dockerfiles/centos.docker>`_ and `Android <https://github.com/lief-project/Dockerlief/blob/v0.1.0/dockerlief/dockerfiles/android.docker>`_.
8
+
9
+
`LibFuzzer <https://llvm.org/docs/LibFuzzer.html>`_ has also been integrated in the project to enhance the parsers
10
+
6
11
7
12
Features
8
13
********
skipped 1 lines
10
15
11
16
:Abstract Layer:
12
17
13
-
* :class:`~lief.Relocation` are now abstracted from the 3 formats.
18
+
* :class:`~lief.Relocation` are now abstracted from the 3 formats-:commit:`9503f2fc7b6c14bebd4c220bda4a243d87f14bd1`
14
19
* ``PIE`` and ``NX`` are abstracted through the :attr:`~lief.Binary.is_pie` and :attr:`~lief.Binary.has_nx` properties
20
+
* Add the :meth:`lief.Section.search` and :meth:`lief.Section.search_all` methods to look for patterns in the section's content.
15
21
16
22
:ELF:
17
23
18
-
* DT_FLAGS and DT_FLAGS_1
24
+
* ``DT_FLAGS`` and ``DT_FLAGS_1`` are now parsed into :class:`~lief.ELF.DynamicEntryFlags` - :commit:`754b8afa2b41993e6c37d2d9003cebdccc641d23`
25
+
* Handle relocations of object files (``.o``) - :commit:`483b8dc2eabee3da29ce5e5ff2e25c2a3c9ca297`
26
+
27
+
* Global enhancement of the ELF builder:
28
+
29
+
One can now add **multiple** :class:`~lief.ELF.Section` or :class:`~lief.ELF.Segment` into an ELF:
* Section relocations are now parsed into :attr:`lief.MachO.Section.relocations` - :commit:`29c8157ecc3b308bd521cb1daee3c2e3a2cffb28`
205
+
* ``LC_FUNCTION_STARTS`` is parsed into :class:`~lief.MachO.FunctionStarts` (:commit:`18d89198a0cc63ff291ae9110f465354c3b8f1e6`)
34
206
* ``LC_SOURCE_VERSION``, ``LC_VERSION_MIN_MACOSX`` and ``LC_VERSION_MIN_IPHONEOS`` are
35
-
parsed into :class:`~lief.MachO.SourceVersion` and :class:`~lief.MachO.VersionMin`
207
+
parsed into :class:`~lief.MachO.SourceVersion` and :class:`~lief.MachO.VersionMin` (:commit:`c359778194db874669884aaccb52a4b05546bc07`, :commit:`0b4bb7d56520cd0ea08bbcb9530e5e0c96ac14ae`, :commit:`5b993117ed391db18ba775cabefa5f3981b2f1cc`, :issue:`45`)
208
+
* ``LC_THREAD`` and ``LC_UNIXTHREAD`` are now parsed into :class:`~lief.MachO.ThreadCommand` - :commit:`23257830b291c40a3aed92360040f2b0b11ffa72`
Fix most of the memory leaks: :commit:`88dafa8db6e752393f69d73f68d295e91963b8da`, :commit:`d9b1436730b5d33a753e7dfa4301697a0c676066`, :commit:`554fa153af943b97a16fc4a52ab8459a3d0a9bc7`, :commit:`3602643f5d02a1c78c4de609cc47f193f3a8840f`
42
217
43
218
:ELF:
44
219
220
+
* Bug Fix when counting dynamic symbols from the GnuHash Table - :commit:`9036a2405dc44726f40cb77cab1bcbf371ab7a70`
* Fix memory leaks and *some* performance issues: :issue:`94`
54
232
55
233
56
234
235
+
57
236
API
58
237
***
59
238
60
-
Logger --> configuration
239
+
In the C++ API ``get_XXX()`` getters have been renamed into ``XXX()`` (e.g. ``get_header()`` becomes ``header()``) - :commit:`a4c69f7868da1de5d09aa26e977dedb720e36cbd`, :commit:`e805669865b130057413f456958a471d8f0ac0b1`
61
240
62
241
:Abstract:
63
242
64
-
* parser can take a list of integer
243
+
* :class:`lief.Binary` gains the :attr:`~lief.Binary.format` property - :commit:`9391238f114fe963890777c2d8b90f2caaa5510c`
244
+
* :func:`lief.parse` can now takes a list of integers - :commit:`f330fa887d14d47f0683144430ac9695d3136561`
245
+
* Add :meth:`~lief.Binary.has_symbol` and :meth:`~lief.Binary.get_symbol` to :class:`lief.Binary` - :commit:`f121af5ca61a22fd83acc5c7094b50ed1cda8226`
246
+
* [Python API] Enhance the access to the abstract layer through the :attr:`~lief.Binary.abstract` attribute - :commit:`07138549a46db87c7b924fd072356030b1d5c6bc`
247
+
248
+
One can now do:
249
+
250
+
.. code-block:: python
251
+
252
+
elf = lief.ELF.parse("/bin/ls") # Could be lief.MachO / lief.PE
253
+
abstract = elf.abstract # Return the lief.Binary object
254
+
65
255
66
256
:ELF:
67
257
68
-
* Relocation gains the :attr:`~lief.ELF.Relocation.purpose` property - `b7b0bde<https://github.com/lief-project/LIEF/commit/b7b0bde4d51c54d8d226e5320b1b0d2cc48137c4>`_
* Relocation gains the :attr:`~lief.ELF.Relocation.purpose` property - :commit:`b7b0bde4d51c54d8d226e5320b1b0d2cc48137c4`
259
+
* Add :attr:`lief.ELF.Binary.symbols` which return an iterator over **all** symbols (static and dynamic) - :commit:`af6ab65dc91169627f4fbb87cda92093eb699a1e`
260
+
* ``Header.sizeof_section_header`` has been renamed into :attr:`~lief.ELF.Header.section_header_size` - :commit:`d96971b0c3f8ff50add349957f571b8daa00708a`
261
+
* ``Segment.flag`` has been renamed into :attr:`~lief.ELF.Segment.flags` - :commit:`20a5f666deb89b06b79a1c4418ac938497fb658c`
262
+
* Add:
263
+
264
+
* :attr:`~lief.ELF.Header.arm_flags_list`,
265
+
* :attr:`~lief.ELF.Header.mips_flags_list`
266
+
* :attr:`~lief.ELF.Header.ppc64_flags_list`
267
+
* :attr:`~lief.ELF.Header.hexagon_flags_list`
268
+
269
+
to :class:`~lief.ELF.Header` - :commit:`730d045e05dca7ef3cd6a51d1175f280be356c70`
270
+
271
+
To check if a given flag is set, one can do:
272
+
273
+
.. code-block:: python
274
+
275
+
>>> if lief.ELF.ARM_EFLAGS.EABI_VER5 in lief.ELF.Header "yes" else "no"
276
+
* [Python] Segment flags: ``PF_X``, ``PF_W``, ``PF_X`` has been renamed into :attr:`~lief.ELF.SEGMENT_FLAGS.X`, :attr:`~lief.ELF.SEGMENT_FLAGS.W`, :attr:`~lief.ELF.SEGMENT_FLAGS.X` - :commit:`d70ef9ec2c42619434352dbd7b74a835ebad7569`
* Enhancement for :attr:`~lief.ELF.DynamicEntryRpath` and :attr:`~lief.ELF.DynamicEntryRunPath`: :commit:`c375a47da7c4c524e886f9238f8dd51a44501087`
279
+
* Enhancement for :attr:`~lief.ELF.DynamicEntryArray`: :commit:`81440ce00cdfc793161a0dc394ada345307dc24b`
280
+
* Add some *operators* :commit:`3b200b30503847be4779447c76f5207d18daf77f`, :commit:`43bd06f8f32196454ee2305201f4e27b3a3c8a1e`
281
+
282
+
76
283
77
284
:PE:
78
-
79
-
* 5666351e07b7bf4a9624033f670d02b8806d2663
285
+
* Add some *operators* :commit:`5666351e07b7bf4a9624033f670d02b8806d2663`
80
286
81
287
:MachO:
82
288
83
-
* cbe835484751396daffe7f8d238cbb85d66470ab
289
+
* :func:`lief.MachO.parse` can now takes a list of integers - :commit:`f330fa887d14d47f0683144430ac9695d3136561`
290
+
* :func:`lief.MachO.parse` now returns a :class:`~lief.MachO.FatBinary` instead of a ``list`` of :class:`~lief.MachO.Binary`. :class:`~lief.MachO.FatBinary` has a similar API as a list - :commit:`3602643f5d02a1c78c4de609cc47f193f3a8840f`
291
+
* Add some *operators*: :commit:`cbe835484751396daffe7f8d238cbb85d66470ab`
84
292
85
-
TODO: Findlief.cmake
86
-
Make JSON related API optional
293
+
:Logging:
294
+
295
+
Add an API to configure the logger - :commit:`4600c2ba8d7d17b5965c2b74faeb7e4d2128de17`
* Parse PE Overlay - `e0634c1<https://github.com/lief-project/LIEF/commit/e0634c1cf6d12fbdc5bcc1745059005e46e5d805>`_
125
-
* Enable PE Hooking - `24f6b72<https://github.com/lief-project/LIEF/commit/24f6b7213647469e269ead9441d78204162d08ec>`_
126
-
* Parse and rebuilt dos stub - `3f06397<https://github.com/lief-project/LIEF/commit/3f0639712617007e2e0431cb5eeb9be204c5d74b>`_
127
-
* Add a *resources manager* to provide an enhanced API over the resources - `8473c8e<https://github.com/lief-project/LIEF/commit/8473c8e126f2a8f14728ad3f8ebb59c45ac55d2d>`_
128
-
* Serialize PE objects into JSON - `673f5a3<https://github.com/lief-project/LIEF/commit/673f5a36f0d339ad9390427292fa6e725b8fd907>`_, `#18<https://github.com/lief-project/LIEF/issues/18>`_
* Bug fix in the signature parser: `#30<https://github.com/lief-project/LIEF/issues/30>`_, `4af0256<https://github.com/lief-project/LIEF/commit/4af0256ce7c5577e0b1010c6f9b566634f0a3993>`_
141
-
* Bug fix in the resources parser: Infinite loop - `a569cc1<https://github.com/lief-project/LIEF/commit/a569cc13d99354ff96932460f5b1fd859378f252>`_
142
-
* Add more *out-of-bounds* checks on relocations and exports - `9364f64<https://github.com/lief-project/LIEF/commit/9364f644e937a6a5d69c64c2ef4eaa1fbdd2cfad>`_
143
-
* Use ``min(SizeOfRawData, VirtualSize)`` for the section's size and truncate the size to the file size - `61bf14b<https://github.com/lief-project/LIEF/commit/61bf14ba1182fe458453599ff014de5d71d25680>`_
373
+
* Bug fix in the signature parser: :issue:`30`, :commit:`4af0256ce7c5577e0b1010c6f9b566634f0a3993`
374
+
* Bug fix in the resources parser: Infinite loop - :commit:`a569cc13d99354ff96932460f5b1fd859378f252`
375
+
* Add more *out-of-bounds* checks on relocations and exports - :commit:`9364f644e937a6a5d69c64c2ef4eaa1fbdd2cfad`
376
+
* Use ``min(SizeOfRawData, VirtualSize)`` for the section's size and truncate the size to the file size - :commit:`61bf14ba1182fe458453599ff014de5d71d25680`
144
377
145
378
146
379
:MachO:
147
380
148
-
* Bug fix when a binary hasn't a ``LC_MAIN`` command - `957501f<https://github.com/lief-project/LIEF/commit/957501fe76596e0396c66d08540884876cea049c>`_
381
+
* Bug fix when a binary hasn't a ``LC_MAIN`` command - :commit:`957501fe76596e0396c66d08540884876cea049c`
* Hyrum Anderson who pointed bugs in the PE parser
274
507
* My collegues for the feedbacks and suggestions (Adrien, SebK, Pierrick)
275
508
skipped 5 lines
281
514
282
515
:ELF:
283
516
284
-
* Don't rely on :attr:`lief.ELF.Section.entry_size` to count symbols - `004c676<https://github.com/lief-project/LIEF/commit/004c6769bec37e303bbe7aaceb49f4b05c8eec84>`_
517
+
* Don't rely on :attr:`lief.ELF.Section.entry_size` to count symbols - :commit:`004c6769bec37e303bbe7aaceb49f4b05c8eec84`