Skip to content

Commit

Permalink
fix: improve signature optimization for raw contents
Browse files Browse the repository at this point in the history
  • Loading branch information
Marco Cesarato committed Mar 31, 2021
1 parent 3d91eae commit 0c55dbb
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Signatures.php
Expand Up @@ -357,6 +357,9 @@ class Signatures
'find / \-type f \-name \.htpasswd',
'find / \-type f \-perm \-02000 \-ls',
'find / \-type f \-perm \-04000 \-ls',
'find / -type f -name .htpasswd',
'find / -type f -perm -02000 -ls',
'find / -type f -perm -04000 -ls',
"if(''==(\$df=@ini_get('disable_functions",
'ncftpput -u',
'wsoEx(',
Expand Down Expand Up @@ -3521,6 +3524,7 @@ public static function getAll()
$raw = self::$raw;
foreach ($raw as &$pattern) {
$pattern = preg_quote($pattern, '#');
$pattern = str_replace([' ', "'", '"'], ['[\s]*', '[\'"]', '[\'"]'], $pattern);
}
$optimized = array_merge($optimized, $raw);
self::optimizeSignatures($optimized);
Expand Down

0 comments on commit 0c55dbb

Please sign in to comment.