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

 

 


Tema destacado: Únete al Grupo Steam elhacker.NET


+  Foro de elhacker.net
|-+  Programación
| |-+  Programación General
| | |-+  .NET (C#, VB.NET, ASP)
| | | |-+  Programación Visual Basic (Moderadores: LeandroA, seba123neo)
| | | | |-+  [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
0 Usuarios y 1 Visitante están viendo este tema.
Páginas: 1 [2] 3 Ir Abajo Respuesta Imprimir
Autor Tema: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas  (Leído 20,319 veces)
Karcrack


Desconectado Desconectado

Mensajes: 2.416


Se siente observado ¬¬'


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #10 en: 12 Abril 2010, 03:13 am »

Okey, I got you ;)

You must check API declaration like this one:
Código:
Private Declare Sub CopyBytes Lib "MSVBVM60" Alias "__vbaCopyBytes" (ByVal Size As Long, Dest As Any, Source As Any)
Then you look each parameter, if the parametar hasn't ByVal or has ByRef VB6 will pass the pointer to the APIs, to sum up, if there isn't ByVal or there's ByRef you must use VarPtr(). You must be carefull with Strings and use StrPtr(), sometimes you'll need to convert UNICODE to ANSI...

I've fixed the code, it must work now:
Código:
Public Function DeObfuscateAPI(ByVal sLib As String, ByVal sFunc As String) As Boolean
    Dim lAddr           As Long
    Dim sBuff           As String * &H200
    Dim lLib            As Long
    Dim lFunc           As Long

    If App.LogMode = 0 Then GoTo OUT
    
    lAddr = App.hInstance& - Len(sBuff)
    
    Do
        lAddr = lAddr + Len(sBuff)
        If Invoke("KERNEL32", &H6E824142, ByVal lAddr, Len(sBuff)) <> 0 Then GoTo OUT
        Call Invoke("MSVBVM60", &H6A5B5999, Len(sBuff), ByVal StrPtr(sBuff), ByVal lAddr&)
        lLib = InStr(1, sBuff, sLib, vbBinaryCompare)
        lFunc = InStr(1, sBuff, sFunc, vbBinaryCompare)
    Loop Until (lLib <> 0) And (lFunc <> 0)
    
    lLib = lAddr + lLib - 1
    lFunc = lAddr + lFunc - 1
    
    dim bvTmp()  as byte
    bvTmp = StrConv(E(sLib),vbFromUnicode)

    If Invoke("KERNEL32", &HD83D6AA1, -1, ByVal lLib&, ByVal varptr(bvTmp(0)), Len(sLib), ByVal 0&) = 0 Then GoTo OUT
    bvTmp = StrConv(E(sFunc),vbFromUnicode)
    If Invoke("KERNEL32", &HD83D6AA1, -1, ByVal lFunc&, ByVal varptr(bvTmp(0)), Len(sFunc), ByVal 0&) = 0 Then GoTo OUT
    
    DeObfuscateAPI = True: Exit Function
OUT:
    DeObfuscateAPI = False: Exit Function
End Function



I've noticed that VB has a weird error with VarPtr() and Calling Funcs/APIs... looks like depending place you call it returns differents things :-\ I'm quite confused :-\ Anyway i think i've found the way of bypassing that... i will post it later
EDIT: After few hours debugging i've noticed that the problem can be solved replacing Strings in Types by Byte Arrays :)


« Última modificación: 24 Julio 2010, 01:57 am por Karcrack » En línea

tr1n1t1

Desconectado Desconectado

Mensajes: 6


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #11 en: 12 Abril 2010, 08:43 am »

Indeed I get a type mismatch error on the ByVal in this line

Código:
If Invoke("KERNEL32", &H6E824142, ByVal lAddr, Len(sBuff)) <> 0 Then GoTo OUT

Hope you can help me to fix it  :)


En línea

Karcrack


Desconectado Desconectado

Mensajes: 2.416


Se siente observado ¬¬'


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #12 en: 12 Abril 2010, 15:46 pm »

Try this way dude:
Código
  1. ]If Invoke("KERNEL32", &H6E824142, lAddr, Len(sBuff)) <> 0 Then GoTo OUT

Make sure lAddr is long ;)
En línea

tr1n1t1

Desconectado Desconectado

Mensajes: 6


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #13 en: 12 Abril 2010, 19:56 pm »

