diff --git a/.gitignore b/.gitignore index 4c49bd7..4461bb0 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ .env +setup.conf diff --git a/profiles/default.yaotl b/profiles/default.yaotl index c6e3346..a33bdd0 100644 --- a/profiles/default.yaotl +++ b/profiles/default.yaotl @@ -12,7 +12,7 @@ Teamserver { WebHook { Discord { # required - Url = "https://discord.com/api/webhooks//" # replace this with your webhook + Url = "{{DISCORD_WEBHOOK}}" # optional AvatarUrl = "https://raw.githubusercontent.com/HavocFramework/Havoc/main/assets/Havoc.png" # url to an image to use as an avatar @@ -24,8 +24,8 @@ WebHook { # For God's sake, change this... Operators { - user "admin" { - Password = "admin" + user "{{OPERATOR_USER}}" { + Password = "{{OPERATOR_PASS}}" } } @@ -40,7 +40,7 @@ Listeners { UserAgent = "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36" Hosts = [ - "c2.example.com" # replace with your actual host + "{{C2_DOMAIN}}" ] } } diff --git a/setup.conf.example b/setup.conf.example new file mode 100644 index 0000000..947b97d --- /dev/null +++ b/setup.conf.example @@ -0,0 +1,9 @@ +# Listener & Cloudflare +C2_DOMAIN="c2.wh0crypt.dev" + +# OpCreds (Teamserver) +OPERATOR_USER="admin" +OPERATOR_PASS="admin" + +# Configuración del Webhook de Discord +DISCORD_WEBHOOK="https://discord.com/api/webhooks/123456/abcdef" diff --git a/setup.sh b/setup.sh new file mode 100644 index 0000000..791cd97 --- /dev/null +++ b/setup.sh @@ -0,0 +1,32 @@ +#!/usr/bin/env bash + +set -e + +CONFIG_FILE="setup.conf" +PROFILE_FILE="./profiles/default.yaotl" + +# validate files +if [ ! -f "$CONFIG_FILE" ]; then + echo -e "\e[31m[!] Error: No se encuentra ${CONFIG_FILE}\e[0m" + exit 1 +fi + +if [ ! -f "$PROFILE_FILE" ]; then + echo -e "\e[31m[!] Error: No se encuentra el perfil base en ${PROFILE_FILE}\e[0m" + exit 1 +fi + +# load vars +source "$CONFIG_FILE" + +echo -e "\e[34m[*] Aplicando cambios quirúrgicos en el perfil...\e[0m" + +# replace useing sed +sed -i "s|{{C2_DOMAIN}}|${C2_DOMAIN}|g" "$PROFILE_FILE" +sed -i "s|{{OPERATOR_USER}}|${OPERATOR_USER}|g" "$PROFILE_FILE" +sed -i "s|{{OPERATOR_PASS}}|${OPERATOR_PASS}|g" "$PROFILE_FILE" +sed -i "s|{{DISCORD_WEBHOOK}}|${DISCORD_WEBHOOK}|g" "$PROFILE_FILE" +sed -i "s|{{DEMON_SLEEP}}|${DEMON_SLEEP}|g" "$PROFILE_FILE" +sed -i "s|{{DEMON_JITTER}}|${DEMON_JITTER}|g" "$PROFILE_FILE" + +echo -e "\e[32m[+] Placeholders have been replaced successfully.\e[0m"