added: IP ban mechanism (not finished yet -- we need a winix function to remove a ban)
now after some incorrent login attempts your IP can be banned or blocked (see new config variables) git-svn-id: svn://ttmath.org/publicrep/winix/trunk@902 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
@@ -20,6 +20,7 @@
|
||||
#include "rebus.h"
|
||||
#include "textstream.h"
|
||||
#include "date/date.h"
|
||||
#include "ipban.h"
|
||||
|
||||
|
||||
|
||||
@@ -50,7 +51,7 @@ struct Session
|
||||
PT::Date last_date;
|
||||
|
||||
// when there was a last get request
|
||||
// (used to calculate spam)
|
||||
// (used to calculate spam or invalid login attempts etc.)
|
||||
time_t last_time_get;
|
||||
|
||||
|
||||
@@ -84,6 +85,11 @@ struct Session
|
||||
// used by some javascript wysiwyg editors (ckeditor, tinymce)
|
||||
std::vector<std::wstring> last_css;
|
||||
|
||||
// pointer to IPBan struct if exists for this IP
|
||||
// many sessions can pointer to the same IPBan struct
|
||||
// (it can be null)
|
||||
IPBan * ip_ban;
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user