[img]http://img4.fotos-hochladen.net/uploads/logoprivatefunchser8ntdym.png[/img]
First:
I decided to release some of my private functions. I think they will be
very useful for RATs and other tools which are providing information from
computer and user.
Functions
° Get Hard-disk usage °
° Get CPU-usage °
° Get RAM-usage °
° Get CPU information °
° Get external IP °
° Get local IP °
° Get TCP traffic °
° Get HWID (Processor) °
° Get Proxyserver °
° Get ammount of installed programs °
SourceCode
First:
I decided to release some of my private functions. I think they will be
very useful for RATs and other tools which are providing information from
computer and user.
Functions
° Get Hard-disk usage °
° Get CPU-usage °
° Get RAM-usage °
° Get CPU information °
° Get external IP °
° Get local IP °
° Get TCP traffic °
° Get HWID (Processor) °
° Get Proxyserver °
° Get ammount of installed programs °
SourceCode
Code
Function gethdusage(ByVal what As Byte)
Dim spacefree As String = 0
Dim space As String = 0
For Each xx As DriveInfo In DriveInfo.GetDrives
If xx.DriveType = IO.DriveType.Fixed Then
Try
space = space + CShort(xx.TotalSize / 1024 / 1024 / 1024)
spacefree = spacefree + CShort(xx.TotalFreeSpace / 1024 / 1024 / 1024)
Catch
End Try
End If
Next
If what = 0 Then
Return CInt(space - spacefree) 'Gives back the used space of your HDs in GB.
ElseIf what = 1 Then
Return CInt(space) 'Gives back the HDs Space in GB.
ElseIf what = 2 Then
Return CUInt(100 - ((spacefree / space) * 100)) 'Gives back the % of used space of the fixed HDs.
'e.g.: if you got a 100GB HD and 70GB is in use (30GB is free) this will give back "70"
'for "70% in use".
Else
Return Nothing
End If
End Function
Dim cpuCounter = New PerformanceCounter("Processor", "% Processor Time", "_Total") '<-- needed to get cpu usage!
Function getcpuusage()
Dim xx As Byte = 0
While xx = 0
xx = cpuCounter.NextValue() 'Gets the percetnual usage of your cpu.
End While
Return xx
End Function
Function getramusage(ByVal what As Byte)
Dim space As String = CInt(My.Computer.Info.TotalPhysicalMemory / 1024 / 1024)
Dim spacefree As String = CInt(My.Computer.Info.AvailablePhysicalMemory / 1024 / 1024)
If what = 0 Then
Return space - spacefree
ElseIf what = 1 Then
Return space
ElseIf what = 2 Then
Return CInt(100 - ((spacefree / space) * 100))
Else
Return Nothing
End If
End Function
Function getcpuinformation()
On Error GoTo ErrHandler
Dim oWMI As Object
Dim sSQL As String
Dim oResult As Object
Dim oItem As Object
Dim sTemp As String
Dim sProz As String
oWMI = GetObject("winmgmts:")
sSQL = "SELECT Name FROM Win32_Processor"
oResult = oWMI.ExecQuery(sSQL)
For Each oItem In oResult
sTemp = Trim$(oItem.Name)
If Len(sTemp) > 0 Then
sProz = sTemp
While InStr(sProz, " ") > 0
sProz = Replace(sProz, " ", " ")
End While
Exit For
End If
Next
On Error Resume Next
oItem = Nothing
oResult = Nothing
oWMI = Nothing
On Error GoTo 0
Return sProz
Exit Function
ErrHandler:
getcpuinformation = ""
End Function
Function getexternalip()
Dim client As New WebClient
Dim ip As String = client.DownloadString("http://whatismyip.com/automation/n09230945.asp")
Return ip
End Function
Function getlocalip()
Dim StrngAr() As String
Try
Dim IP As Net.IPAddress
Dim IPList As Array = Net.Dns.GetHostEntry(SystemInformation.ComputerName.ToString).AddressList
If IPList.Length > 0 Then
ReDim StrngAr(IPList.Length - 1)
For i As Integer = 0 To IPList.Length - 1
IP = IPList.GetValue(i)
StrngAr(i) = IP.ToString
Next
Return StrngAr
End If
Catch ex As Exception
End Try
ReDim StrngAr(0)
Return StrngAr
End Function
Function gettcptraffic(ByVal what As Byte)
Dim xxx() As NetworkInterface = NetworkInterface.GetAllNetworkInterfaces()
Dim xx As IPv4InterfaceStatistics = xxx(0).GetIPv4Statistics()
If what = 0 Then
Return CInt(xx.BytesSent / 1024)
ElseIf what = 1 Then
Return CInt(xx.BytesReceived / 1024)
Else
Return Nothing
End If
End Function
Function gethwid()
Dim strProcessorId As String = String.Empty
Dim query As New SelectQuery("Win32_processor")
Dim search As New ManagementObjectSearcher(query)
Dim info As ManagementObject
For Each info In search.Get()
strProcessorId = info("processorId").ToString()
Next
Return strProcessorId
End Function
Function getproxy()
Return My.Computer.Registry.GetValue("HKEY_CURRENT_USER\Software\" & _
"Microsoft\Windows\CurrentVersion\Internet Settings", _
"ProxyServer", "Kein Proxy")
End Function
Function getinstalled()
Dim wmi As New ManagementObjectSearcher("\root\cimv2", "SELECT * FROM " & _
"win32_Product")
Return wmi.Get.Count
End FunctionDownload Project
[img]http://icons.iconarchive.com/icons/gakuseisean/ivista-2/96/Network-Download-icon.png[/img]
[img]http://icons.iconarchive.com/icons/gakuseisean/ivista-2/96/Network-Download-icon.png[/img]
Because we are hacker - and hacker have black terminals with green font color!




![[Image: rD7TvGj.gif]](https://i.imgur.com/rD7TvGj.gif)