PHP_CodeSniffer
PHP_CodeSniffer copied to clipboard
Getting identified as malware by windows defender
Whilst installing PHP_CodeSniffer via composer on windows, defender identifies PHP_CodeSniffer as a "Severe Threat" and removes it from the computer.
Threat detected: Backdoor:PHP/Dirtelti.MTF
Affected items:
file: \vendor\composer\ff331b7a\squizlabs-PHP_CodeSniffer-d7c00c3\src\Standards\Squiz\Tests\PHP\EvalUnitTest.inc
I know this is a false positive and probably linked to #2468 You CAN tell defender to allow this exception
So I suppose it is just something to be aware of.

The contents of the file is:
<?php
eval('$var = 4;');
$string = '$var = 4;';
eval($string);
?>
It's used to test the sniff that detects and bans evals.
The tests are shipped in version 3 but have been removed in version 4 as this is a BC break.
Closing this as there is no change I can make to version 3 to resolve this.