How to find unwanted files, always.
 

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

How to find unwanted files, always.

Started by VERMiN, 16 November, 2003, 11:34:19

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

VERMiN

I', still on the lookout for a great script which detect unwanted files. LatinMusic was kind enough to provide me with this fine script.

The only problem is that it doesn't always discover a "badshare".
I have several machines connected to my testhub, and all of them have c:\windows and c:\program shared
but the script will only detect badshares from time to time. Can this script be altered to be more accurate and
trusted?
- Also if somebody can tell me how to move out the defined "bad files" to an external file instead. This will make it a lot easier to add files to the for example UnWanted.txt file-list.


-- BadFilesDetecter V: 1.0 by [ES]latinmusic. Date: 05/11/2003
-- Base on Illegalist by Ptaczek, Jan-3, 2003
-- Searches for specified patterns. Useful for illegal share checking
-- Modificed by Leo (for music hub)
-- Modified by nErBoS
-- Operators are now checked as normal users
-- Some extensions added
-- All known bugs fixed by ----------->>> OpiumVolage
 
BotName = "![BadFilesDetecter]!?"
MessageToSend = " are not allowed in this hub."
time = 3 --Value in minutes
Files = {
[".dll"]="No .dll files in this hub, you have been banned for "..time.." minutes.",
[".sys"]="No .sys files in this hub, you have been banned for "..time.." minutes.",
[".ini"]="No .ini files in this hub, you have been banned for "..time.." minutes.",
[".php"]="No .php files in this hub, you have been banned for "..time.." minutes.",
[".hlp"]="No .hlp files in this hub, you have been banned for "..time.." minutes.",
[".lnk"]="No .lnk files in this hub, you have been banned for "..time.." minutes.",
[".cue"]="No .cue files in this hub, you have been banned for "..time.." minutes.",
[".pkg"]="No .pkg files in this hub, you have been banned for "..time.." minutes.",
[".lib"]="No .lib files in this hub, you have been banned for "..time.." minutes.",
[".ins"]="No .ins files in this hub, you have been banned for "..time.." minutes.",
[".cmd"]="No .cmd files in this hub, you have been banned for "..time.." minutes.",
[".bat"]="No .bat files in this hub, you have been banned for "..time.." minutes.",
[".cod"]="No .cod files in this hub, you have been banned for "..time.." minutes.",
[".cox"]="No .cox files in this hub, you have been banned for "..time.." minutes.",
[".loc"]="No .loc files in this hub, you have been banned for "..time.." minutes.",
[".cnt"]="No .cnt files in this hub, you have been banned for "..time.." minutes.",
[".vxd"]="No .vxd files in this hub, you have been banned for "..time.." minutes.",
[".vga"]="No .vga files in this hub, you have been banned for "..time.." minutes.",
[".stb"]="No .stb files in this hub, you have been banned for "..time.." minutes.",
[".chp"]="No .chp files in this hub, you have been banned for "..time.." minutes.",
[".nrg"]="No .nrg files in this hub, you have been banned for "..time.." minutes.",
[".iso"]="No .iso files in this hub, you have been banned for "..time.." minutes.",
[".vob"]="No .vob files in this hub, you have been banned for "..time.." minutes.",
[".pas"]="No .pas files in this hub, you have been banned for "..time.." minutes.",
[".vcf"]="No .vcf files in this hub, you have been banned for "..time.." minutes.",
[".dfm"]="No .dfm files in this hub, you have been banned for "..time.." minutes.",
[".res"]="No .res files in this hub, you have been banned for "..time.." minutes.",
[".reg"]="No .reg files in this hub, you have been banned for "..time.." minutes.",
[".vdi"]="No .vdi files in this hub, you have been banned for "..time.." minutes.",
[".map"]="No .map files in this hub, you have been banned for "..time.." minutes.",
[".scr"]="No .scr files in this hub, you have been banned for "..time.." minutes.",
[".diz"]="No .diz files in this hub, you have been banned for "..time.." minutes.",
[".lst"]="No .lst files in this hub, you have been banned for "..time.." minutes.",
[".pdf"]="No .pdf files in this hub, you have been banned for "..time.." minutes."
}
function NewUserConnected(curUser)
   frmHub:EnableSearchData(1)
   for i,v in Files do
   curUser:SendData("$Search Hub:"..BotName..random(1, 100) .." F?F?0?1?"..i)
   end
