<!-- @(#) $Id: ./etc/rules/telnetd_rules.xml, 2011/09/08 dcid Exp $

  -  Telnetd rules for OSSEC.
  -  Author: Ahmet Ozturk
  -  License: http://www.ossec.net/en/licensing.html
  -->
      

<group name="syslog,telnetd">
  <rule id="5600" level="0" noalert="1">
    <match>telnetd</match>
    <description>Grouping for the telnetd rules</description>
  </rule>

  <rule id="5601" level="5">
    <if_sid>5600</if_sid>
    <match>refused connect from </match>
    <description>Connection refused by TCP Wrappers.</description>
  </rule>

  <rule id="5602" level="3">
    <if_sid>5600</if_sid>
    <match>: connect from </match>
    <description>Remote host established a telnet connection.</description>
  </rule>

  <rule id="5603" level="5" timeframe="1">
    <match>ttloop:  peer died:|ttloop:  read:</match>
    <if_matched_sid>5602</if_matched_sid>
    <description>Remote host invalid connection.</description>
  </rule>

  <rule id="5604" level="5">
    <match>warning: can't verify hostname:</match>
    <description>Reverse lookup error (bad hostname config).</description>
  </rule>

  <rule id="5631" level="10" frequency="6" timeframe="120">
    <if_matched_sid>5602</if_matched_sid>
    <same_source_ip />
    <description>Multiple connection attempts from same source </description>
    <description>(possible scan).</description>
  </rule>

</group> <!-- SYSLOG,TELNETD -->
