LIEF: Library to Instrument Executable Formats
Version 1.0.0
Toggle main menu visibility
Loading...
Searching...
No Matches
lief-install
x86_64
static
include
LIEF
ELF
ELF/ParserConfig.hpp
Go to the documentation of this file.
1
/* Copyright 2017 - 2026 R. Thomas
2
* Copyright 2017 - 2026 Quarkslab
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*/
16
#ifndef LIEF_ELF_PARSER_CONFIG_H
17
#define LIEF_ELF_PARSER_CONFIG_H
18
#include "
LIEF/visibility.h
"
19
#include "
LIEF/ELF/enums.hpp
"
20
21
namespace
LIEF
{
22
namespace
ELF
{
23
25
struct
LIEF_API
ParserConfig
{
28
enum class
DYNSYM_COUNT
{
29
AUTO = 0,
30
SECTION = 1,
31
HASH = 2,
32
RELOCATIONS = 3,
34
};
35
38
static
ParserConfig
all
() {
39
static
const
ParserConfig
DEFAULT;
40
return
DEFAULT;
41
}
42
43
bool
parse_relocations
=
true
;
45
bool
parse_dyn_symbols
=
46
true
;
47
bool
parse_symtab_symbols
=
48
true
;
49
bool
parse_symbol_versions
=
50
true
;
51
bool
parse_notes
=
true
;
52
bool
parse_overlay
=
true
;
53
55
DYNSYM_COUNT
count_mtd
=
DYNSYM_COUNT::AUTO
;
56
60
uint64_t
page_size
= 0;
61
};
62
63
}
64
}
65
#endif
enums.hpp
LIEF::ELF
Namespace related to the LIEF's ELF module.
Definition
Abstract/Header.hpp:28
LIEF
LIEF namespace.
Definition
Abstract/Binary.hpp:40
LIEF::ELF::ParserConfig
This structure is used to tweak the ELF Parser (ELF::Parser).
Definition
ELF/ParserConfig.hpp:25
LIEF::ELF::ParserConfig::page_size
uint64_t page_size
Memory page size if the binary uses a non-standard value.
Definition
ELF/ParserConfig.hpp:60
LIEF::ELF::ParserConfig::parse_dyn_symbols
bool parse_dyn_symbols
Whether dynamic symbols (those from .dynsym) should be parsed.
Definition
ELF/ParserConfig.hpp:45
LIEF::ELF::ParserConfig::parse_notes
bool parse_notes
Whether ELF notes information should be parsed.
Definition
ELF/ParserConfig.hpp:51
LIEF::ELF::ParserConfig::parse_relocations
bool parse_relocations
Whether relocations (including plt-like relocations) should be parsed.
Definition
ELF/ParserConfig.hpp:43
LIEF::ELF::ParserConfig::count_mtd
DYNSYM_COUNT count_mtd
Definition
ELF/ParserConfig.hpp:55
LIEF::ELF::ParserConfig::parse_symtab_symbols
bool parse_symtab_symbols
Whether debug symbols (those from .symtab) should be parsed.
Definition
ELF/ParserConfig.hpp:47
LIEF::ELF::ParserConfig::parse_overlay
bool parse_overlay
Whether the overlay data should be parsed.
Definition
ELF/ParserConfig.hpp:52
LIEF::ELF::ParserConfig::parse_symbol_versions
bool parse_symbol_versions
Whether versioning symbols should be parsed.
Definition
ELF/ParserConfig.hpp:49
LIEF::ELF::ParserConfig::DYNSYM_COUNT
DYNSYM_COUNT
Definition
ELF/ParserConfig.hpp:28
LIEF::ELF::ParserConfig::DYNSYM_COUNT::AUTO
@ AUTO
Definition
ELF/ParserConfig.hpp:29
LIEF::ELF::ParserConfig::all
static ParserConfig all()
This returns a ParserConfig object configured to process all the ELF elements.
Definition
ELF/ParserConfig.hpp:38
visibility.h
LIEF_API
#define LIEF_API
Definition
visibility.h:45
Generated by
1.17.0