This post is an echo on the previous post which describes how to configure snort to detect SIP attacks. This time we look at detecting attacks at the PBX's end rather than by monitoring network traffic. OSSEC allows us to do just this - it is a host intrusion detection system that can do matching on log files and actively react to attack.<include>asterisk.xml</include>
<decoder name="asterisk">
<program_name>^asterisk</program_name>
</decoder>
<decoder name="asterisk-denied">
<parent>asterisk</parent>
<prematch>Registration from </prematch>
<regex offset="after_prematch">failed for '(\d+.\d+.\d+.\d+)'</regex>
<order>srcip</order>
</decoder>
/etc/init.d/ossec restartFinally - it is important to make sure that Asterisk is configured to log to syslog and restarted. The next commands to execute are:
echo "syslog.local0 => notice,warning,error" >> /etc/asterisk/logger.confNote: Check out Laureano's post on how to just reload the logger configuration.
/etc/init.d/asterisk restart
This post is an echo on the previous post which describes how to configure snort to detect SIP attacks. This time we look at detecting attacks at the PBX's end rather than by monitoring network traffic. OSSEC allows us to do just this - it is a host intrusion detection system that can do matching on log files and actively react to attack.<include>asterisk.xml</include>
<decoder name="asterisk">
<program_name>^asterisk</program_name>
</decoder>
<decoder name="asterisk-denied">
<parent>asterisk</parent>
<prematch>Registration from </prematch>
<regex offset="after_prematch">failed for '(\d+.\d+.\d+.\d+)'</regex>
<order>srcip</order>
</decoder>
/etc/init.d/ossec restartFinally - it is important to make sure that Asterisk is configured to log to syslog and restarted. The next commands to execute are:
echo "syslog.local0 => notice,warning,error" >> /etc/asterisk/logger.confNote: Check out Laureano's post on how to just reload the logger configuration.
/etc/init.d/asterisk restart
This post is an echo on the previous post which describes how to configure snort to detect SIP attacks. This time we look at detecting attacks at the PBX's end rather than by monitoring network traffic. OSSEC allows us to do just this - it is a host intrusion detection system that can do matching on log files and actively react to attack.<include>asterisk.xml</include>
<decoder name="asterisk">
<program_name>^asterisk</program_name>
</decoder>
<decoder name="asterisk-denied">
<parent>asterisk</parent>
<prematch>Registration from </prematch>
<regex offset="after_prematch">failed for '(\d+.\d+.\d+.\d+)'</regex>
<order>srcip</order>
</decoder>
/etc/init.d/ossec restartFinally - it is important to make sure that Asterisk is configured to log to syslog and restarted. The next commands to execute are:
echo "syslog.local0 => notice,warning,error" >> /etc/asterisk/logger.confNote: Check out Laureano's post on how to just reload the logger configuration.
/etc/init.d/asterisk restart
This post is an echo on the previous post which describes how to configure snort to detect SIP attacks. This time we look at detecting attacks at the PBX's end rather than by monitoring network traffic. OSSEC allows us to do just this - it is a host intrusion detection system that can do matching on log files and actively react to attack.<include>asterisk.xml</include>
<decoder name="asterisk">
<program_name>^asterisk</program_name>
</decoder>
<decoder name="asterisk-denied">
<parent>asterisk</parent>
<prematch>Registration from </prematch>
<regex offset="after_prematch">failed for '(\d+.\d+.\d+.\d+)'</regex>
<order>srcip</order>
</decoder>
/etc/init.d/ossec restartFinally - it is important to make sure that Asterisk is configured to log to syslog and restarted. The next commands to execute are:
echo "syslog.local0 => notice,warning,error" >> /etc/asterisk/logger.confNote: Check out Laureano's post on how to just reload the logger configuration.
/etc/init.d/asterisk restart