Commit Graph

1991 Commits (a63b834c8c66ff3aa8844a2a9e5c5f361383ec58)

Author SHA1 Message Date
David a63b834c8c Update datetemplate.py to add spanish month names
In order to correctly detect the spanish months it's mandatory to add their names in the dictionary table, as should be done with the rest of the supported languages (http://lh.2xlibre.net/values/abmon/)
2015-08-28 08:26:24 +02:00
Yaroslav Halchenko 51fc3d7642 Merge pull request #1014 from opoplawski/0.8-ignoreregex
Add missing ignoreregex lines to avoid warnings
2015-04-07 21:33:51 -04:00
Orion Poplawski da568d73fa Add missing ignoreregex lines to avoid warnings 2015-04-06 16:47:44 -06:00
Yaroslav Halchenko 9deafe6355 BF: adjusted for new IP of example.com 2014-12-21 21:40:58 -05:00
Yaroslav Halchenko 4bd929ffa8 prepare to accept more fixes 2014-08-19 16:29:13 -04:00
Yaroslav Halchenko 254b57e43b Version changes/man pages for the release 2014-08-19 16:23:33 -04:00
Yaroslav Halchenko f39c778a97 changelog and thanks for the preceding fix 2014-07-28 12:46:52 -04:00
Jisoo Park 094b0e651a Fix sieve filter to use correct option 2014-07-28 12:44:42 -04:00
Steven Hiscocks 09b2016c05 TST: Skip SYSLOG log target test if '/dev/log' not present
Conflicts:
	testcases/servertestcase.py -- probably jumped over another commit in this cherry-pick which resulted in conflict
2014-04-24 12:24:57 -04:00
Steven Hiscocks 3a1a1f3ad7 Merge branch 'yarikoptic/bf/recidive-mail' into 0.8
Conflicts:
	ChangeLog
        - Additions in both branches kept