Try this way dude:
Código
  1. ]If Invoke("KERNEL32", &H6E824142, lAddr, Len(sBuff)) <> 0 Then GoTo OUT

Make sure lAddr is long ;)

If I change just this line it works  ;D , too bad that I get Type mismatch on every ByVal, so I removed them all but it won't work anymore, I think the problem is on lLib&,lAddr&,lFunc& because I tried changing one line at time and it won't work for CopyBytes and Writeprocessmemory, but not sure. Anyway this line is totally right and working.

Código:
If Invoke("KERNEL32", &H6E824142, lAddr, Len(sBuff)) <> 0 Then GoTo OUT
« Última modificación: 12 Abril 2010, 20:15 pm por tr1n1t1 » En línea

Karcrack


Desconectado Desconectado

Mensajes: 2.416


Se siente observado ¬¬'


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #14 en: 22 Julio 2010, 18:53 pm »

He hecho una pequeña actualizacion para un nuevo modulo RunPe en el que estoy trabajando, asi que aqui esta:
Código
  1. 'Karcrack , 22/07/10
  2. Option Explicit
  3. Private Type DWORD_L
  4.    D1      As Long
  5. End Type
  6.  
  7. Private Type DWORD_B
  8.    B1      As Byte:    B2      As Byte:   B3      As Byte:    B4      As Byte
  9. End Type
  10.  
  11. 'USER32
  12. Private Declare Function CallWindowProcW Lib "USER32" (ByVal lpCode As Long, Optional ByVal lParam1 As Long, Optional ByVal lParam2 As Long, Optional ByVal lParam3 As Long, Optional ByVal lParam4 As Long) As Long
  13.  
  14. Private bInitialized_Inv        As Boolean
  15. Private ASM_gAPIPTR(0 To 170)   As Byte
  16. Private ASM_cCODE(0 To 255)     As Byte
  17.  
  18. Private Function Invoke(ByVal sDLL As String, ByVal hHash As Long, ParamArray vParams() As Variant) As Long
  19.    Dim vItem                   As Variant
  20.    Dim bsTmp                   As DWORD_B
  21.    Dim lAPI                    As Long
  22.    Dim i                       As Long
  23.    Dim w                       As Long
  24.  
  25.    If Not bInitialized_Inv Then
  26.        For Each vItem In Array(&HE8, &H22, &H0, &H0, &H0, &H68, &HA4, &H4E, &HE, &HEC, &H50, &HE8, &H43, &H0, &H0, &H0, &H83, &HC4, &H8, &HFF, &H74, &H24, &H4, &HFF, &HD0, &HFF, &H74, &H24, &H8, &H50, &HE8, &H30, &H0, &H0, &H0, &H83, &HC4, &H8, &HC3, &H56, &H55, &H31, &HC0, &H64, &H8B, &H70, &H30, &H8B, &H76, &HC, &H8B, &H76, &H1C, &H8B, &H6E, &H8, &H8B, &H7E, &H20, &H8B, &H36, &H38, &H47, &H18, &H75, &HF3, &H80, &H3F, &H6B, &H74, &H7, &H80, &H3F, &H4B, &H74, &H2, &HEB, &HE7, &H89, &HE8, &H5D, &H5E, &HC3, &H55, &H52, &H51, _
  27.                                &H53, &H56, &H57, &H8B, &H6C, &H24, &H1C, &H85, &HED, &H74, &H43, &H8B, &H45, &H3C, &H8B, &H54, &H5, &H78, &H1, &HEA, &H8B, &H4A, &H18, &H8B, &H5A, &H20, &H1, &HEB, &HE3, &H30, &H49, &H8B, &H34, &H8B, &H1, &HEE, &H31, &HFF, &H31, &HC0, &HFC, &HAC, &H84, &HC0, &H74, &H7, &HC1, &HCF, &HD, &H1, &HC7, &HEB, &HF4, &H3B, &H7C, &H24, &H20, &H75, &HE1, &H8B, &H5A, &H24, &H1, &HEB, &H66, &H8B, &HC, &H4B, &H8B, &H5A, &H1C, &H1, &HEB, &H8B, &H4, &H8B, &H1, &HE8, &H5F, &H5E, &H5B, &H59, &H5A, &H5D, &HC3)
  28.            ASM_gAPIPTR(i) = CByte(vItem)
  29.            i = i + 1
  30.        Next vItem
  31.        i = 0
  32.        bInitialized_Inv = True
  33.    End If
  34.  
  35.    lAPI = CallWindowProcW(VarPtr(ASM_gAPIPTR(0)), StrPtr(sDLL), hHash)
  36.  
  37.    If lAPI Then
  38.        For w = UBound(vParams) To LBound(vParams) Step -1
  39.            vItem = vParams(w)
  40.            bsTmp = SliceLong(CLng(vItem))
  41.            '// PUSH ADDR
  42.            ASM_cCODE(i) = &H68:            i = i + 1
  43.            ASM_cCODE(i) = bsTmp.B1:        i = i + 1
  44.            ASM_cCODE(i) = bsTmp.B2:        i = i + 1
  45.            ASM_cCODE(i) = bsTmp.B3:        i = i + 1
  46.            ASM_cCODE(i) = bsTmp.B4:        i = i + 1
  47.        Next w
  48.  
  49.        bsTmp = SliceLong(lAPI)
  50.        '// MOV EAX, ADDR
  51.        ASM_cCODE(i) = &HB8:                i = i + 1
  52.        ASM_cCODE(i) = bsTmp.B1:            i = i + 1
  53.        ASM_cCODE(i) = bsTmp.B2:            i = i + 1
  54.        ASM_cCODE(i) = bsTmp.B3:            i = i + 1
  55.        ASM_cCODE(i) = bsTmp.B4:            i = i + 1
  56.        '// CALL EAX
  57.        ASM_cCODE(i) = &HFF:                i = i + 1
  58.        ASM_cCODE(i) = &HD0:                i = i + 1
  59.        '// RET
  60.        ASM_cCODE(i) = &HC3:                i = i + 1
  61.  
  62.        Invoke = CallWindowProcW(VarPtr(ASM_cCODE(0)))
  63.    Else
  64.        Invoke = -1
  65.        'Err.Raise -1, , "Bad Hash or wrong DLL"
  66.    End If
  67. End Function
  68.  
  69. Private Function SliceLong(ByVal lLong As Long) As DWORD_B
  70.    Dim tL                      As DWORD_L
  71.  
  72.    tL.D1 = lLong
  73.    LSet SliceLong = tL
  74. End Function
  75.  

