What does this command?

PhoXZoNe 0 Reputation points
2023-04-04T16:58:47.38+00:00

I speak spanish, so... Google Translate going on.
Hello, first I want to clarify that I already know what causes the command, because in the link below there is a question on how to solve what causes it, but I would like to know what it does and how it works, to be able to "break" Windows Defender, thanks.
And, i don't really know if this is the place to make a question about this, but at least y have to try.

powershell -inputformat none -outputformat none -NonInteractive -Command Add-MpPreference -ExclusionPath C:\

https://answers.microsoft.com/es-es/windows/forum/all/no-puedo-windows-defender-ni-actualizar-windows/7853f339-b7ae-4311-9c98-f27080b17fd4 (yes, this post is in Spanish, but al least the images are the same to everyone that use that command)

Windows for business Windows Client for IT Pros Devices and deployment Configure application groups
Windows for business Windows Server User experience PowerShell
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. MotoX80 36,291 Reputation points
    2023-04-04T18:23:18.7766667+00:00

    It effectively excludes the entire C: drive from being scanned for malware. On my laptop, I see that some McAfee antivirus folders are excluded. Likely because those folders might contain virus signatures that McAfee uses to detect malware. That exclusion prevents Defender from falsely detecting the McAfee files as viruses.

    PS C:\> (Get-MpPreference).ExclusionPath
    c:\program files\mcafee'c:\program files\common files\mcafee'c:\program files (x86)\mcafee'c:\program files (x86)\common files\mcafee'C:\DELL\FD09N'c:\programdata\mcafee
    PS C:\>
    
    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.