forked from fashao/XIL2CppDumper
-
Notifications
You must be signed in to change notification settings - Fork 0
/
IL2CppBinParser.h
41 lines (31 loc) · 923 Bytes
/
IL2CppBinParser.h
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
//
// Created by xia0 on 2019/11/18.
//
#ifndef XIL2CPPDUMPER_IL2CPPBINPARSER_H
#define XIL2CPPDUMPER_IL2CPPBINPARSER_H
#include <unistd.h>
#include "XB1nLib/XB1nLib.h"
class IL2CppBinParser
{
private:
public:
void* codeRegistration;
void* metadataRegistration;
uint32_t metadataVersion;
bool isMacho;
bool isMacho64;
bool isElf;
bool isElf64;
void* il2cppbin;
IL2CppBinParser(void* il2cppbin, uint32_t metadataVersion);
void initWithMacho64();
int64_t fixElf64Relocation(uint64_t needFixAddr);
Arm_Addr fixElf32Relocation(Arm_Addr needFixAddr);
void initWithElf32();
void initWithElf64();
void* seek2Offset(uint64_t offset);
uint64_t RVA2RAW(void* rva); // convert ida adress to file offset
void* RAW2RVA(uint64_t raw); // convert file offset to ida address
void* idaAddr2MemAddr(void* idaAddr);
};
#endif //XIL2CPPDUMPER_IL2CPPBINPARSER_H