-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathprocmodlib.h
More file actions
51 lines (43 loc) · 1.16 KB
/
Copy pathprocmodlib.h
File metadata and controls
51 lines (43 loc) · 1.16 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
#ifndef PROCMODLIB
#define PROCMODLIB
#include "unicode.h"
#include<stdio.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <sys/mman.h>
#include <errno.h>
#include <sys/ptrace.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <limits.h>
#include <stdint.h>
#if defined(__ILP32__)
#define WORD uint32_t
#define WORDFORMAT "%08x"
#define WORDMAX 0xFFFFFFFF
#define TOWORD(x) strtoul(x,NULL,10)
#elif defined(__LP64__)
#define WORD uint64_t
#define WORDFORMAT "%016lx"
#define WORDMAX 0xFFFFFFFFFFFFFFFF
#define TOWORD(x) strtoul(x,NULL,10)
#elif __SIZEOF_POINTER__ == 4
#define WORD uint32_t
#define WORDFORMAT "%08x"
#define WORDMAX 0xFFFFFFFF
#define TOWORD(x) strtoul(x,NULL,10)
#else
#error Unsupported architecture
#endif
void dumpprocess(int procid, char *file);
int procreplace(int procid, unsigned char *find, int findlen, unsigned char *replace,
int replacelen, WORD lowerbound, WORD upperbound);
#endif