Skip to content

Commit 6cdf0e1

Browse files
committed
cleanup: comment out too broad patterns
1 parent c410f12 commit 6cdf0e1

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

scan.php

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@
6363
'/fwrite\s*\(/i', // Writes to file
6464
'/fread\s*\(/i', // Reads from file
6565
'/file_put_contents\s*\(/i', // Writes to file
66-
'/file_get_contents\s*\(/i', // Reads from file
6766
'/unlink\s*\(/i', // Deletes file
6867
'/rename\s*\(/i', // Renames file
6968
'/file_get_contents\s*\(\s*("|\')https?:\/\//i', // Remote file inclusion
@@ -132,16 +131,16 @@
132131
// Shell tricks
133132
'/`.*`/i', // Backticks suggest suspicious shell exec usage
134133
'/backdoor/i', // Indicates potential backdoor
135-
'/shell/i', // Indicates shell commands
136-
'/cmd/i', // Indicates command execution
134+
// '/shell/i', // Indicates shell commands
135+
// '/cmd/i', // Indicates command execution
137136

138137
// WP specific
139138
'/add_action\s*\(.*base64_decode/i', // Obfuscated code in WP hook
140139
'/add_filter\s*\(.*eval/i', // Code execution in WP filter
141140
'/wp_eval_request\s*\(/i', // Known malicious plugin pattern
142141
'/\$GLOBALS\s*\[\s*["\']wp_filter["\']\s*\]/i', // Manipulates WP global hooks
143-
'/functions\.php/i', // Indicates direct theme function manipulation
144-
'/wp-config\.php/i', // Indicates tampering with configuration
142+
// '/functions\.php/i', // Indicates direct theme function manipulation
143+
// '/wp-config\.php/i', // Indicates tampering with configuration
145144

146145
// Dynamic inclusion (too many false positives)
147146
// '/include\s*\(/i',

0 commit comments

Comments
 (0)