Imported Upstream version 2.7
[ossec-hids.git] / etc / rules / pam_rules.xml
1 <!-- @(#) $Id: ./etc/rules/pam_rules.xml, 2012/07/23 dcid Exp $
2
3   -  Official Unix Pam 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="pam,syslog,">
18   <rule id="5500" level="0" noalert="1">
19     <decoded_as>pam</decoded_as>
20     <description>Grouping of the pam_unix rules.</description>
21   </rule>
22   
23   <rule id="5501" level="3">
24     <if_sid>5500</if_sid>
25     <match>session opened for user </match>
26     <description>Login session opened.</description>
27     <group>authentication_success,</group>
28   </rule>
29
30   <rule id="5502" level="3">
31     <if_sid>5500</if_sid>
32     <match>session closed for user </match>
33     <description>Login session closed.</description>
34   </rule>
35  
36   <rule id="5503" level="5">
37     <if_sid>5500</if_sid>
38     <match>authentication failure; logname=</match>
39     <description>User login failed.</description>
40     <group>authentication_failed,</group>
41   </rule> 
42  
43   <rule id="5504" level="5">
44     <if_sid>5500</if_sid>
45     <match>check pass; user unknown</match>
46     <description>Attempt to login with an invalid user.</description>
47     <group>invalid_login</group>
48   </rule> 
49
50   <!-- Ignoring Annoying Ubuntu/debian cron login events. -->
51   <rule id="5521" level="0">
52     <if_sid>5501</if_sid>
53     <program_name>^CRON$</program_name>
54     <match>^pam_unix(cron:session): session opened for user </match>
55     <description>Ignoring Annoying Ubuntu/debian cron login events.</description>
56   </rule>
57   
58   <rule id="5522" level="0">
59     <if_sid>5502</if_sid>
60     <program_name>^CRON$</program_name>
61     <match>^pam_unix(cron:session): session closed for user </match>
62     <description>Ignoring Annoying Ubuntu/debian cron login events.</description>
63   </rule>
64
65   <rule id="5523" level="0">
66     <if_sid>5504</if_sid>
67     <regex>^pam_unix\S+: check pass; user unknown$</regex>
68     <description>Ignoring events with a user or a password.</description>
69   </rule>
70
71   <rule id="5551" level="10" frequency="6" timeframe="180">
72     <if_matched_sid>5503</if_matched_sid>
73     <same_source_ip />
74     <description>Multiple failed logins in a small period of time.</description>
75     <group>authentication_failures,</group>
76   </rule>
77
78   <rule id="5552" level="0">
79     <if_sid>5500</if_sid>
80     <match>gdm:auth): conversation failed</match>
81     <description>PAM and gdm are not playing nicely.</description>
82   </rule>
83
84    <rule id="5553" level="4">
85     <program_name>login</program_name>
86     <match>cannot open shared object file: No such file or directory</match>
87     <description>PAM misconfiguration.</description>
88   </rule>
89
90   <rule id="5554" level="4">
91     <program_name>login</program_name>
92     <match>illegal module type: </match>
93     <description>PAM misconfiguration.</description>
94   </rule>
95
96   <rule id="5555" level="3">
97     <match>: password changed for</match>
98     <description>User changed password.</description>
99   </rule>
100
101
102 </group> <!-- SYSLOG,pam -->
103
104
105 <!-- EOF -->