Imported Upstream version 2.7
[ossec-hids.git] / etc / rules / php_rules.xml
1 <!-- @(#) $Id: ./etc/rules/php_rules.xml, 2012/05/09 dcid Exp $
2
3   -  Official PHP rules for OSSEC.
4   -
5   -  Copyright (C) 2009 Trend Micro Inc.
6   -  All rights reserved.
7   -
8   -  This program is a free software; you can redistribute it
9   -  and/or modify it under the terms of the GNU General Public
10   -  License (version 2) as published by the FSF - Free Software
11   -  Foundation.
12   -
13   -  License details: http://www.ossec.net/en/licensing.html
14   -->
15                         
16
17 <group name="apache,">
18   <rule id="31401" level="0">
19     <if_sid>31301, 30101</if_sid>
20     <match>PHP Warning: </match>
21     <description>PHP Warning message.</description>
22   </rule>    
23
24   <rule id="31402" level="0">
25     <if_sid>31301, 30101</if_sid>
26     <match>PHP Fatal error: </match>
27     <description>PHP Fatal error.</description>
28   </rule>    
29
30   <rule id="31403" level="0">
31     <if_sid>31301, 30101</if_sid>
32     <match>PHP Parse error:</match>
33     <description>PHP Parse error.</description>
34   </rule>    
35
36   <rule id="31404" level="0">
37     <match>^PHP Warning: </match>
38     <description>PHP Warning message.</description>
39   </rule>    
40
41   <rule id="31405" level="0">
42     <match>^PHP Fatal error: </match>
43     <description>PHP Fatal error.</description>
44   </rule>    
45
46   <rule id="31406" level="0">
47     <match>^PHP Parse error: </match>
48     <description>PHP Parse error.</description>
49   </rule>    
50
51
52   <!-- PHP Warnings 
53     - PHP Warning:  urlencode() expects parameter 1 to be string, array given in
54     -->
55   <rule id="31410" level="3">
56     <if_sid>31401, 31404</if_sid>
57     <description>PHP Warning message.</description>
58   </rule>
59
60   <rule id="31411" level="6">
61     <if_sid>31410</if_sid>
62     <match> expects parameter 1 to be string, array given in</match>
63     <group>attack,</group>
64     <description>PHP web attack.</description>
65   </rule>
66
67   <rule id="31412" level="5">
68     <if_sid>31410</if_sid>
69     <match>Failed opening|failed to open stream</match>
70     <description>PHP internal error (missing file).</description>
71     <options>alert_by_email</options>
72   </rule>
73
74   <rule id="31413" level="5" ignore="1200">
75     <if_sid>31410</if_sid>
76     <match>bytes written, possibly out of free disk space in</match>
77     <description>PHP internal error (server out of space).</description>
78     <options>alert_by_email</options>
79     <group>low_diskspace,</group>
80   </rule>
81
82
83   <!-- PHP Fatal errors
84     - PHP Fatal error:  require_once() [<a href='function.require'>function.require</a>]: Failed opening require
85 d 'includes/SkinTemplate.php'
86     -->
87   <rule id="31420" level="5">
88     <if_sid>31402, 31405</if_sid>
89     <description>PHP Fatal error.</description>
90   </rule>
91
92   <rule id="31421" level="5">
93     <if_sid>31420</if_sid>
94     <match>Failed opening required |Call to undefined function </match>
95     <description>PHP internal error (missing file or function).</description>
96     <options>alert_by_email</options>
97   </rule>
98
99
100
101   <!-- PHP Parse error -->
102   <rule id="31430" level="5">
103     <if_sid>31403, 31406</if_sid>
104     <description>PHP Parse error.</description>
105     <options>alert_by_email</options>
106   </rule>
107
108 </group> <!-- ERROR_LOG, PHP -->
109
110 <!-- EOF -->
111