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

 

 


Tema destacado: Arreglado, de nuevo, el registro del warzone (wargame) de EHN


  Mostrar Mensajes
Páginas: 1 ... 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 [25] 26
241  Comunicaciones / Hacking Mobile / cambio de bdaddr en WIFISLAX en: 22 Mayo 2007, 21:20 pm
bdaddr no hace soporte  para  el  cambio de mi BD Address.... que programa podria utilizar para cambiarle  la MAC de mi bluetooth...

la manufacturer de mi modulo es..... Integrated System Solution Corp. (57)
242  Programación / Programación Visual Basic / ayudita con CreateServiceA en: 22 Enero 2007, 18:28 pm
Mmmm... Haber gente... estoy haciendo un rootkit para el eMule (claro todavia esta en su version MUYYY PERO MUYY BETA) donde quiero agregar mi programa como un servicio de Win...! Lo agrego pero no logro que arranque...! aqui esta un trozo de my project....

hSvc = CreateServiceA(hSC, service_name_intern, SERVICE_NAME_EXTERT, _
SERVICE_ALL_ACCESS, SERVICE_WIN32_SHARE_PROCESS, SERVICE_AUTO_START, _
SERVICE_ERROR_CRITICAL, pathMe, vbNullString, vbNullString, vbNullString, vbNullString, vbNullString)

Como les dije se crea el servicio pero no arranca, es decir CreateServiceA.... devuelve el handle de mi servicio.... Creo que esta parte esta bien... pero no estoy seguro....!

Bue... si alguin quiere colaborar en my project, sera bienvenido...! <victormiguelgomez@hotmail.com>

El err que me dice cuando intento arrancarlo es.... 
"Error 1053: El servicio no ha respondido a la petición o inicio del control en un tiempo adecuado."

Ah otra cosa.... Alguien sabe como impedir que detengan un servicio de Win...??
243  Programación / Programación Visual Basic / modificar el serial de un diskk...?? en: 12 Enero 2007, 21:13 pm
Ahi una API de Win que permita modificar el serial de un disk...??? Digo esto porque todos los diskkets nuevos tienen el mismo serial... 0000-0000
244  Programación / Programación Visual Basic / Re: --- adivina que --- Basic5 TE ESPIA en: 12 Enero 2007, 20:27 pm

Además, si te sacan el nombre que? Van a ir a tu casa a pegarte?


Si guarda el path quien quita que guarde la IP... pero cifrada...!    :o :o
245  Programación / Programación Visual Basic / Re: --- adivina que --- Basic5 TE ESPIA en: 11 Enero 2007, 23:00 pm
 ;D ;D si y dimelo a mi.... por eso estoy migrando a perl.....!
246  Programación / Programación Visual Basic / --- adivina que --- Basic5 TE ESPIA en: 11 Enero 2007, 22:45 pm
Cuando generas un exe en Basic5, dicho exe guarda el path o directorio del *.vbp (Visual Basic Project) por ejemplo... si haces un virus en “C:\Documents and Settings\Maldito MOCOSOFT\Basic\virus\quepeoconMOCOSOFT.vbp” esa ruta se almacena en el exe... sino me creen abranlo con un edit hexadecimal... o con Process Explorer de Sysinternals

Con Process Explorer abran las propiedades del exe y vayan a la pestaña Strings....

Otra razon para migrar a los compiladores de codigo abierto...!
247  Programación / Programación Visual Basic / Re: API SOCKET -- ws2_32 --- en: 9 Enero 2007, 00:12 am
muchaho tu si sabes.......................! thanks...!
248  Programación / Programación Visual Basic / Re: API SOCKET -- ws2_32 --- en: 6 Enero 2007, 22:20 pm
tu dices en el cod que puse..???


