3x Bad Pass cleaner
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

3x Bad Pass cleaner

Started by Dessamator, 23 March, 2005, 23:06:50

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Dessamator

--Requested by blackwings 
--Made by nErBoS
--lua 5 by Dessamator
sBot = "Bad Password Cleaner"

fPermBan = "../PermBan.dat"
arrAux = {}
sec = 1000
min = 60*sec
hour = 60*min
iTime = 15*min-- Checking Time

function Main()
frmHub:RegBot(sBot)
SetTimer(iTime)
StartTimer()
end

function OnTimer()
CheckForBan()
CleanBan()
end

function CheckForBan()
	local file = io.input(fPermBan)
	for sLine in file:lines() do
		if (sLine == nil) then
	break
	else
	local s,e,ip,reason = string.find(sLine, "(%S+)|(%S+%s+%S+%s+%S+)")
			if (ip ~= nil and reason ~= nil and reason == "3x bad password") then
		arrAux[ip] = 1
			end
		end
	end
file:close()
end

function CleanBan()
	local ip,aux
	for ip, aux in arrAux do
		Unban(ip)
	end
end
 
Ignorance is Bliss.

dragos_sto

dont work whit ptoka server 0.3.3.0  build 16.06
error
)
Syntax \scripts\passwordcleaner.lua:25: bad argument #1 to `input' (../PermBan.dat: Permission denied
)

Typhoon

check the Lua 5 script database at

             http://ptokaxscripts.sytes.net


Typhoon?



Dessamator

#3
yaps i had fixed that error before, but i think i was kinda tired when i posted that, :D, error corrected, post edited up there, or u can,
Quotecheck the Lua 5 script database at     http://ptokaxscripts.sytes.net       Typhoon

more specifically::
Quotehttp://ptokaxscripts.sytes.net/e107_files/public/baddpassbanremover.lua
Ignorance is Bliss.

SMF spam blocked by CleanTalk