-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdata_structure.h
39 lines (30 loc) · 1.02 KB
/
data_structure.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
char *logFile = "log", *logDict = "dict", *sysFile = "syscall", *sigFile = "signature", appName[100];
char *lists = ".ids/list";
char *inputS = ".ids/input";
char *siglist = ".ids/siglist";
char *tmpF = ".tmp";
char *tmpSigF = ".tmpSig";
int countC = 0, countI = 0, countR = 0, countT = 0, countTD = 0, countSIG = 0, countSIGBB = 0, flag = 0, continueFlag = 0;
int global_len=0;
// node for the poset is System Call PoSet
struct sysCPS {
char *call1;
char *call2;
struct sysCPS *next;
};
struct sStruct {
char *str1;
char *str2;
int l;
};
// for converting files to posets and making the signature during iteration
struct sysCPS *head = NULL, *tail = NULL;
int countPS=0;
// for the current status of signature which will be written to a file later on
struct sysCPS *headSIG = NULL, *tailSIG = NULL;
// for temporary storage of input
struct sysCPS *tmpHead = NULL, *tmpTail = NULL;
// a random variable as a helper for making posets
struct sysCPS* random_var;
int val[5000][5000];
struct sStruct array[1000][1000];