Update DebugKit.cna

CS Update broke debugkit
This commit is contained in:
Und3rf10w
2023-05-23 09:54:52 -04:00
committed by GitHub
parent c56c8fc813
commit 604d4f8150
+14 -14
View File
@@ -1,14 +1,14 @@
# This kit is limited to actions that I use for development and debugging, and thus is not loaded with the rest of them.
# @Und3rf10w
command !beaconinfo {
command beaconinfo {
foreach $beacon (beacons()) {
println("Beacon ID: " . $beacon['id'] . " is " . $beacon['computer']);
}
}
# This basically shows the powershell commandlets loaded for every beacon
command !loaded_powershell{
command loaded_powershell{
foreach $beacon (beacons()) {
if (data_query('cmdlets')[$beacon['id']] ne $null) {
println("\c7ID: \cF" . $beacon['id'] . ",\c3 Hostname: \cF" . $beacon['computer'] . ",\c4 Cmdlets Enabled: \cF" . data_query('cmdlets')[$beacon['id']]);
@@ -17,17 +17,17 @@ command !loaded_powershell{
}
# This shows what responses generated by the c2 server would look like
command !c2_sample_server{
command c2_sample_server{
println(data_query('metadata')['c2sample.server']);
}
# This shows what requests generated by the clients look like
command !c2_sample_client{
command c2_sample_client{
println(data_query('metadata')['c2sample.client']);
}
# This shows a list of everyone that's connected to the teamserver:
command !who{
command who{
println("\c7Currently logged on users on this teamserver are:");
foreach $user (data_query('users')){
println("\c3 * \cF $user");
@@ -35,7 +35,7 @@ command !who{
}
# This command shows a hostname of every sessions that happened, active or inactive. Basically just to provide a list of pwned hosts.
command !pwn3d_hosts {
command pwn3d_hosts {
foreach $session (data_query('sessions')) {
$computer = $session['computer'];
println($computer);
@@ -43,15 +43,15 @@ command !pwn3d_hosts {
}
# Shows the queryable Keys within cobalt strike's data model
command !show_data_keys{
command show_data_keys{
foreach $key (data_keys()){
println("\n\c4=== $key ===");
}
}
# Queries the specified key within cobalt strike's data model
# USAGE: !query_data_key <key_name>
command !query_data_key {
# USAGE: query_data_key <key_name>
command query_data_key {
$key_name = $1;
println("\n\c4=== Data for \c8\U$key_name\U \c4data key ===\n");
println(data_query($key_name));
@@ -60,8 +60,8 @@ command !query_data_key {
# Syncs all of the downloads on the teamserver to a specified path. Recursively recreates the file structure as it was on the system the file was downloaded from
# This is not very safe to use.
# TODO: Figure out how to get the content of a file stored on the teamserver
# USAGE: !sync_all_downloads [/path/on/client/machine/to/save/downloads/to] <IP address of host to download files for>
command !sync_all_downloads {
# USAGE: sync_all_downloads [/path/on/client/machine/to/save/downloads/to] <IP address of host to download files for>
command sync_all_downloads {
$file_path = $1; # TODO: sanity check, $1 MUST be provided.
if (!-exists $file_path){
mkdir($filepath);
@@ -101,7 +101,7 @@ command !sync_all_downloads {
# println("Error while trying to write to $fullfile");
# }
# }
# command !sync_all_downloads {
# command sync_all_downloads {
# $file_path = $1; # TODO: sanity check, $1 MUST be provided.
# if (!-exists $file_path){
# mkdir($filepath);
@@ -193,7 +193,7 @@ sub pstreeCreate {
}
# This alias checks whether CS thinks the beacon is an admin based on the '-isadmin' function
alias !iscsadmin{
alias iscsadmin{
if (-isadmin $1){
blog($1, "Beacon is admin");
} else{
@@ -202,7 +202,7 @@ alias !iscsadmin{
}
# This alias shows the process tree for the beacon
alias !bproctree{
alias bproctree{
blog($1, "Generate this beacon's process tree...")
$b_pid = beacon_info($1, "pid");
@ps_arry = wait(bps($1, &pstreeBpsArray));