-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathglibcruntime.h
More file actions
57 lines (44 loc) · 1.24 KB
/
glibcruntime.h
File metadata and controls
57 lines (44 loc) · 1.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#ifndef __LINE_GLIBC_RUNTIME_H_
#define __LINE_GLIBC_RUNTIME_H_
#include <stdint.h>
#include "rtld.h"
#include "logger.h"
class GlibcRuntime : Logger
{
private:
rtld_global_ro m_rtldGlobalRO;
rtld_global m_rtldGlobal;
int m_libc_enable_secure;
public:
GlibcRuntime();
~GlibcRuntime();
uint64_t findSymbol(const char* symName);
static uint64_t tls_get_addr();
static void lock_recursive(void* lock);
static void unlock_recursive(void* lock);
static void* dl_find_dso_for_object(void* addr);
static void* dl_open(
const char *file,
int mode,
const void *caller_dlopen,
Lmid_t nsid,
int argc,
char *argv[],
char *env[]);
static int dl_catch_error(
const char **objname,
const char **errstring,
bool *mallocedp,
void (*operate) (void *),
void *args);
static uint64_t dl_lookup_symbol_x(
const char * symname,
struct link_map * handle,
const Elf64_Sym ** symbol,
struct r_scope_elem *[],
const struct r_found_version *,
int, int,
struct link_map *);
static void dl_debug_printf(const char *, ...) __attribute__ ((__format__ (__printf__, 1, 2)));
};
#endif