Fijate cuando se llama a la fn accept devuelve un 0.. cuando deberia devolver el handle para utilizarlo con las fns recv y send...!
249  Programación / Programación Visual Basic / Re: API SOCKET -- ws2_32 --- en: 1 Enero 2007, 07:58 am
Quiero aprender a programar con la APi...!
250  Programación / Programación Visual Basic / API SOCKET -- ws2_32 --- en: 27 Diciembre 2006, 20:23 pm
Cuando intento utilizar la fn accept siempre me devuelve SOCK_INVALID, pero aun asi establece la conexion con el client..... Y no puedo utilizar las fn send y recv.. bueno aqui esta el codigo.... Bueno con unos cuantos cambios que le hecho...

Option Explicit

'Servidor simple con Sockets del API Winsock2.
'Autor: HaXprT
'Fecha: 01/03/2002
'Ultima actualización: 05/03/2002

'Constantes del API Winsock 2
Private Const INVALID_SOCKET = -1
Private Const SOCKET_ERROR = -1
Private Const WSADESCRIPTION_LEN = 256
Private Const WSASYSSTATUS_LEN = 128
Private Const AF_INET = 2
Private Const INADDR_ANY = 0
Private Const SOCK_STREAM = 1
Private Const SOCK_DGRAM = 2


'Tipos de Datos del API Winsock 2
Private Type WSAData_Type
    wVersion As Integer
    wHighVersion As Integer
    szDescription(WSADESCRIPTION_LEN) As Byte
    szSystemStatus(WSASYSSTATUS_LEN) As Byte
    iMaxSockets As Integer  'U_SHORT
    iMaxUdpDg As Integer    'U_SHORT
    lpVendorInfo As Long
   
End Type

'Estructura IN_ADDR implementada sin uniones
Private Type IN_ADDR
    S_addr As Long  'U_LONG
   
End Type

Private Type SOCKADDR_IN
    sin_family As Integer
    sin_port As Integer 'U_SHORT
    sin_addr As Long
    sin_zero(7) As Byte 'array de 8 bytes
   
End Type

'Funciones del API Winsock 2
' Ojo, probar con "ws2_32"
Private Declare Function socket Lib "ws2_32" (ByVal AF As Long, _
ByVal Tipo As Long, _
ByVal Protocol As Long) As Long

Private Declare Function WSAStartup Lib "ws2_32" (ByVal wVersionRequested As Integer, _
ByRef lpWSAData As Any) As Long

Private Declare Function WSACleanup Lib "ws2_32" () As Long

Private Declare Function WSAGetLastError Lib "ws2_32" () As Long

Private Declare Function htons Lib "ws2_32" (ByVal hostshort As Integer) As Long 'U_SHORT

Private Declare Function bind Lib "ws2_32" (ByVal s As Long, _
name As SOCKADDR_IN, _
ByVal namelen As Long) As Long

Private Declare Function listen Lib "ws2_32" (ByVal s As Long, _
ByVal backlog As Long) As Long

Private Declare Function send Lib "ws2_32" (ByVal Sock As Long, _
ByVal Buf As Byte, _
ByVal Lenght As Long, _
ByVal Flags As Long) As Long

Private Declare Function accept Lib "ws2_32" (ByVal hSock&, _
from As SOCKADDR_IN, _
ByVal LenFrom&) As Long

Private Declare Function recv Lib "ws2_32" (ByVal Sock As Long, _
ByVal Buf As Byte, _
ByVal Lenght As Long, _
ByVal Flags As Long) As Long

Private Declare Function closesocket Lib "ws2_32" (ByVal s As Long) As Long

Dim SockServer As Long
Function MakeWord(ByVal low As Byte, ByVal high As Byte) As Integer

MakeWord = high * 256 + low

End Function

Function LoByte(ByVal Num As Integer) As Byte

LoByte = Num And 255

End Function

Function HiByte(ByVal Num As Integer) As Byte

Num = Num / 256
HiByte = Num And 255

End Function

Function ComplementoADos(Num As Long) As Integer
' Esta función recibe un número entero que debe estar entre 0..65535,
' el cual es el rango para un tipo de dato unsigned short en C,
' y lo convierte a un valor equivalente para ser almacenado en un
' tipo de dato Integer de Visual Basic (-32768..32767)