Saludos ;)
En línea

nemit

Desconectado Desconectado

Mensajes: 1


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #15 en: 26 Julio 2010, 08:11 am »

Hi Karcrack.

Thx for kInvoke.

Everything runs fine in the code except the commentet Invoke Calls.
Maybe you know what im doing wrong?


Código
  1. Option Explicit
  2.  
  3. Private Declare Function CryptEncrypt Lib "advapi32.dll" (ByVal hKey As Long, ByVal hHash As Long, ByVal Final As Long, ByVal dwFlags As Long, ByVal pbData As String, pdwDataLen As Long, ByVal dwBufLen As Long) As Long
  4. Private Declare Function CryptDecrypt Lib "advapi32.dll" (ByVal hKey As Long, ByVal hHash As Long, ByVal Final As Long, ByVal dwFlags As Long, ByVal pbData As String, pdwDataLen As Long) As Long
  5. Private Declare Function CryptHashData Lib "advapi32.dll" (ByVal hHash As Long, ByVal pbData As String, ByVal dwDataLen As Long, ByVal dwFlags As Long) As Long
  6.  
  7. Private Const PROV_RSA_AES      As Long = 24
  8. Private Const CRYPT_NEWKEYSET   As Long = 8
  9. Private Const CALG_AES_256      As Long = 26128
  10. Private Const CALG_SHA_512      As Long = 32782
  11. Private Const CRYPT_CREATE_SALT As Long = &H4
  12.  
  13. Private Type OSVERSIONINFO
  14.        dwOSVersionInfoSize     As Long
  15.        dwMajorVersion          As Long
  16.        dwMinorVersion          As Long
  17.        dwBuildNumber           As Long
  18.        dwPlatformId            As Long
  19.        szCSDVersion            As String * 128
  20. End Type
  21.  
  22. Private Const sAdvapi As String = "advapi32.dll"
  23. Private Const sKernel As String = "kernel32.dll"
  24.  
  25.  
  26. Public Function EnDecodeAES(ByVal sData As String, ByVal sPassword As String, ByVal bEncrypt As Boolean) As String
  27.  
  28. Dim hHash As Long
  29. Dim hKey As Long
  30. Dim hCryptProv As Long
  31. Dim lData As Long
  32. Dim sGetServiceProvider As String
  33. Dim OS As OSVERSIONINFO
  34.  
  35.    OS.dwOSVersionInfoSize = Len(OS)
  36.    Call Invoke(sKernel, &HC75FC483, VarPtr(OS))
  37.  
  38.    If OS.dwMajorVersion & OS.dwMinorVersion >= 60 Then
  39.        sGetServiceProvider = "Microsoft Enhanced RSA and AES Cryptographic Provider"
  40.    Else
  41.        sGetServiceProvider = "Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)"
  42.    End If
  43.  
  44.    Call Invoke(sAdvapi, &H43C28BF0, VarPtr(hCryptProv), 0, StrPtr(sGetServiceProvider), PROV_RSA_AES, CRYPT_NEWKEYSET)
  45.    Call Invoke(sAdvapi, &H43C28BF0, VarPtr(hCryptProv), 0, StrPtr(sGetServiceProvider), PROV_RSA_AES, 0&)
  46.    Call Invoke(sAdvapi, &H4105A130, hCryptProv, CALG_SHA_512, 0, 0, VarPtr(hHash))
  47.  
  48.    'Private Declare Function CryptHashData Lib "advapi32.dll" (ByVal hHash As Long, ByVal pbData As String, ByVal dwDataLen As Long, ByVal dwFlags As Long) As Long
  49.    'Call Invoke(sAdvapi, &HC2122629, hHash, sPassword, Len(sPassword), 0)
  50.    ' without Invoke
  51.    Call CryptHashData(hHash, sPassword, Len(sPassword), 0)
  52.  
  53.    Call Invoke(sAdvapi, &HC2122629, hHash, StrPtr(sPassword), Len(sPassword), 0)
  54.    Call Invoke(sAdvapi, &HB56D274A, hCryptProv, CALG_AES_256, hHash, CRYPT_CREATE_SALT, VarPtr(hKey))
  55.  
  56.    lData = Len(sData)
  57.    If bEncrypt Then
  58.        sData = sData & Space(16)
  59.  
  60.        'Private Declare Function CryptEncrypt Lib "advapi32.dll" (ByVal hKey As Long, ByVal hHash As Long, ByVal Final As Long, ByVal dwFlags As Long, ByVal pbData As String, pdwDataLen As Long, ByVal dwBufLen As Long) As Long
  61.        'Call Invoke(sAdvapi, &HD9242588, hKey, 0, 1, 0, sData, VarPtr(lData), Len(sData))
  62.        ' without Invoke
  63.        Call CryptEncrypt(hKey, 0, 1, 0, sData, lData, Len(sData))
  64.  
  65.    Else
  66.  
  67.        'Private Declare Function CryptDecrypt Lib "advapi32.dll" (ByVal hKey As Long, ByVal hHash As Long, ByVal Final As Long, ByVal dwFlags As Long, ByVal pbData As String, pdwDataLen As Long) As Long
  68.        'Call Invoke(sAdvapi, &H59202584, hKey, 0, 1, 0, sData, VarPtr(lData))
  69.        ' without Invoke
  70.        Call CryptDecrypt(hKey, 0, 1, 0, sData, lData)
  71.  
  72.    End If
  73.  
  74.    EnDecodeAES = Left(sData, lData)
  75.    Call Invoke(sAdvapi, &H25D4AE7A, hHash)
  76.    Call Invoke(sAdvapi, &H95E24580, hKey)
  77.    Call Invoke(sAdvapi, &H5AE8E894, hCryptProv, 0)
  78. End Function
  79.  

