diff options
| author | Julien (jvoisin) Voisin | 2016-05-11 13:18:51 +0200 |
|---|---|---|
| committer | Julien (jvoisin) Voisin | 2016-05-11 13:18:51 +0200 |
| commit | 00d3bd072796336a7b243eb11a74412ef9c15b1f (patch) | |
| tree | a0eebc5cc45e98f3211f7fa30c36e63cce56ce35 | |
| parent | a16357a56653edc2aa0dc769a3df0bb4268dab94 (diff) | |
Fix the tests
| -rwxr-xr-x | php-malware-finder/tests.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/php-malware-finder/tests.sh b/php-malware-finder/tests.sh index 3aaceea..42c2456 100755 --- a/php-malware-finder/tests.sh +++ b/php-malware-finder/tests.sh | |||
| @@ -3,6 +3,8 @@ | |||
| 3 | PMF=./phpmalwarefinder | 3 | PMF=./phpmalwarefinder |
| 4 | SAMPLES=./samples | 4 | SAMPLES=./samples |
| 5 | 5 | ||
| 6 | type yara 2>/dev/null 1>&2 || (echo "[-] Please make sure that yara is installed" && exit 1) | ||
| 7 | |||
| 6 | CPT=0 | 8 | CPT=0 |
| 7 | run_test(){ | 9 | run_test(){ |
| 8 | NB_DETECTED=$(${PMF} -v "$SAMPLES"/"$1" | grep -c "$2" 2>/dev/null) | 10 | NB_DETECTED=$(${PMF} -v "$SAMPLES"/"$1" | grep -c "$2" 2>/dev/null) |
| @@ -32,11 +34,9 @@ run_test freepbx.php 'DodgyPhp' | |||
| 32 | run_test freepbx.php '0x31d:$execution: system(base64_decode' | 34 | run_test freepbx.php '0x31d:$execution: system(base64_decode' |
| 33 | 35 | ||
| 34 | # Classic shells | 36 | # Classic shells |
| 35 | run_test classic/ajaxshell.php 'ObfuscatedPhp' | ||
| 36 | run_test classic/ajaxshell.php 'DodgyStrings' | 37 | run_test classic/ajaxshell.php 'DodgyStrings' |
| 37 | run_test classic/ajaxshell.php 'Websites' | 38 | run_test classic/ajaxshell.php 'Websites' |
| 38 | run_test classic/ajaxshell.php '0x23e2:$: shell_exec' | 39 | run_test classic/ajaxshell.php '0x23e2:$: shell_exec' |
| 39 | run_test classic/ajaxshell.php '0x2380:$eval: {\\x0A\\x09\\x09\\x09\\x09\\x09system(' | ||
| 40 | run_test classic/ajaxshell.php "0x16e0:\$ini_get: ini_get('safe_mode" | 40 | run_test classic/ajaxshell.php "0x16e0:\$ini_get: ini_get('safe_mode" |
| 41 | run_test classic/ajaxshell.php "0x17f1:\$ini_get: ini_get('open_basedir" | 41 | run_test classic/ajaxshell.php "0x17f1:\$ini_get: ini_get('open_basedir" |
| 42 | run_test classic/angel.php '0x1d:$disable_magic_quotes:' | 42 | run_test classic/angel.php '0x1d:$disable_magic_quotes:' |
