Add changelog and bump to v0.8.0

This commit is contained in:
Romain Thomas 2017-10-14 21:16:32 +02:00
parent e8ac976c99
commit ef95d0ab69
9 changed files with 364 additions and 93 deletions

View File

@ -36,7 +36,7 @@ execute_process(
# LIEF version
set(LIEF_VERSION_MAJOR 0)
set(LIEF_VERSION_MINOR 7)
set(LIEF_VERSION_MINOR 8)
set(LIEF_VERSION_PATCH 0)
project(LIEF VERSION ${LIEF_VERSION_MAJOR}.${LIEF_VERSION_MINOR}.${LIEF_VERSION_PATCH})

View File

@ -20,7 +20,7 @@
</a>
&nbsp;
<a href="https://github.com/lief-project/LIEF/releases">
<img src="https://img.shields.io/badge/release-0.7.0-brightgreen.svg?style=default">
<img src="https://img.shields.io/badge/release-0.8.0-brightgreen.svg?style=default">
</a>
</p>
@ -42,9 +42,9 @@ Latest **tagged** version can be downloaded in the [Release](https://github.com/
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:
:warning: *master* **SDK** packages have a same name as *tagged* packages (e.g. ``LIEF-0.7.0-Linux.tar.gz``) :warning:
:warning: *master* **SDK** packages have a same name as *tagged* packages (e.g. ``LIEF-0.8.0-Linux.tar.gz``) :warning:
:warning: *master* **Python** package has ``dev`` suffix (e.g. ``pylief-0.7.0.dev.zip``) :warning:
:warning: *master* **Python** package has ``dev`` suffix (e.g. ``pylief-0.8.0.dev.zip``) :warning:
<table>
<tr><td colspan="4"><img src="https://img.shields.io/badge/release-master-brightgreen.svg?style=default"></td></tr>
@ -56,43 +56,27 @@ Pre-built packages from the [master](https://github.com/lief-project/LIEF/tree/m
</tr>
<tr>
<td><a href="https://github.com/lief-project/packages/raw/lief-master-latest/LIEF-0.7.0-Linux.tar.gz">SDK</a></td>
<td><a href="https://github.com/lief-project/packages/raw/lief-master-latest/LIEF-0.7.0-win32.zip">SDK</a></td>
<td><a href="https://github.com/lief-project/packages/raw/lief-master-latest/LIEF-0.7.0-win64.zip">SDK</a></td>
<td><a href="https://github.com/lief-project/packages/raw/lief-master-latest/LIEF-0.7.0-Darwin.tar.gz">SDK</a></td>
<td><a href="https://github.com/lief-project/packages/raw/lief-master-latest/LIEF-0.8.0-Linux.tar.gz">SDK</a></td>
<td><a href="https://github.com/lief-project/packages/raw/lief-master-latest/LIEF-0.8.0-win32.zip">SDK</a></td>
<td><a href="https://github.com/lief-project/packages/raw/lief-master-latest/LIEF-0.8.0-win64.zip">SDK</a></td>
<td><a href="https://github.com/lief-project/packages/raw/lief-master-latest/LIEF-0.8.0-Darwin.tar.gz">SDK</a></td>
</tr>
<tr>
<td colspan="4"><p align="center"><a href="https://github.com/lief-project/packages/raw/lief-master-latest/pylief-0.7.0.dev.zip">Python</a></p></td>
<td colspan="4"><p align="center"><a href="https://github.com/lief-project/packages/raw/lief-master-latest/pylief-0.8.0.dev.zip">Python</a></p></td>
</tr>
<tr><td colspan="4"><b><img src="https://img.shields.io/badge/release-0.7.0-brightgreen.svg?style=default"></b></td></tr>
<tr><td colspan="4"><b><img src="https://img.shields.io/badge/release-0.8.0-brightgreen.svg?style=default"></b></td></tr>
<tr>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/LIEF-0.7.0-Linux.tar.gz">SDK</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/LIEF-0.7.0-win32.zip">SDK</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/LIEF-0.7.0-win64.zip">SDK</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/LIEF-0.7.0-Darwin.tar.gz">SDK</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.8.0/LIEF-0.8.0-Linux.tar.gz">SDK</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.8.0/LIEF-0.8.0-win32.zip">SDK</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.8.0/LIEF-0.8.0-win64.zip">SDK</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.8.0/LIEF-0.8.0-Darwin.tar.gz">SDK</a></td>
</tr>
<tr>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/linux_lief-0.7.0_py2.7.tar.gz">Python 2.7</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/windows_x86_lief-0.7.0_py2.7.zip">Python 2.7</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/windows_x64_lief-0.7.0_py2.7.zip">Python 2.7</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/osx_lief-0.7.0_py2.7.tar.gz">Python 2.7</a></td>
</tr>
<tr>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/linux_lief-0.7.0_py3.5.tar.gz">Python 3.5</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/windows_x86_lief-0.7.0_py3.5.zip">Python 3.5</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/windows_x64_lief-0.7.0_py3.5.zip">Python 3.5</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/osx_lief-0.7.0_py3.5.tar.gz">Python 3.5</a></td>
</tr>
<tr>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/linux_lief-0.7.0_py3.6.tar.gz">Python 3.6</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/windows_x86_lief-0.7.0_py3.6.zip">Python 3.6</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/windows_x64_lief-0.7.0_py3.6.zip">Python 3.6</a></td>
<td><a href="https://github.com/lief-project/LIEF/releases/download/0.7.0/osx_lief-0.7.0_py3.6.tar.gz">Python 3.6</a></td>
<td colspan="4"><p align="center"><a href="https://github.com/lief-project/LIEF/releases/download/0.8.0/pylief-0.8.0.zip">Python</a></p></td>
</tr>

View File

@ -122,7 +122,7 @@ else()
add_custom_target(doc-lief ALL
COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/doxygen/Doxyfile
COMMAND ${CMAKE_COMMAND} -E env "PYTHONPATH=${PROJECT_BINARY_DIR}/api/python:$ENV{PYTHONPATH}" ${SPHINX_BUILD_BIN} ${CMAKE_CURRENT_BINARY_DIR}/sphinx-src sphinx-doc
COMMAND ${CMAKE_COMMAND} -E env "PYTHONPATH=${PROJECT_BINARY_DIR}/api/python:$ENV{PYTHONPATH}" ${SPHINX_BUILD_BIN} -a -E ${CMAKE_CURRENT_BINARY_DIR}/sphinx-src sphinx-doc
DEPENDS pyLIEF LIB_LIEF_STATIC
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMENT "Generating documentation with Doxygen and Sphinx" VERBATIM)

View File

@ -41,6 +41,15 @@ Symbol
:project: lief
----------
Relocation
**********
.. doxygenclass:: LIEF::Relocation
:project: lief
Enums
*****

View File

@ -49,6 +49,17 @@ Symbol
:undoc-members:
----------
Relocation
**********
.. autoclass:: lief.Relocation
:members:
:inherited-members:
:undoc-members:
Enums
*****

View File

@ -1,8 +1,13 @@
Changelog
=========
0.8.0 - XXXX
------------
0.8.0 - October 16, 2017
------------------------
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>`_.
`LibFuzzer <https://llvm.org/docs/LibFuzzer.html>`_ has also been integrated in the project to enhance the parsers
Features
********
@ -10,80 +15,303 @@ Features
:Abstract Layer:
* :class:`~lief.Relocation` are now abstracted from the 3 formats.
* :class:`~lief.Relocation` are now abstracted from the 3 formats - :commit:`9503f2fc7b6c14bebd4c220bda4a243d87f14bd1`
* ``PIE`` and ``NX`` are abstracted through the :attr:`~lief.Binary.is_pie` and :attr:`~lief.Binary.has_nx` properties
* Add the :meth:`lief.Section.search` and :meth:`lief.Section.search_all` methods to look for patterns in the section's content.
:ELF:
* DT_FLAGS and DT_FLAGS_1
* ``DT_FLAGS`` and ``DT_FLAGS_1`` are now parsed into :class:`~lief.ELF.DynamicEntryFlags` - :commit:`754b8afa2b41993e6c37d2d9003cebdccc641d23`
* Handle relocations of object files (``.o``) - :commit:`483b8dc2eabee3da29ce5e5ff2e25c2a3c9ca297`
* Global enhancement of the ELF builder:
One can now add **multiple** :class:`~lief.ELF.Section` or :class:`~lief.ELF.Segment` into an ELF:
.. code-block:: python
elf = lief.parse("/bin/cat")
for i in range(3):
segment = Segment()
segment.type = SEGMENT_TYPES.LOAD
segment.content = [i & 0xFF] * 0x1000
elf += segment
for i in range(3):
section = Section("lief_{:02d}".format(i))
section.content = [i & 0xFF] * 0x1000
elf += section
elf.write("foo")
.. code-block:: console
$ readelf -l ./foo
PHDR 0x0000000000000040 0x0000000000000040 0x0000000000000040
0x00000000000061f8 0x00000000000061f8 R E 0x8
INTERP 0x0000000000006238 0x0000000000006238 0x0000000000006238
0x000000000000001c 0x000000000000001c R 0x1
[Requesting program interpreter: /lib64/ld-linux-x86-64.so.2]
LOAD 0x0000000000000000 0x0000000000000000 0x0000000000000000
0x000000000000d6d4 0x000000000000d6d4 R E 0x200000
LOAD 0x000000000000da90 0x000000000020da90 0x000000000020da90
0x0000000000000630 0x00000000000007d0 RW 0x200000
LOAD 0x000000000000f000 0x000000000040f000 0x000000000040f000
0x0000000000001000 0x0000000000001000 0x1000
LOAD 0x0000000000010000 0x0000000000810000 0x0000000000810000
0x0000000000001000 0x0000000000001000 0x1000
LOAD 0x0000000000011000 0x0000000001011000 0x0000000001011000
0x0000000000001000 0x0000000000001000 0x1000
....
$ readelf -S ./foo
...
[27] lief_00 PROGBITS 0000000002012000 00012000
0000000000001000 0000000000000000 0 0 4096
[28] lief_01 PROGBITS 0000000004013000 00013000
0000000000001000 0000000000000000 0 0 4096
[29] lief_02 PROGBITS 0000000008014000 00014000
0000000000001000 0000000000000000 0 0 4096
.. warning::
There are issues with executables statically linked with libraries that use ``TLS``
See: :issue:`98`
One can now add **multiple** entries in the dynamic table:
.. code-block:: python
elf = lief.parse("/bin/cat")
elf.add_library("libfoo.so")
elf.add(DynamicEntryRunPath("$ORIGIN"))
elf.add(DynamicEntry(DYNAMIC_TAGS.INIT, 123))
elf.add(DynamicSharedObject("libbar.so"))
elf.write("foo")
.. code-block:: console
$ readelf -d foo
0x0000000000000001 (NEEDED) Bibliothèque partagée: [libfoo.so]
0x0000000000000001 (NEEDED) Bibliothèque partagée: [libc.so.6]
0x000000000000000c (INIT) 0x7b
0x000000000000000c (INIT) 0x3600
...
0x000000000000001d (RUNPATH) Bibliothèque runpath:[$ORIGIN]
0x000000000000000e (SONAME) Bibliothèque soname: [libbar.so]
See :commit:`b94900ca7f500912bfe249cd534055942e28e34b`, :commit:`1e410e6c950c391f0d1a3f12cb6f8e4c9fb16539` for details.
* :commit:`b2d36940f60eacfa602c115cb542e11c70b6841c` enables modification of the ELF interpreter without **length restriction**
.. code-block:: python
elf = lief.parse("/bin/cat")
elf.interpreter = "/a/very/long/path/to/another/interpreter"
elf.write("foo")
.. code-block:: console
$ readelf -l foo
Program Headers:
Type Offset VirtAddr PhysAddr
FileSiz MemSiz Flags Align
PHDR 0x0000000000000040 0x0000000000000040 0x0000000000000040
0x00000000000011f8 0x00000000000011f8 R E 0x8
INTERP 0x000000000000a000 0x000000000040a000 0x000000000040a000
0x0000000000001000 0x0000000000001000 R 0x1
[Requesting program interpreter: /a/very/long/path/to/another/interpreter]
....
* Enhancement of the dynamic symbols counting - :commit:`985d1249b72494a0e62f34042b3c9cbfa0706e90`
* Enable editing ELF's notes:
.. code-block:: python
elf = lief.parse("/bin/ls")
build_id = elf[NOTE_TYPES.BUILD_ID]
build_id.description = [0xFF] * 20
elf.write("foo")
.. code-block:: console
$ readelf -n foo
Displaying notes found in: .note.gnu.build-id
Owner Data size Description
GNU 0x00000014 NT_GNU_BUILD_ID (unique build ID bitstring)
Build ID: ffffffffffffffffffffffffffffffffffffffff
See commit :commit:`3be9dd0ff58ec68cb8813e01d6798c16b42dac22` for more details
:PE:
* import hash / resolve ordinals
* Add :func:`~lief.PE.get_imphash` and :func:`~lief.PE.resolve_ordinals` functions - :commit:`a89bc6df4f242d7641292acdb184927449d14fff`, :commit:`dfa8e985c0561427a20088750693a004de587b1c`
* Parse the *Load Config Table* into :class:`~lief.PE.LoadConfiguration` (up to Windows 10 SDK 15002 with *hotpatch_table_offset*)
.. code-block:: python
from lief import to_json
import json
pe = lief.parse("some.exe")
loadconfig = to_json(pe.load_configuration)) # Using the lief.to_json function
pprint(json.loads(to_json(loadconfig)))
.. code-block:: javascript
{'characteristics': 248,
'code_integrity': {'catalog': 0,
'catalog_offset': 0,
'flags': 0,
'reserved': 0},
'critical_section_default_timeout': 0,
'csd_version': 0,
'editlist': 0,
...
'guard_cf_check_function_pointer': 5368782848,
'guard_cf_dispatch_function_pointer': 5368782864,
'guard_cf_function_count': 15,
'guard_cf_function_table': 5368778752,
'guard_flags': 66816,
'guard_long_jump_target_count': 0,
'guard_long_jump_target_table': 0,
'guard_rf_failure_routine': 5368713280,
'guard_rf_failure_routine_function_pointer': 5368782880,
...
For details, see commit: :commit:`0234e3b8bbb6f6f3490392f8c295fde284a99334`
:MachO:
* The ``dyld`` structure is parsed into :class:`~lief.MachO.DyldInfo`. It includes:
* The ``dyld`` structure is parsed (deeply) into :class:`~lief.MachO.DyldInfo`. It includes:
* Binding opcodes
* Rebases opcodes
* Export trie
* Section's relocations are now parsed. See: :attr:`lief.MachO.Section.relocations`
* ``LC_FUNCTION_STARTS`` is parsed into :class:`~lief.MachO.FunctionStarts`
See: :commit:`e2b81e0a8e187cae5f0f115241243a84ee7696b6`, :commit:`0e972d69ce35731867d82c047eef7eb9ea58e3ec`, :commit:`f7cc518dcfbb0557fd8d396144bf99a222d96705`, :commit:`782295bfb86d2a12584c5b16a37a26d56d1ee235`, :issue:`67`
* Section relocations are now parsed into :attr:`lief.MachO.Section.relocations` - :commit:`29c8157ecc3b308bd521cb1daee3c2e3a2cffb28`
* ``LC_FUNCTION_STARTS`` is parsed into :class:`~lief.MachO.FunctionStarts` (:commit:`18d89198a0cc63ff291ae9110f465354c3b8f1e6`)
* ``LC_SOURCE_VERSION``, ``LC_VERSION_MIN_MACOSX`` and ``LC_VERSION_MIN_IPHONEOS`` are
parsed into :class:`~lief.MachO.SourceVersion` and :class:`~lief.MachO.VersionMin`
parsed into :class:`~lief.MachO.SourceVersion` and :class:`~lief.MachO.VersionMin` (:commit:`c359778194db874669884aaccb52a4b05546bc07`, :commit:`0b4bb7d56520cd0ea08bbcb9530e5e0c96ac14ae`, :commit:`5b993117ed391db18ba775cabefa5f3981b2f1cc`, :issue:`45`)
* ``LC_THREAD`` and ``LC_UNIXTHREAD`` are now parsed into :class:`~lief.MachO.ThreadCommand` - :commit:`23257830b291c40a3aed92360040f2b0b11ffa72`
Bug Fixes
*********
Fixes
*****
Fix enums conflicts 66b4cd4550ecf6cf3adb4900e6ad7ac33f1f7f32
Fix enums conflicts(:issue:`32`) - :commit:`66b4cd4550ecf6cf3adb4900e6ad7ac33f1f7f32`
Fix most of the memory leaks: :commit:`88dafa8db6e752393f69d73f68d295e91963b8da`, :commit:`d9b1436730b5d33a753e7dfa4301697a0c676066`, :commit:`554fa153af943b97a16fc4a52ab8459a3d0a9bc7`, :commit:`3602643f5d02a1c78c4de609cc47f193f3a8840f`
:ELF:
* Bug Fix when counting dynamic symbols from the GnuHash Table - :commit:`9036a2405dc44726f40cb77cab1bcbf371ab7a70`
:PE:
* Fix nullptr deref - `ce66916 <https://github.com/lief-project/LIEF/commit/ce6691682e231dbc9ebe97695229ee0afdc185a5>`_
* Fix nullptr dereference in resources - :commit:`e90fe1b6c6f6a605390bcd1026435ce7503e7e6a`
* Handle encoding issues in the Python API - `8c7ceaf <https://github.com/lief-project/LIEF/commit/8c7ceafa823bda508259bf3c7cdc05b865f13d5c>`_
* Sanitize DLL name
* Relocations (117f8663e57ff81369630a575b4a4d0695db29b6)
* Sanitize DLL names
:MachO:
* Fix :issue:`87`, :issue:`92`
* Fix memory leaks and *some* performance issues: :issue:`94`
API
***
Logger --> configuration
In the C++ API ``get_XXX()`` getters have been renamed into ``XXX()`` (e.g. ``get_header()`` becomes ``header()``) - :commit:`a4c69f7868da1de5d09aa26e977dedb720e36cbd`, :commit:`e805669865b130057413f456958a471d8f0ac0b1`
:Abstract:
* parser can take a list of integer
* :class:`lief.Binary` gains the :attr:`~lief.Binary.format` property - :commit:`9391238f114fe963890777c2d8b90f2caaa5510c`
* :func:`lief.parse` can now takes a list of integers - :commit:`f330fa887d14d47f0683144430ac9695d3136561`
* Add :meth:`~lief.Binary.has_symbol` and :meth:`~lief.Binary.get_symbol` to :class:`lief.Binary` - :commit:`f121af5ca61a22fd83acc5c7094b50ed1cda8226`
* [Python API] Enhance the access to the abstract layer through the :attr:`~lief.Binary.abstract` attribute - :commit:`07138549a46db87c7b924fd072356030b1d5c6bc`
One can now do:
.. code-block:: python
elf = lief.ELF.parse("/bin/ls") # Could be lief.MachO / lief.PE
abstract = elf.abstract # Return the lief.Binary object
:ELF:
* Relocation gains the :attr:`~lief.ELF.Relocation.purpose` property - `b7b0bde <https://github.com/lief-project/LIEF/commit/b7b0bde4d51c54d8d226e5320b1b0d2cc48137c4>`_
()
* C++ get_XXX -> XXX
* Header.sizeof_section_header -> section_header_size
* Segment.flags -> segment.flags
* Header flags (730d045e05dca7ef3cd6a51d1175f280be356c70)
* 3b200b30503847be4779447c76f5207d18daf77f
* 43bd06f8f32196454ee2305201f4e27b3a3c8a1e
* Relocation gains the :attr:`~lief.ELF.Relocation.purpose` property - :commit:`b7b0bde4d51c54d8d226e5320b1b0d2cc48137c4`
* Add :attr:`lief.ELF.Binary.symbols` which return an iterator over **all** symbols (static and dynamic) - :commit:`af6ab65dc91169627f4fbb87cda92093eb699a1e`
* ``Header.sizeof_section_header`` has been renamed into :attr:`~lief.ELF.Header.section_header_size` - :commit:`d96971b0c3f8ff50add349957f571b8daa00708a`
* ``Segment.flag`` has been renamed into :attr:`~lief.ELF.Segment.flags` - :commit:`20a5f666deb89b06b79a1c4418ac938497fb658c`
* Add:
* :attr:`~lief.ELF.Header.arm_flags_list`,
* :attr:`~lief.ELF.Header.mips_flags_list`
* :attr:`~lief.ELF.Header.ppc64_flags_list`
* :attr:`~lief.ELF.Header.hexagon_flags_list`
to :class:`~lief.ELF.Header` - :commit:`730d045e05dca7ef3cd6a51d1175f280be356c70`
To check if a given flag is set, one can do:
.. code-block:: python
>>> if lief.ELF.ARM_EFLAGS.EABI_VER5 in lief.ELF.Header "yes" else "no"
* [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`
* Add :attr:`lief.ELF.Section.flags_list` - :commit:`4937b7193a5760df85d0ac1567afc011a22cdb98`
* Enhancement for :attr:`~lief.ELF.DynamicEntryRpath` and :attr:`~lief.ELF.DynamicEntryRunPath`: :commit:`c375a47da7c4c524e886f9238f8dd51a44501087`
* Enhancement for :attr:`~lief.ELF.DynamicEntryArray`: :commit:`81440ce00cdfc793161a0dc394ada345307dc24b`
* Add some *operators* :commit:`3b200b30503847be4779447c76f5207d18daf77f`, :commit:`43bd06f8f32196454ee2305201f4e27b3a3c8a1e`
:PE:
* 5666351e07b7bf4a9624033f670d02b8806d2663
* Add some *operators* :commit:`5666351e07b7bf4a9624033f670d02b8806d2663`
:MachO:
* cbe835484751396daffe7f8d238cbb85d66470ab
* :func:`lief.MachO.parse` can now takes a list of integers - :commit:`f330fa887d14d47f0683144430ac9695d3136561`
* :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`
* Add some *operators*: :commit:`cbe835484751396daffe7f8d238cbb85d66470ab`
:Logging:
Add an API to configure the logger - :commit:`4600c2ba8d7d17b5965c2b74faeb7e4d2128de17`
Example:
.. code-block:: python
from lief import Logger
Logger.disable()
Logger.enable()
Logger.set_level(lief.LOGGING_LEVEL.INFO)
See: :class:`lief.Logger`
Build system
************
* Add `FindLIEF.cmake <https://github.com/lief-project/LIEF/blob/e8ac976c994f6612e8dcca994032403c2d6f580f/scripts/FindLIEF.cmake>`_ - :commit:`6dd8b10325e832a7520bf5ae3a588b9e022d0345`
* Add ASAN, TSAN, USAN, LSAN - :commit:`7f6aeb0d0d74eae886f4b312e12e8f71e1d5da6a`
* Add LibFuzzer - :commit:`7a0dc28ea29a30209e944ebcde27f7c0ab234651`
TODO: Findlief.cmake
Make JSON related API optional
Documentation
*************
@ -96,7 +324,12 @@ Documentation
Acknowledgements
****************
alvaro, aguinet
* :github_user:`alvarofe` for :pr:`47`
* :github_user:`aguinet` for :pr:`55`, :pr:`61`, :pr:`65`, :pr:`77`
* :github_user:`jevinskie` for :pr:`75`
* :github_user:`liumuqing` for :pr:`80`
* :github_user:`Manouchehri` for :pr:`106`
0.7.0 - July 3, 2017
---------------------
@ -106,27 +339,27 @@ Features
:Abstract Layer:
* Add bitness (32bits / 64bits) - `78d1adb <https://github.com/lief-project/LIEF/commit/78d1adb41e8b0d21a6f6fe94014753ce68e0ffa1>`_
* Add object type (Library, executable etc) - `78d1adb <https://github.com/lief-project/LIEF/commit/78d1adb41e8b0d21a6f6fe94014753ce68e0ffa1>`_
* Add *mode* Thumbs, 16bits etc - `78d1adb <https://github.com/lief-project/LIEF/commit/78d1adb41e8b0d21a6f6fe94014753ce68e0ffa1>`_
* Add endianness - `7ea08f7 <https://github.com/lief-project/LIEF/commit/7ea08f72c43212f2e3f401b5c2c2614bc9aab8de>`_, `#29 <https://github.com/lief-project/LIEF/issues/29>`_
* Add bitness (32bits / 64bits) - :commit:`78d1adb41e8b0d21a6f6fe94014753ce68e0ffa1`
* Add object type (Library, executable etc) - :commit:`78d1adb41e8b0d21a6f6fe94014753ce68e0ffa1`
* Add *mode* Thumbs, 16bits etc - :commit:`78d1adb41e8b0d21a6f6fe94014753ce68e0ffa1`
* Add endianness - :commit:`7ea08f72c43212f2e3f401b5c2c2614bc9aab8de`, :issue:`29`
:ELF:
* Enable dynamic symbols permutation - `2dea7cb <https://github.com/lief-project/LIEF/commit/2dea7cb6d631b69995567e056a97e526f588b8ff>`_
* Fully handle section-less binaries - `de40c06 <https://github.com/lief-project/LIEF/commit/de40c068316b3334e4c8d81ecb3efc177ab24c3b>`_
* Parse ELF notes - `241aac7 <https://github.com/lief-project/LIEF/commit/241aac7bedaf18ab5e3f0c9775a8a51cb0b40a3e>`_
* Parse SYSV hash table - `afa74ce <https://github.com/lief-project/LIEF/commit/afa74cee88f730acef84fe6d9c984455a28463e7>`_, `#36 <https://github.com/lief-project/LIEF/issues/36>`_
* Add relocation size - `f1766f2 <https://github.com/lief-project/LIEF/commit/f1766f2c297caed636c7f32730cd10b62bfcc757>`_
* Enable dynamic symbols permutation - :commit:`2dea7cb6d631b69995567e056a97e526f588b8ff`
* Fully handle section-less binaries - :commit:`de40c068316b3334e4c8d81ecb3efc177ab24c3b`
* Parse ELF notes - :commit:`241aac7bedaf18ab5e3f0c9775a8a51cb0b40a3e`
* Parse SYSV hash table - :commit:`afa74cee88f730acef84fe6d9c984455a28463e7`, :issue:`36`
* Add relocation size - :commit:`f1766f2c297caed636c7f32730cd10b62bfcc757`
:PE:
* Parse PE Overlay - `e0634c1 <https://github.com/lief-project/LIEF/commit/e0634c1cf6d12fbdc5bcc1745059005e46e5d805>`_
* Enable PE Hooking - `24f6b72 <https://github.com/lief-project/LIEF/commit/24f6b7213647469e269ead9441d78204162d08ec>`_
* Parse and rebuilt dos stub - `3f06397 <https://github.com/lief-project/LIEF/commit/3f0639712617007e2e0431cb5eeb9be204c5d74b>`_
* Add a *resources manager* to provide an enhanced API over the resources - `8473c8e <https://github.com/lief-project/LIEF/commit/8473c8e126f2a8f14728ad3f8ebb59c45ac55d2d>`_
* Serialize PE objects into JSON - `673f5a3 <https://github.com/lief-project/LIEF/commit/673f5a36f0d339ad9390427292fa6e725b8fd907>`_, `#18 <https://github.com/lief-project/LIEF/issues/18>`_
* Parse Rich Header - `0893bd9 <https://github.com/lief-project/LIEF/commit/0893bd9b08f2248ae8f656ccd81b1be12e8ae57e>`_, `#15 <https://github.com/lief-project/LIEF/issues/15>`_
* Parse PE Overlay - :commit:`e0634c1cf6d12fbdc5bcc1745059005e46e5d805`
* Enable PE Hooking - :commit:`24f6b7213647469e269ead9441d78204162d08ec`
* Parse and rebuilt dos stub - :commit:`3f0639712617007e2e0431cb5eeb9be204c5d74b`
* Add a *resources manager* to provide an enhanced API over the resources - :commit:`8473c8e126f2a8f14728ad3f8ebb59c45ac55d2d`
* Serialize PE objects into JSON - :commit:`673f5a36f0d339ad9390427292fa6e725b8fd907`, :issue:`18`
* Parse Rich Header - :commit:`0893bd9b08f2248ae8f656ccd81b1be12e8ae57e`, :issue:`15`
Bug Fixes
*********
@ -137,15 +370,15 @@ Bug Fixes
:PE:
* Bug fix in the signature parser: `#30 <https://github.com/lief-project/LIEF/issues/30>`_, `4af0256 <https://github.com/lief-project/LIEF/commit/4af0256ce7c5577e0b1010c6f9b566634f0a3993>`_
* Bug fix in the resources parser: Infinite loop - `a569cc1 <https://github.com/lief-project/LIEF/commit/a569cc13d99354ff96932460f5b1fd859378f252>`_
* Add more *out-of-bounds* checks on relocations and exports - `9364f64 <https://github.com/lief-project/LIEF/commit/9364f644e937a6a5d69c64c2ef4eaa1fbdd2cfad>`_
* 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>`_
* Bug fix in the signature parser: :issue:`30`, :commit:`4af0256ce7c5577e0b1010c6f9b566634f0a3993`
* Bug fix in the resources parser: Infinite loop - :commit:`a569cc13d99354ff96932460f5b1fd859378f252`
* Add more *out-of-bounds* checks on relocations and exports - :commit:`9364f644e937a6a5d69c64c2ef4eaa1fbdd2cfad`
* Use ``min(SizeOfRawData, VirtualSize)`` for the section's size and truncate the size to the file size - :commit:`61bf14ba1182fe458453599ff014de5d71d25680`
:MachO:
* Bug fix when a binary hasn't a ``LC_MAIN`` command - `957501f <https://github.com/lief-project/LIEF/commit/957501fe76596e0396c66d08540884876cea049c>`_
* Bug fix when a binary hasn't a ``LC_MAIN`` command - :commit:`957501fe76596e0396c66d08540884876cea049c`
API
***
@ -268,8 +501,8 @@ Documentation
Acknowledgements
****************
* `ek0 <https://github.com/ek0>`_: `#24 <https://github.com/lief-project/LIEF/pull/24>`_
* `ACSC-CyberLab <https://github.com/ACSC-CyberLab>`_: `#33 <https://github.com/lief-project/LIEF/pull/33>`_, `#34 <https://github.com/lief-project/LIEF/pull/34>`_, `#37 <https://github.com/lief-project/LIEF/pull/37>`_, `#39 <https://github.com/lief-project/LIEF/pull/39>`_
* `ek0 <https://github.com/ek0>`_: :pr:`24`
* `ACSC-CyberLab <https://github.com/ACSC-CyberLab>`_: :pr:`33`, :pr:`34`, :pr:`37`, :pr:`39`
* Hyrum Anderson who pointed bugs in the PE parser
* My collegues for the feedbacks and suggestions (Adrien, SebK, Pierrick)
@ -281,7 +514,7 @@ Bug Fixes
:ELF:
* Don't rely on :attr:`lief.ELF.Section.entry_size` to count symbols - `004c676 <https://github.com/lief-project/LIEF/commit/004c6769bec37e303bbe7aaceb49f4b05c8eec84>`_
* Don't rely on :attr:`lief.ELF.Section.entry_size` to count symbols - :commit:`004c6769bec37e303bbe7aaceb49f4b05c8eec84`
API
***

View File

@ -65,11 +65,7 @@ The Doxygen documentation will be located at ``build/doc/doxygen/html`` and the
Docker
------
.. code-block:: console
$ docker build -t lief LIEF
$ docker run -i -t lief /bin/bash
See the `Dockerlief <https://github.com/lief-project/Dockerlief>`_ repo.

View File

@ -15,6 +15,13 @@
import sys
import os
import re
import six
from datetime import datetime
from docutils import nodes
from docutils.parsers.rst import directives
from sphinx.util.compat import Directive
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
@ -114,8 +121,39 @@ todo_include_todos = False
# -- Options for HTML output ----------------------------------------------
def commit_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
commit_link = nodes.reference(
"", text[:7], refuri="https://github.com/lief-project/LIEF/commit/{}".format(text), **options)
return [commit_link], []
def pr_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
pr_link = nodes.reference(
"", '#' + text, refuri="https://github.com/lief-project/LIEF/pull/{}".format(text), **options)
return [pr_link], []
def issue_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
issue_link = nodes.reference(
"", '#' + text, refuri="https://github.com/lief-project/LIEF/issues/{}".format(text), **options)
return [issue_link], []
def github_user(name, rawtext, text, lineno, inliner, options={}, content=[]):
issue_link = nodes.reference(
"", text, refuri="https://github.com/{}".format(text), **options)
return [issue_link], []
def setup(app):
app.add_stylesheet('css/custom.css') # may also be an URL
app.add_role('commit', commit_role)
app.add_role('pr', pr_role)
app.add_role('issue', issue_role)
app.add_role('github_user', github_user)
import sphinx_rtd_theme

View File

@ -39,7 +39,7 @@
#
# .. code-block:: cmake
#
# find_package(LIEF 0.7.0 REQUIRED COMPONENTS STATIC)
# find_package(LIEF 0.8.0 REQUIRED COMPONENTS STATIC)