If Num > 32767 Then
Num = Num - 1
ComplementoADos = -(Num Xor 65535)

    Else
    ComplementoADos = Num
   
End If

End Function

Function ByteArrayToString(Arreglo() As Byte, Tamaño As Long) As String
Dim Str As String
Dim i As Integer

For i = 0 To Tamaño - 1
    Str = Str & Chr(Arreglo(i))
   
Next

ByteArrayToString = Str

End Function

'*** Mis Funciones de Alto Nivel ***
' Inica el socket del servidor y lo retorna si todo sale bien.
' En caso de fallo retorna SOCKET_ERROR
Private Function IniciarSocketServidor(Puerto As Long, Cola As Long) As Long
Dim Error As Long
Dim wVersionRequested As Integer
Dim Sin As SOCKADDR_IN
Dim wsaData As WSAData_Type

wVersionRequested = MakeWord(2, 2)
Error = WSAStartup(wVersionRequested, wsaData)

If Error <> 0 Then

    MsgBox "error", vbExclamation, "Socket Invalido 1"
    IniciarSocketServidor = SOCKET_ERROR
    Exit Function

End If

If (LoByte(wsaData.wVersion) <> 2) Or (HiByte(wsaData.wVersion) <> 2) Then

    Call WSACleanup
    MsgBox "Socket Invalido, Versión de Winsock Incorrecta", vbExclamation, Error
    IniciarSocketServidor = SOCKET_ERROR
   
Exit Function

End If

SockServer = socket(AF_INET, SOCK_STREAM, 0)

If SockServer = INVALID_SOCKET Then

    Error = WSAGetLastError()
    Call WSACleanup
    MsgBox "Error al llamar a socket: " & Error, vbExclamation, "Error"
    IniciarSocketServidor = SOCKET_ERROR
    Exit Function
   
End If

Sin.sin_family = AF_INET
Sin.sin_addr = INADDR_ANY
Sin.sin_port = ComplementoADos(htons(Puerto))

If bind(SockServer, Sin, Len(Sin)) = SOCKET_ERROR Then

    Error = WSAGetLastError()
    closesocket SockServer
    Call WSACleanup
    closesocket (SockServer)
    MsgBox "Error al llamar a bind: " & Error, vbExclamation, "Error"
    IniciarSocketServidor = SOCKET_ERROR
    Exit Function

End If

If listen(SockServer, Cola) = SOCKET_ERROR Then

    Error = WSAGetLastError()
    closesocket SockServer
    Call WSACleanup
    MsgBox "Error al llamar a listen: " + Error, vbExclamation, "Error"
    IniciarSocketServidor = SOCKET_ERROR
    Exit Function
   
End If

IniciarSocketServidor = SockServer

End Function

Private Function AcceptLoop(SockServ As Long)

Dim Buf(255) As Byte, N As Long, hSock&, from As SOCKADDR_IN

Do

hSock = accept(SockServ, from, Len(from))

Debug.Print "bucle"

Loop While hSock = INVALID_SOCKET

Debug.Print "hSock = " & hSock

Do
N = 0

N = recv(SockServ, Buf(0), UBound(Buf), 0)
If N > 0 Then
Debug.Print "Se recibió: " & ByteArrayToString(Buf, N)

    Else
    Debug.Print N

End If

N = send(SockServ, Buf(0), N, 0)
If N > 0 Then
Debug.Print "Se envió: " & ByteArrayToString(Buf, N)

    Else
    Debug.Print N

End If

DoEvents

Loop

End Function

Private Sub cndCerrar_Click()

closesocket SockServer
Unload Me

End Sub

Private Sub CommandIniciarSocket_Click()
Dim SockServer As Long

SockServer = IniciarSocketServidor(Val(TextPuerto.Text), 5)
If SockServer <> SOCKET_ERROR Then Call AcceptLoop(SockServer)

End Sub
Páginas: 1 ... 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 [25] 26
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines