问题
I used pyinstaller to create exe file and sent it to some friends. it is harmless, but because it's --onefile the windows defender alert about it. the user need to allow permission to activate it, and it works. but with inconvenience. Any solution how to make sure windows defender won't alert about it from the start?
回答1:
It is necessary to exclude from check from all PC using that program by the following procedure.
Add an exclusion to Windows Security
- Go to Start > Settings > Update & Security > Windows Security > Virus & threat protection.
- Under Virus & threat protection settings, select Manage settings, and then under Exclusions, select Add or remove exclusions.
- Select Add an exclusion, and then select from files, folders, file types, or process. The exclusion will apply to subfolders within a folder as well.
In Addition:
For example, searching with "pyinstaller virus" in StackOverflow will find many articles.
pyinstaller virus
It seems that there is a similar article just recently.
Windows Defender detecting Python EXE as Trojan
As mentioned in this article, it has already been reported to developers of pyinstaller. There are various introductions of alternative means other than pyinstaller.
Virus warnings after trying to run .py program converted to an .exe file
AVG (and other antiviruses) reports exe file as containing virus #603
Freezing Your Code
This is introduced in the article below. What is Nuitka
However, it seems that none of them is safe after all.
Py2Exe detected as virus. Alternatives?
There seems to be workaround to recompile PyInstaller's bootloader "runw.exe".
Program made with PyInstaller now seen as a Trojan Horse by AVG
how to recompile the bootloader of Pyinstaller
来源:https://stackoverflow.com/questions/54733909/windows-defender-alert-users-from-my-pyinstaller-exe