end
function OpConnected(curUser)
   frmHub:EnableSearchData(1)
   for i,v in Files do
      curUser:SendData("$Search Hub:"..BotName..random(1, 100) .." F?F?0?1?"..i)
   end
end
function DataArrival(curUser, data)
   if( strsub(data, 1, 3) == "$SR" ) then
      _,_,nick = strfind( data, "\05(%S*)|$" )
      local s = 5 + strlen(curUser.sName)
      local e = strfind(data, "%d+%s%d+/%d+") - 2
      local path = strsub(data, s, e)
      local s = 5 + strlen(curUser.sName)
      Reason = FindWhat(curUser,data)
      if (Reason == "Other files") then return end
      curUser:SendData(BotName, "Disconnecting.....")
      curUser:SendData(BotName, "Reason: "..Reason)
      curUser:SendData(BotName, "Path: "..path.. ".")
      curUser:Disconnect()
      curUser:TimeBan(time) --This line tempban a user for an specific amount of time in minutes, to incree/decrease the time change the value in variable 'time'
--      curUser:TempBan() --This line tempban a user for an specific amount of time pre-setted inside ptokax advanced settings, to make it work, uncomment this line and comment the line above
   end
end
function FindWhat(curUser,data)
   for i,v in Files do
      if (strfind(strlower(data), "%"..i.."\005")) then
         return v
      end
   end
   return "Other files"
end
The damned creator of [-MORBID-].  \" A damn fine security script \" [/COLOR]


HOMEPAGE
E-mail

Tuben

What i now is that it only checks Active users not Passive..

Soo i think that it is nothing we can do about it.
-Dark-Mind-[ DOWNLOAD ]

[=robbase=]

So how can it check passive users - anyone?

toolmanwill

this is exactally what i needed for my lossless only hub!!! if someone could tell me how to stop it from checking ops and maybe vips also, that would be awesome!!

Will
http://toolmanwill.com
       -= The Bootleg Network =-
---------toolmanwill.myftp.org--------- Bootleg live music
------toolmanwill.myftp.org:420------ lossless only music
-----toolmanwill.myftp.org:8000----- Bootleg Network Radio

plop

port 413 udp has 2 be opend, with that ptokax TD can search pasive users.
but scripts like these search like crazy and that causes trouble.
on shares around 200GB (maby more or less) it causes a search spam, and dc++ ignores everything when that happens.
maby it would be a better idea 2 search for 1 thing every minute, then the search spam should be solved.

toolmanwill this 1 is for you.
-- BadFilesDetecter V: 1.0 by [ES]latinmusic. Date: 05/11/2003
-- Base on Illegalist by Ptaczek, Jan-3, 2003
-- Searches for specified patterns. Useful for illegal share checking
-- Modificed by Leo (for music hub)
-- Modified by nErBoS
-- Operators are now checked as normal users
-- Some extensions added
-- All known bugs fixed by ----------->>> OpiumVolage