En línea

Karcrack


Desconectado Desconectado

Mensajes: 2.416


Se siente observado ¬¬'


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #16 en: 26 Julio 2010, 14:53 pm »

I'd like to see the working code without Invoke, so I'll be able to see if you pass some pointers wrong..
En línea

Elemental Code


Desconectado Desconectado

Mensajes: 622


Im beyond the system


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #17 en: 9 Diciembre 2010, 19:41 pm »

Porque visual basic me odia? Eh?

Quise ver si hacia magia con la deteccion por euristica de los AV y... NO ME ANDA  :-( :-(

Código
  1. Call Invoke("urlmon", &H702F1A36, 0, StrPtr("http://d.imagehost.org/0187/Tron-Evolution-cover_1.jpg"), StrPtr("C:\Tron.jpg"), 0, 0)
  2.  

Este es un codigo "bobo" con la UrLmon de URLTODOWNLOADFILE que baja una imagen al disco para probar.

Pero no baja la imagen ni me muestra ningun error ni nada.

En que le erre :S?
En línea

I CODE FOR $$$
Programo por $$$
Hago tareas, trabajos para la facultad, lo que sea en VB6.0

Mis programas
Karcrack


Desconectado Desconectado

Mensajes: 2.416


Se siente observado ¬¬'


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #18 en: 9 Diciembre 2010, 20:34 pm »

Comprueba que estes llamando a la version unicode del API... URLDownloadToFileW@URLMON...

La explicacion de porque hay que llamar a las versiones unicode de las APIs es porque al usar StrPtr() sacas el puntero a la cadena en formato unicode... si quisieses por alguna razon usar la version ascii deberias hacer la conversion manualmente por ejemplo con
Código
  1. bvByteArray = StrConv(sCADENA, vbFromUnicode)

Un saludo ;)
En línea

Swellow

Desconectado Desconectado

Mensajes: 77


Ver Perfil
Re: [ASM+VB6][INVOKE] Llamas APIs sin declararlas - kInvoke.bas
« Respuesta #19 en: 31 Octubre 2011, 23:58 pm »

He hecho una pequeña actualizacion para un nuevo modulo RunPe en el que estoy trabajando, asi que aqui esta:
Código
  1. 'Karcrack , 22/07/10
  2. Option Explicit
  3. Private Type DWORD_L
  4.    D1      As Long
  5. End Type
  6.  
  7. Private Type DWORD_B
  8.    B1      As Byte:    B2      As Byte:   B3      As Byte:    B4      As Byte
  9. End Type
  10.  
  11. 'USER32
  12. Private Declare Function CallWindowProcW Lib "USER32" (ByVal lpCode As Long, Optional ByVal lParam1 As Long, Optional ByVal lParam2 As Long, Optional ByVal lParam3 As Long, Optional ByVal lParam4 As Long) As Long
  13.  
  14. Private bInitialized_Inv        As Boolean
  15. Private ASM_gAPIPTR(0 To 170)   As Byte
  16. Private ASM_cCODE(0 To 255)     As Byte
  17.  
  18. Private Function Invoke(ByVal sDLL As String, ByVal hHash As Long, ParamArray vParams() As Variant) As Long
  19.    Dim vItem                   As Variant
  20.    Dim bsTmp                   As DWORD_B
  21.    Dim lAPI                    As Long
  22.    Dim i                       As Long
  23.    Dim w                       As Long
  24.  
  25.    If Not bInitialized_Inv Then
  26.        For Each vItem In Array(&HE8, &H22, &H0, &H0, &H0, &H68, &HA4, &H4E, &HE, &HEC, &H50, &HE8, &H43, &H0, &H0, &H0, &H83, &HC4, &H8, &HFF, &H74, &H24, &H4, &HFF, &HD0, &HFF, &H74, &H24, &H8, &H50, &HE8, &H30, &H0, &H0, &H0, &H83, &HC4, &H8, &HC3, &H56, &H55, &H31, &HC0, &H64, &H8B, &H70, &H30, &H8B, &H76, &HC, &H8B, &H76, &H1C, &H8B, &H6E, &H8, &H8B, &H7E, &H20, &H8B, &H36, &H38, &H47, &H18, &H75, &HF3, &H80, &H3F, &H6B, &H74, &H7, &H80, &H3F, &H4B, &H74, &H2, &HEB, &HE7, &H89, &HE8, &H5D, &H5E, &HC3, &H55, &H52, &H51, _
  27.                                &H53, &H56, &H57, &H8B, &H6C, &H24, &H1C, &H85, &HED, &H74, &H43, &H8B, &H45, &H3C, &H8B, &H54, &H5, &H78, &H1, &HEA, &H8B, &H4A, &H18, &H8B, &H5A, &H20, &H1, &HEB, &HE3, &H30, &H49, &H8B, &H34, &H8B, &H1, &HEE, &H31, &HFF, &H31, &HC0, &HFC, &HAC, &H84, &HC0, &H74, &H7, &HC1, &HCF, &HD, &H1, &HC7, &HEB, &HF4, &H3B, &H7C, &H24, &H20, &H75, &HE1, &H8B, &H5A, &H24, &H1, &HEB, &H66, &H8B, &HC, &H4B, &H8B, &H5A, &H1C, &H1, &HEB, &H8B, &H4, &H8B, &H1, &HE8, &H5F, &H5E, &H5B, &H59, &H5A, &H5D, &HC3)
  28.            ASM_gAPIPTR(i) = CByte(vItem)
  29.            i = i + 1
  30.        Next vItem
  31.        i = 0
  32.        bInitialized_Inv = True
  33.    End If
  34.  
  35.    lAPI = CallWindowProcW(VarPtr(ASM_gAPIPTR(0)), StrPtr(sDLL), hHash)
  36.  
  37.    If lAPI Then
  38.        For w = UBound(vParams) To LBound(vParams) Step -1
  39.            vItem = vParams(w)
  40.            bsTmp = SliceLong(CLng(vItem))
  41.            '// PUSH ADDR
  42.            ASM_cCODE(i) = &H68:            i = i + 1
  43.            ASM_cCODE(i) = bsTmp.B1:        i = i + 1
  44.            ASM_cCODE(i) = bsTmp.B2:        i = i + 1
  45.            ASM_cCODE(i) = bsTmp.B3:        i = i + 1
  46.            ASM_cCODE(i) = bsTmp.B4:        i = i + 1
  47.        Next w
  48.  
  49.        bsTmp = SliceLong(lAPI)
  50.        '// MOV EAX, ADDR
  51.        ASM_cCODE(i) = &HB8:                i = i + 1
  52.        ASM_cCODE(i) = bsTmp.B1:            i = i + 1
  53.        ASM_cCODE(i) = bsTmp.B2:            i = i + 1
  54.        ASM_cCODE(i) = bsTmp.B3:            i = i + 1
  55.        ASM_cCODE(i) = bsTmp.B4:            i = i + 1
  56.        '// CALL EAX
  57.        ASM_cCODE(i) = &HFF:                i = i + 1
  58.        ASM_cCODE(i) = &HD0:                i = i + 1
  59.        '// RET
  60.        ASM_cCODE(i) = &HC3:                i = i + 1
  61.  
  62.        Invoke = CallWindowProcW(VarPtr(ASM_cCODE(0)))
  63.    Else
  64.        Invoke = -1
  65.        'Err.Raise -1, , "Bad Hash or wrong DLL"
  66.    End If
  67. End Function
  68.  
  69. Private Function SliceLong(ByVal lLong As Long) As DWORD_B
  70.    Dim tL                      As DWORD_L
  71.  
  72.    tL.D1 = lLong
  73.    LSet SliceLong = tL
  74. End Function
  75.  

Saludos ;)

