Updates the internal MbedTLS version from 3.6.4 to 4.0.0.
This major version introduces the TF-PSA-Crypto architecture,
requiring significant changes to the build system and internal API usage.
Added `src/mbedtls_wraps.h` to handle the internalization
of MbedTLS 4.0 structures. This file re-declares private contexts
(like `mbedtls_rsa_context`) and uses `-DMBEDTLS_DECLARE_PRIVATE_IDENTIFIERS`
to allow LIEF to inspect internal key parameters required for PE
signature verification.
By default, LIEF's logger uses `stderr` to emit log messages which
is not catchable in Python. This commit makes use of `sys.stderr` for
the Python bindings.
This commit (obviously non-atomic) cleans LIEF's code base by:
- Using pointer semantics (`std::unique_ptr<>`)
- Using LEAF boost error in the binary stream
- Reducing the scope of the iterators (`it_section`, ...)
- Removing `Structures.hpp` from the public headers
- etc
This commit removes the public include of nlohmann/json
as it is a *detail of implementation*. Instead, the public
API exposes:
```cpp
std::string to_json(...);
```
In addition, it enables to externally provide nlohmann/json using
the cmake option ``-DLIEF_OPT_NLOHMANN_JSON_EXTERNAL=on``.
For instance, this option can be used as follows:
```bash
$ cmake -DLIEF_OPT_NLOHMANN_JSON_EXTERNAL=on \
-Dnlohmann_json_DIR=<PATH>/lib/cmake/nlohmann_json
```
Related to #605
Among the changes:
- It removes the ``and, or, not`` keywords
- It updates the Documentation
- It moves the internal structures in the ``details::`` namespace