FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
ShellcodeCompiler/ShellcodeCompiler/DeclaredFunctionsStates.cpp at master · sjas/ShellcodeCompiler · GitHub
sjas
ShellcodeCompiler
Repository navigation
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
ShellcodeCompiler
/
ShellcodeCompiler
/
DeclaredFunctionsStates.cpp
Copy path
More file actions
More file actions
Latest commit
History
History
History
60 lines (49 loc) · 2.16 KB
Breadcrumbs
ShellcodeCompiler
/
ShellcodeCompiler
/
DeclaredFunctionsStates.cpp
Copy path
File metadata and controls
60 lines (49 loc) · 2.16 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
58
59
60
#
include
"
DeclaredFunctionsStates.h
"
//
Declare functions states
DeclaredStates::State DeclaredFunctionsStates::DF_function;
DeclaredStates::State DeclaredFunctionsStates::DF_FunctionName;
DeclaredStates::State DeclaredFunctionsStates::DF_FunctionDLLStr;
DeclaredStates::State DeclaredFunctionsStates::DF_ReadStringInQuotes;
DeclaredStates::State DeclaredFunctionsStates::DF_GotStrInQuotes;
DeclaredStates::State DeclaredFunctionsStates::DF_FinishStrInQuotes;
void
DeclaredFunctionsStates::CreateDeclareFunctionsStates
()
{
DeclaredStates::Transform T;
//
From "DF_function" with space go to "DF_FunctionName"
T.
Character
=
'
'
;
T.
NextState
= &DF_FunctionName;
DF_function.
Transforms
.
push_back
(T);
DF_function.
Name
=
"
function
"
;
//
From "DF_FunctionName" with AlphaNum go to "DF_FunctionName"
T.
Character
=
CHR_READ_ALPHANUMSTR
;
T.
NextState
= &DF_FunctionName;
DF_FunctionName.
Transforms
.
push_back
(T);
DF_FunctionName.
Name
=
"
FunctionName
"
;
DF_FunctionName.
Process
=
true
;
DF_FunctionName.
ProcessStateData
= DeclaredStates::ProcessStateData_FunctionName;
//
From "DF_FunctionName" with "(" go to "DF_FunctionDLLStr"
T.
Character
=
'
(
'
;
T.
NextState
= &DF_FunctionDLLStr;
DF_FunctionName.
Transforms
.
push_back
(T);
//
From "DF_FunctionDLLStr" with "\"" go to "DF_ReadStrInQuotes"
T.
Character
=
'
"
'
;
T.
NextState
= &DF_ReadStringInQuotes;
DF_FunctionDLLStr.
Transforms
.
push_back
(T);
DF_FunctionDLLStr.
Name
=
"
FunctionDLLStr
"
;
//
From "DF_ReadStrInQuotes" with AlphaNum go to "DF_ReadStrInQuotes"
T.
Character
=
CHR_READ_ALPHANUMSTR
;
T.
NextState
= &DF_ReadStringInQuotes;
DF_ReadStringInQuotes.
Transforms
.
push_back
(T);
DF_ReadStringInQuotes.
Name
=
"
ReadStringInQuotes
"
;
DF_ReadStringInQuotes.
Process
=
true
;
DF_ReadStringInQuotes.
ProcessStateData
= DeclaredStates::ProcessStateData_FunctionDLLName;
//
From "DF_ReadStringInQuotes" with "\"" go to "DF_GotStrInQuotes"
T.
Character
=
'
"
'
;
T.
NextState
= &DF_GotStrInQuotes;
DF_ReadStringInQuotes.
Transforms
.
push_back
(T);
//
From "DF_GotStrInQuotes" with ")" go to "DF_FinishStrInQuotes"
T.
Character
=
'
)
'
;
T.
NextState
= &DF_FinishStrInQuotes;
DF_GotStrInQuotes.
Transforms
.
push_back
(T);
DF_GotStrInQuotes.
Name
=
"
GotStrInQuotes
"
;
}
Back
|
FazBrowse Home
|
New Git URL