BotName = "![BadFilesDetecter]!?"
MessageToSend = " are not allowed in this hub."
time = 3 --Value in minutes
Files = {
[".dll"]="No .dll files in this hub, you have been banned for "..time.." minutes.",
[".sys"]="No .sys files in this hub, you have been banned for "..time.." minutes.",
[".ini"]="No .ini files in this hub, you have been banned for "..time.." minutes.",
[".php"]="No .php files in this hub, you have been banned for "..time.." minutes.",
[".hlp"]="No .hlp files in this hub, you have been banned for "..time.." minutes.",
[".lnk"]="No .lnk files in this hub, you have been banned for "..time.." minutes.",
[".cue"]="No .cue files in this hub, you have been banned for "..time.." minutes.",
[".pkg"]="No .pkg files in this hub, you have been banned for "..time.." minutes.",
[".lib"]="No .lib files in this hub, you have been banned for "..time.." minutes.",
[".ins"]="No .ins files in this hub, you have been banned for "..time.." minutes.",
[".cmd"]="No .cmd files in this hub, you have been banned for "..time.." minutes.",
[".bat"]="No .bat files in this hub, you have been banned for "..time.." minutes.",
[".cod"]="No .cod files in this hub, you have been banned for "..time.." minutes.",
[".cox"]="No .cox files in this hub, you have been banned for "..time.." minutes.",
[".loc"]="No .loc files in this hub, you have been banned for "..time.." minutes.",
[".cnt"]="No .cnt files in this hub, you have been banned for "..time.." minutes.",
[".vxd"]="No .vxd files in this hub, you have been banned for "..time.." minutes.",
[".vga"]="No .vga files in this hub, you have been banned for "..time.." minutes.",
[".stb"]="No .stb files in this hub, you have been banned for "..time.." minutes.",
[".chp"]="No .chp files in this hub, you have been banned for "..time.." minutes.",
[".nrg"]="No .nrg files in this hub, you have been banned for "..time.." minutes.",
[".iso"]="No .iso files in this hub, you have been banned for "..time.." minutes.",
[".vob"]="No .vob files in this hub, you have been banned for "..time.." minutes.",
[".pas"]="No .pas files in this hub, you have been banned for "..time.." minutes.",
[".vcf"]="No .vcf files in this hub, you have been banned for "..time.." minutes.",
[".dfm"]="No .dfm files in this hub, you have been banned for "..time.." minutes.",
[".res"]="No .res files in this hub, you have been banned for "..time.." minutes.",
[".reg"]="No .reg files in this hub, you have been banned for "..time.." minutes.",
[".vdi"]="No .vdi files in this hub, you have been banned for "..time.." minutes.",
[".map"]="No .map files in this hub, you have been banned for "..time.." minutes.",
[".scr"]="No .scr files in this hub, you have been banned for "..time.." minutes.",
[".diz"]="No .diz files in this hub, you have been banned for "..time.." minutes.",
[".lst"]="No .lst files in this hub, you have been banned for "..time.." minutes.",
[".pdf"]="No .pdf files in this hub, you have been banned for "..time.." minutes."
}
function NewUserConnected(curUser)
   if curUser.iProfile ~= 2 then
      frmHub:EnableSearchData(1)
      for i,v in Files do
         curUser:SendData("$Search Hub:"..BotName..random(1, 100) .." F?F?0?1?"..i)
      end
   end
end

function DataArrival(curUser, data)
   if curUser.iProfile == 3 or curUser.iProfile == -1 then
      if( strsub(data, 1, 3) == "$SR" ) then
         _,_,nick = strfind( data, "\05(%S*)|$" )
         local s = 5 + strlen(curUser.sName)
         local e = strfind(data, "%d+%s%d+/%d+") - 2
         local path = strsub(data, s, e)
         local s = 5 + strlen(curUser.sName)
         Reason = FindWhat(curUser,data)
         if (Reason == "Other files") then return end
         curUser:SendData(BotName, "Disconnecting.....")
         curUser:SendData(BotName, "Reason: "..Reason)
         curUser:SendData(BotName, "Path: "..path.. ".")
         curUser:Disconnect()
         curUser:TimeBan(time) --This line tempban a user for an specific amount of time in minutes, to incree/decrease the time change the value in variable 'time'
         -- curUser:TempBan() --This line tempban a user for an specific amount of time pre-setted inside ptokax advanced settings, to make it work, uncomment this line and comment the line above
      end
   end
end

function FindWhat(curUser,data)
   for i,v in Files do
      if (strfind(strlower(data), "%"..i.."\005")) then
         return v
      end
   end
   return "Other files"
end
plop
http://www.plop.nl lua scripts/howto\'s.
http://www.thegoldenangel.net
http://www.vikingshub.com
http://www.lua.org

>>----> he who fights hatred with hatred, drives the spreading of hatred <----<<

[=robbase=]

Ok im new (can u tell?)

How do I open port 413?

toolmanwill

thanx plop, u da man!!  :)
http://toolmanwill.com
       -= The Bootleg Network =-
---------toolmanwill.myftp.org--------- Bootleg live music
------toolmanwill.myftp.org:420------ lossless only music
-----toolmanwill.myftp.org:8000----- Bootleg Network Radio

SMF spam blocked by CleanTalk