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/utils.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_UTILS_H
17
#define LIEF_ELF_UTILS_H
18
19
#include <string>
20
#include <vector>
21
22
#include "
LIEF/types.hpp
"
23
#include "
LIEF/visibility.h
"
24
25
namespace
LIEF
{
26
class
BinaryStream
;
27
28
namespace
ELF
{
29
31
LIEF_API
bool
is_elf
(
BinaryStream
& stream);
32
34
LIEF_API
bool
is_elf
(
const
std::string& file);
35
37
LIEF_API
bool
is_elf
(
const
std::vector<uint8_t>& raw);
38
39
LIEF_API
unsigned
long
hash32
(
const
char
* name);
40
LIEF_API
unsigned
long
hash64
(
const
char
* name);
41
LIEF_API
uint32_t
dl_new_hash
(
const
char
* name);
42
}
43
}
44
45
46
#endif
LIEF::BinaryStream
Class that is used to a read stream of data from different sources.
Definition
BinaryStream.hpp:33
LIEF::ELF
Namespace related to the LIEF's ELF module.
Definition
Abstract/Header.hpp:28
LIEF::ELF::is_elf
bool is_elf(BinaryStream &stream)
Check if given stream wraps an ELF file.
LIEF::ELF::hash64
unsigned long hash64(const char *name)
LIEF::ELF::hash32
unsigned long hash32(const char *name)
LIEF::ELF::dl_new_hash
uint32_t dl_new_hash(const char *name)
LIEF
LIEF namespace.
Definition
Abstract/Binary.hpp:40
types.hpp
visibility.h
LIEF_API
#define LIEF_API
Definition
visibility.h:41
Generated by
1.17.0