【问题标题】:Windows defender alert users from my pyinstaller exe [duplicate]Windows Defender 从我的 pyinstaller exe 提醒用户 [重复]
【发布时间】:2019-07-11 01:09:04
【问题描述】:

我使用 pyinstaller 创建 exe 文件并发送给一些朋友。它是无害的,但因为它是 --onefile,windows 防御者会警告它。用户需要允许激活它,并且它可以工作。但带来不便。 任何解决方案如何确保 Windows Defender 从一开始就不会提醒它?

【问题讨论】:

    标签: python windows exe pyinstaller


    【解决方案1】:

    必须通过以下步骤从使用该程序的所有 PC 中排除检查。

    Add an exclusion to Windows Security

    1. 转至开始 > 设置 > 更新和安全 > Windows 安全 > 病毒和威胁防护。
    2. 在病毒和威胁防护设置下,选择管理设置,然后在排除项下,选择添加或删除排除项。
    3. 选择添加排除项,然后从文件、文件夹、文件类型或进程中进行选择。排除也适用于文件夹中的子文件夹。

    另外:

    比如在StackOverflow中用“pyinstaller virus”搜索会发现很多文章。
    pyinstaller virus

    好像最近有一篇类似的文章。
    Windows Defender detecting Python EXE as Trojan

    如本文所述,已向 pyinstaller 的开发者报告。除了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
    这将在下面的文章中介绍。 What is Nuitka

    但是,它们似乎都不是安全的。
    Py2Exe detected as virus. Alternatives?

    似乎有重新编译 PyInstaller 的引导加载程序“runw.exe”的解决方法。
    Program made with PyInstaller now seen as a Trojan Horse by AVG
    how to recompile the bootloader of Pyinstaller

    【讨论】:

    • 感谢您的回复。问题出在其他计算机上,而不仅仅是我的计算机。关于 pyinstaller 或代码本身的任何建议,以便下载我的应用程序的其他计算机不会显示防御者警报?
    • @Omri,很遗憾没有。 PyInstaller.exe 病毒错误识别问题就像FAQ 一样很久以前就发生过多次。应该已经通知 PyInstaller 开发者了,但是好像没有被修改过。请考虑切换到其他程序,例如 cx_Freeze 或 py2exe。
    • @kunif 谢谢。排除 .exe 没有帮助。但排除包含 .exe 的文件夹有效!
    猜你喜欢
    • 2017-11-06
    • 2021-02-23
    • 1970-01-01
    • 2023-04-11
    • 1970-01-01
    • 2019-08-12
    • 2016-06-09
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多