Choco: Cannot install Chocolatey due to Windows Defender AMSI (Anti-Malware Scan Interfaces) blocking installation - "This script contains malicious content and has been blocked by your antivirus software"

Created on 15 Oct 2020  路  12Comments  路  Source: chocolatey/choco

I am using the Licenced version of McAfee AV on my licenced Windows 10 Home Edition. Not sure what is interfering with Chocolatey, but it is not letting me install even being an Administrator.

Please note: I have already followed your documents for setting the ExecutionPolicies and all okay from my end.

Also, attached the error as per the below screengrab: -

Chocolatey_AV_Issue

0 - _Triaging Blocked - External

Most helpful comment

Hi! I was also facing the same problem but I was able to install chocolatey by opening McAfee app and disabling Real Time scanning and Firewall
Screenshot 2020-11-03 133849

All 12 comments

You might want to check your AV settings and make sure they allow signed scripts, at least while you run the installation. I'm not familiar enough with McAfee itself to know exactly where that's at, though.

Okay. I will check the same. The only concern I have is after installing Chocolatey, will it do the same for every software install through its CLI. Also unsure, about being compromising with my System's Security too. So for now, will drop the plan to go ahead with Chocolatey; even though its a great package/concept/thought. Will check and explore WinGet.

I would love to know what it thinks is malicious?

It's possible simple Invoke-Expression / iex usage is enough to trigger Defender at this point tbh. 馃

Hi! I was also facing the same problem but I was able to install chocolatey by opening McAfee app and disabling Real Time scanning and Firewall
Screenshot 2020-11-03 133849

@TanishqPal Thanks! I was also facing the same issue and now it is working fine!

@TanishqPal, @navaneethavarier: There is no point using Antivirus then! Though I know this works, it is not what is expected to be solution. Thanks!

Can you please close this issue ?

@TanishqPal The issue is not yet resolved, so we should keep it open.

Was this page helpful?
0 / 5 - 0 ratings