Allow specifying the ban bruteforcers limit in extmodule.conf

git-svn-id: http://yate.null.ro/svn/yate/trunk@5052 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
paulc 2012-05-09 15:41:29 +00:00
parent 7d2f54a20f
commit e12737a6e3
1 changed files with 7 additions and 0 deletions

View File

@ -27,6 +27,9 @@
[scripts]
banbrutes.php=
or
banbrutes.php=NNN
where NNN >= 2 is the number of failures causing a ban
*/
// How many failures in a row cause a ban
@ -268,6 +271,10 @@ Yate::Output(true);
// Uncomment the next line to get debugging details
//Yate::Debug(true);
$n = round(1 * Yate::Arg());
if ($n >= 2)
$ban_failures = $n;
Yate::Watch("user.auth");
Yate::Install("user.authfail",120);
Yate::Install("engine.timer",150);