Skip to content

Commit

Permalink
Merge pull request #75 from AjayBrahmakshatriya/master
Browse files Browse the repository at this point in the history
Redone RCE implememtation
  • Loading branch information
AjayBrahmakshatriya authored Jun 18, 2024
2 parents 1a8f476 + 4476ad7 commit e487e03
Show file tree
Hide file tree
Showing 4 changed files with 299 additions and 148 deletions.
6 changes: 6 additions & 0 deletions samples/outputs.var_names/sample57
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,11 @@ void bar (void) {
int x_0 = 0;
int* y_1 = (&(x_0));
(y_1[0] = y_1[0] + 1) - 1;
int z_2 = 0;
(z_2 = z_2 + 1) - 1;
int a_3 = z_2;
(z_2 = z_2 + 1) - 1;
int b_4 = a_3;
(b_4 = b_4 + 1) - 1;
}

6 changes: 6 additions & 0 deletions samples/outputs/sample57
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,11 @@ void bar (void) {
int var0 = 0;
int* var1 = (&(var0));
(var1[0] = var1[0] + 1) - 1;
int var2 = 0;
(var2 = var2 + 1) - 1;
int var3 = var2;
(var2 = var2 + 1) - 1;
int var4 = var3;
(var4 = var4 + 1) - 1;
}

9 changes: 9 additions & 0 deletions samples/sample57.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,15 @@ static void bar(void) {
dyn_var<int*> y = &x;

(*y)++;

dyn_var<int> z = 0;
z++;

dyn_var<int> a = z;
z++;

dyn_var<int> b = a;
b++;


}
Expand Down
Loading

0 comments on commit e487e03

Please sign in to comment.