EVENTPROTECT(1)

NAME
eventProtect - Parametric Script

SYNOPSIS
eventProtect EVT_NAME REG_EXPRESSION RANGE EVT_BOUND RED_BOUND FREQ_EMAIL ALLOWED_FILE NOTIFY FILTER

DESCRIPTION
It is used to apply rules specified in configuration's file /etc/aLid/aLid.conf

OPTIONS

EVT_NAME
    It specifics the event's name in which is associated a rule. The name of event allows to indenfy the rule, that send a notific or drop's rule. The name of event is unambiguous in all rules.

REG_EXPRESSION
    A regular expression allows to verify the presence of specified character inside of each line of file in input. When a file's line matches the regular expression so it is considered as presentation of monitored event.

RANGE
    It is the value, in seconds, of the temporal window to analyze. If N is the value of range, the temporal window to analyze is [ NOW - N , NOW ].

EVT_BOUND
    It's the maximun number of times that the found event can verifies inside of temporal window(RANGE). Source ip, findable on log file, is considered responsible. At the overcoming of threshold, depending on configuration, can block source ip or simply notify what is happened. If an ip is blocked, there is also a mark of the moment in which it happens with reference to universal time (UTC) in seconds.

RED_BOUND
    It is the number of seconds in which an blocked ip can't communicate through machine where is installed the program. When the redemption's source is reached blocked ip is unlocked. The overcoming is calculated in the following way:

            IF ( NOW - BLOCKING_TIME > RED_BOUNG )
                    UNLOCK BLOCKED IP
            ELSE
                    BLOCKED IP REMAINS BLOCKED

FREQ_EMAIL
    It specifics the attendance of send of notifics mail in seconds. It's optional and subordinate at the presence of options MAIL or LOG.

ALLOWED_FILE
    It is file's path where are listed allowed ip. If is detected an event with ip present in ALLOWED_FILE so event is ignored. File must respect following syntattic rule: every rule must contains only an ip.

NOTIFY There are 4 kinds of notific option: MAIL, LOG, ALL, NOTHING.
    MAIL
        Send a notific email to alla addresses specified on file /etc/aLid/email.conf

    LOG Allow to write a line on log file of application.

    ALL Include both notify's typologies MAIL e LOG.

    NOTHING
        No nothification

FILTER
    It specifics the policy to adopt considering ip detected. Options accepted are: DROP and NODROP.

    DROP
        It block detected ip in the firewall applying a specific rule.

    NODROP
        It doesn't execute a rule of drop in the firewall.

NOTES
Script reads of input file indicated in the rule through stream <STDIN>.

EXAMPLES

eventProtect SPAMMING 5 10 5 7 /etc/aLid/ip_allowed_SPAMMING all drop
    It executes script with SPAMMING as event name, using a range of 5 seconds, 10 maximum attempts in temporal window, 5 seconds as redemption threshold, 7 seconds is mail's frequency, ip_allowed_SPAMMING is the name of file used to specified immunes ip at event, all is notific's typology and drop is the kind of filter.

FILES

/etc/aLid/aLid.conf
    Configuration's file of the application.

REQUIREMENT

arpwatch
    Arpwatch - http://www.securityfocus.com/tools/142

DateTime
    DateTime - Perl Library of cpan community

SEE ALSO
sharedTail, aLid, aLid.conf

AUTHOR
Andrea Martire (andreamartire@gmail.com)

COPYRIGHT AND LICENSE
Copyright AX 2010 Andrea Martire <andreamartire@gmail.com>. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.