Created
October 4, 2020 18:04
-
-
Save gitjdm/527d54ffef1afa820dff230cee72f0ba to your computer and use it in GitHub Desktop.
Cobalt Strike raw payload generation dialog that allows the exit function to be specified
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
popup attacks_other { | |
item("Payload (Choose Exit Function)", { GenPayloadDialog(); }); | |
} | |
sub GenPayloadDialog { | |
$dialog = dialog("Payload", %(listener => "", arch => "", exitfunc => ""), &GenPayload); | |
drow_listener_stage($dialog, "listener", "Listener: "); | |
drow_combobox($dialog, "exitfunc", "Exit Function: ", @("thread", "process")); | |
drow_combobox($dialog, "arch", "Arch: ", @("x64", "x86")); | |
dbutton_action($dialog, "Generate"); | |
dialog_show($dialog); | |
} | |
sub GenPayload { | |
$data = payload($3['listener'], $3['arch'], $3['exitfunc']); | |
prompt_file_save($null, { | |
local('$handle'); | |
$handle = openf("> $+ $1"); | |
writeb($handle, $data); | |
closef($handle); | |
show_message("Saved payload to\n$1"); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment