summaryrefslogtreecommitdiff
path: root/run_tests.sh
diff options
context:
space:
mode:
Diffstat (limited to 'run_tests.sh')
-rwxr-xr-xrun_tests.sh30
1 files changed, 0 insertions, 30 deletions
diff --git a/run_tests.sh b/run_tests.sh
deleted file mode 100755
index 3ad2ea1..0000000
--- a/run_tests.sh
+++ /dev/null
@@ -1,30 +0,0 @@
1#!/bin/bash
2
3# <? system($_GET['p']);
4# $___ $___ $_____ $_____ $____ $___
5# ZXhlYyg
6# system php_uname posix_setuid phpinfo exec eval
7# /etc/passwd WinExec uname -a nc -l
8# 1337day.com
9
10echo '[+] Testing scanning engine'
11EXPECTED='ObfuscatedPhp run_tests.sh
12SuspiciousEncoding run_tests.sh
13DodgyPhp run_tests.sh
14DangerousPhp run_tests.sh
15DodgyStrings run_tests.sh
16Websites run_tests.sh'
17RESULT="$(./phpmalwarefinder -c ./malwares.yara run_tests.sh)"
18if [ "$RESULT" != "$EXPECTED" ] ; then
19 diff <(echo "$RESULT") <(echo "$EXPECTED")
20 exit 1
21fi
22
23echo '[+] Testing on non-existing rules'
24EXPECTED="./nonexistentfile doesn't exist. Please give me a valid file."
25RESULT="$(./phpmalwarefinder -c ./nonexistentfile run_tests.sh)"
26if [ "$RESULT" != "$EXPECTED" ] ; then
27 diff <(echo "$RESULT") <(echo "$EXPECTED")
28 exit 1
29fi
30