2014-04-18 23:00:46 +01:00
Yaroslav Halchenko 5edc60934d DOC: a note in TODO to refer to issues 2014-04-18 10:11:57 -04:00
Yaroslav Halchenko 4fea9dde8d DOC: minor (just to trigger rebuild) 2014-04-17 23:22:17 -04:00
Yaroslav Halchenko c82eb16f3d DOC: minor changes just to trigger the build 2014-04-17 14:41:14 -04:00
yungchin dbf6cff032 Update comments in shorewall.conf for new settings 2014-04-17 12:06:16 -04:00
Yaroslav Halchenko 30bc782b18 BF: grep in mail*-whois-lines.conf also matches beginning/end of line to work with the recidive filter (Debian #744774)
Thanks James Bottomley for the report and tentative solutions
2014-04-16 22:20:22 -04:00
Steven Hiscocks b89222b1d1 Merge pull request #696 from yarikoptic/bf/skip_apache_subsecond_resolution_on_2.5
BF(2.5): add minimal_python key to failJSON and skip some test lines.
2014-04-16 22:43:28 +01:00
Steven Hiscocks 2874399fed Merge pull request #694 from yarikoptic/bf/fix_move_test
a collection of fixes, including the one log rotation detection which "broke travis"
2014-04-16 22:28:42 +01:00
Yaroslav Halchenko 5bafc61e48 ENH(TST): relax test of sleep to "1" places from "2"
The reason is that internally it does round, so even 1.005 then would not
be equal to 1.  Making it spaces==1 should be sufficient for up to 1.05
i.e. we would allow 50ms "drift"
2014-04-16 13:17:58 -04:00
Yaroslav Halchenko d7087412bb Add .dev suffix to the version to signal "development" build 2014-04-16 13:12:39 -04:00
Yaroslav Halchenko c5a754411d BF(2.5): add minimal_python key to failJSON and skip some test lines with date format which includes sub-seconds
For tests to pass also duplicated representative ones just without subsec timing
2014-04-16 10:51:24 -04:00
Yaroslav Halchenko 8faff41d40 DOC: changelog entry on leaky file descriptors 2014-04-16 08:48:52 -04:00
Yaroslav Halchenko 6eb67899a5 BF: overcome problem with failed *_movefile test if file gets properly closed
Discussion is in the comments on 7260403fdd
and fix consists of skipping first 3 lines while creating a "new" log file.
This should be sufficient to make fail2ban detect "log rotation" and thus
function properly
2014-04-16 08:43:54 -04:00
Yaroslav Halchenko dfc7dd6dc9 ENH: use unique filename in LogFileFilterPoll on every setUp call 2014-04-16 08:26:39 -04:00
Yaroslav Halchenko e19f9e1697 BF(?): stop/join notifier only if defined
Somehow on that elderly squeeze Debian sparc box, I got error that self.__notifier
was not defined.  So first I did define it now in the constructor, but mystery remains
how come it was not defined -- wasn"t run() then run (where it is defined)?

Anyways -- conditioning on it being defined might be safer may be?
Not sure (need to go to sleep) if with this change but on this box I also run from time
to time either into stalling of fail2ban-testcases and refusing to exit normally or

======================================================================
ERROR: test_move_into_file_after_removed (testcases.filtertestcase.MonitorFailures<FilterPyinotify>(/tmp/monitorfailures_FilterPyinotifypcHmMJfail2ban))
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/yoh/deb/gits/fail2ban/testcases/filtertestcase.py", line 473, in tearDown
    self.filter.stop()
  File "/home/yoh/deb/gits/fail2ban/server/filterpyinotify.py", line 196, in stop
    self.__notifier.stop()
  File "/usr/lib/pymodules/python2.6/pyinotify.py", line 1315, in stop
    threading.Thread.join(self)
  File "/usr/lib/python2.6/threading.py", line 633, in join
    raise RuntimeError("cannot join thread before it is started")
RuntimeError: cannot join thread before it is started

that is with pyinotify 0.8.9-1 so could quite be "related" to its age.
2014-04-16 08:26:38 -04:00
Yaroslav Halchenko cb9cbd754e DOC: minor wording fix 2014-04-16 08:26:38 -04:00
Yaroslav Halchenko f206c3d493 BF: give a custom prefix to a tempfile and close it upon tearDown in ExecuteActions tests 2014-04-16 08:26:38 -04:00
Yaroslav Halchenko 8cb6ec54ac Merge pull request #691 from yarikoptic/enh/travis_multiple_log_levels
ENH: run travis with both 'error' and 'heavydebug' levels to ease troubleshooting of failures
2014-04-16 00:50:54 -04:00
Yaroslav Halchenko a45467ac91 ENH: run travis with both 'error' and 'heavydebug' levels to ease troubleshooting of failures 2014-04-15 23:40:09 -04:00
Steven Hiscocks 5c2730d7be DOC: Update ChangeLog 2014-04-03 19:03:05 +01:00
Steven Hiscocks 7260403fdd TST: Close file to allow proper removal in MonitorFailures 2014-03-31 19:02:28 +01:00
Daniel Black 2a31d45582 Merge pull request #669 from kwirk/inotify-watch-auto-remove
BF: Handle case when inotify watch is auto deleted on file deletion
2014-03-31 18:37:01 +11:00
Steven Hiscocks fdcded262d BF: Handle case when inotify watch is auto deleted on file deletion
When a file is deleted, the watcher for it is automatically removed.
FilterPyinotify is detecting a new file being created with the same
name, and in turn attempts to remove the watch for the deleted file
(which has already been removed automatically).

Also, IN_IGNORED events are generated when a file is deleted, but these
weren't being caught, causing an non-existent file path to be passed to
FilterPyinotify._process_file (which caught the exceptions in
Filter.getFailures).
2014-03-29 16:38:39 +00:00
Daniel Black dfac2f700a Merge pull request #647 from yarikoptic/0.8
Minor fixes for claimed compatibility with 2.4 and 2.5 -- not to be "merged" into 0.9
2014-03-17 08:36:59 +11:00
Yaroslav Halchenko bb2d981bf8 Changelog entry 2014-03-16 11:25:12 -04:00
Yaroslav Halchenko 18b476a93e BF(PY2.4,2.5): provide bin() function (introduced in 2.6) 2014-03-16 11:15:00 -04:00
Yaroslav Halchenko 9cbb472478 BF: python 2.4 and 2.5 compatibility -- no "except ... as ..." yet 2014-03-16 10:35:58 -04:00
Daniel Black a8d0cc9af8 DOC: remove duplicate update of Fail2ban_Version 2014-03-15 21:59:22 +11:00
Daniel Black eb66edd338 DOC: DEVELOP release note changes 2014-03-15 19:14:36 +11:00
Daniel Black cee3414029 PKG: version release 2014-03-15 19:06:37 +11:00
Daniel Black 0601a07961 PKG: include nagios filter/log 2014-03-15 19:06:18 +11:00
Daniel Black 123791c94c DOC/ENH: update man pages for release 2014-03-15 18:52:18 +11:00
Daniel Black 77fda9498c ENH: pull asterisk filter change to support syslog from 0.9 branch 2014-03-14 23:15:46 +11:00
Daniel Black c3a2e8fbac Merge pull request #644 from hlein/master
ENH: Changes to --print-* options and memory use for fail2ban-regex
2014-03-14 22:32:41 +11:00
Hank Leininger 2deb1b71a1
Sanity-check print-all-* vs print-no-* options.
Also, fixed a trivial whitespace issue.
2014-03-14 02:10:00 -04:00
Hank Leininger d4fb48fd14
Add --print-no-{missed,ignored} and restore -all.
Realized --print-all-{missed,ignored} aren't meant to be simple on/off,
but are meant to enable printing all lines even when there are more
than 20.

This restores the behavior of --print-all-*, but preserves the
memory-savings when --print-all-* are not specified.

Also adds --print-no-{missed,ignored} which can be used to suppress
printing of a line type entirely.
2014-03-14 01:57:55 -04:00
Hank Leininger aa7af6f9c2
Only remember log lines we need to print later.
When testing proccessing a large logfile (430 MB, 2M lines) without
--print-all-missed or --print-all-ignored, fail2ban-regex consumes
just over 2 GB of RAM before completing.  Even though it does not need
to retain any of the missed or ignored log lines, it does anyway.

With this patch, memory use never grows beyond about 11 MB (unless
--print-all-* are enabled).
2014-03-13 23:18:08 -04:00
Hank Leininger 27dafea281
Fix the --print-all-{missed,ignored} options.
Previously, fail2ban-regex always printed both regardless of whether
those options were present or not.

This commit duplicates the patch I submitted at
https://sourceforge.net/p/fail2ban/patches/25/
2014-03-13 22:47:28 -04:00
Daniel Black 415f187644 ENH: sendmail-reject for all smtp ports. 2014-03-14 07:12:12 +11:00
Daniel Black 11fc7941f5 Merge pull request #633 from grooverdan/sendmail
MRG: Sendmail filter
2014-03-02 14:25:26 +11:00
Daniel Black 853bed8e4f ENH: more sendmail-reject filter items thanks to fab23 2014-03-02 14:04:27 +11:00