Thanks a lot for that code Karcrack, I tried to replace my call api by name by this one, I converted all api names to hash but then my stub gets broken. Is there anything else that has to be done?
En línea

Páginas: 1 [2] 3 Ir Arriba Respuesta Imprimir 

Ir a:  

Mensajes similares
Asunto Iniciado por Respuestas Vistas Último mensaje
Ayuda[Loadlibrary] Cargar apis sin declararlas.
Programación Visual Basic
The Swash 3 4,953 Último mensaje 1 Febrero 2010, 17:31 pm
por Karcrack
[VB6-SRC] mZombieInvoke - Llama APIs sin declararlas « 1 2 »
Programación Visual Basic
Karcrack 11 8,300 Último mensaje 14 Agosto 2010, 21:14 pm
por wh0!
Ayuda con el metodo Invoke y varias Dudas Sockets
.NET (C#, VB.NET, ASP)
CATBro 2 2,687 Último mensaje 28 Octubre 2011, 07:00 am
por CATBro
[HELP] Invoke APIs
Programación Visual Basic
Swellow 1 1,615 Último mensaje 4 Mayo 2012, 10:01 am
por Swellow
[C++ Template] Hasheado de APIs en compile-time - Invoke
Análisis y Diseño de Malware
Karcrack 4 3,173 Último mensaje 24 Enero 2013, 22:13 pm
por Karcrack
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines