help with robocop
 

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

help with robocop

Started by lazyj189, 21 October, 2003, 07:14:49

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

lazyj189

function DoDcPlusChecks(user)

   for key,checkWord in forbiddenWords do
      if strfind(user.sMyInfoString, checkWord, 1, 1) then
         -- I spend no words to the stupid [DONKEY]
         WriteKickBan(date("%d").."/"..date("%m").."-"..date("%Y").." "..date("%T").." "..user.sName.." ("..user.sIP..") - Reason: MlDonkey Client")
         --user:TempBan()
         --user:Disconnect()
         RedirectsUser(user)
         break
      end
   end

function RedirectsUser(user)
   SendToNick(user.sName, "<" ..sBot.."> So you are going to be redirected to: "..frmHub:GetRedirectAddress())
   SendToNick(user.sName, "<" ..sBot.."> Redirecting..")
   user:SendData("$ForceMove "..frmHub:GetRedirectAddress())
end



Will this redirect the mldonkeys or do I have the command wrong?  I've tried tempbanning and permbanning and just disconnecting.  I'm hoping that MLDonkeys follow redirects so I can just send them away.  Please help.
DivX Dominion Hub Owner
3 years running
DivX Dominion Hub

lazyj189

is there a "user:Redirect(Hub address) command that would work in here by any chance so I could redirect to another address than the one I have setup in the hub software?
DivX Dominion Hub Owner
3 years running
DivX Dominion Hub

klownietklowniet

You can do:

        local rd = frmHub:GetRedirectAddress()
         user:SendData("$ForceMove "..rd.."|")
[ > DC - UniteD < ]

lazyj189

how about not sending them to the redirect hub that I have setup in the network settings.  I would much prefer to redirect them to "hell" or at least somewhere totally away from me.
DivX Dominion Hub Owner
3 years running
DivX Dominion Hub

lazyj189

if (sYNFakeShare == "1") and checkFake(user)then
      WriteKickBan(date("%d").."/"..date("%m").."-"..date("%Y").." "..date("%T").." "..user.sName.." ("..user.sIP..") was banned - Reason: Fakeshare!")
      SendToOps(sBot,"Banned: <"..user.sName.."> because he's using a fakeshare!  - IP: "..user.sIP)
      user:SendData(sBot, "You seem to be using a fakeshare client!")
      SendToNick(user.sName, "<" ..sBot.."> Disconnects...")
      user:Ban()
      user:NickBan()
      user:Disconnect()
   end

What would I add if I wanted it to show in the mainchat with the kick message the amount in GB that the user was supposedly sharing?
DivX Dominion Hub Owner
3 years running
DivX Dominion Hub

kepp

Can i use it like this?
RedirectAddress1 = "xxx.no-ip.org"
RedirectAddress2 = "xxx.no-ip.org"

user:SendData("$ForceMove "..RedirectAddress1.."|")
user:SendData("$ForceMove "..RedirectAddress2.."|")

I mean, If i make a script with a command like +rd1

see my point?
Guarding    

lazyj189

ya I see it.  Something like that would be awesome to have.  Back in the day *barf* of NMDC hub, the script I had running in my hub allowed for 3 different redirect addresses.  1 redirect for minimum shares, 1 redirect for dc++ abusers, and 1 redirect address for overflow.  Having the option for multiple redirect addresses inside the script would be great.  I've been trying to make the mldonkey program work on my system so I can better understand how it works so maybe I can come up with something to keep them from "attacking" my hub (not trying to just sound self centered).  As long as the mldonkey client follows redirects, it would probably be best to try and redirect them away somewhere else.  If I'm not mistaken, I believe there is a hub somewhere on the DC network that allows donkeys to log into it's hub.  I'd be more than happy to redirect them all there.  All that if you line of code will work.  I'm no expert on scripting, hell I just get lucky most of the time when I do fiddle with scripts.  Could use someone else's input on that line of code.
DivX Dominion Hub Owner
3 years running
DivX Dominion Hub

kepp

No syntax errors, but i don't know for sure if it works

sBot = "<[DoNKEY]>"

Donkey = { "mldonkey","mldc","client","MLDONKEY","moglo" }

badClients = { "_koala","XKing","repika","[REPLiKA]","pepek","0.233B","0.233A","0.181fr","0.241A","0.24A","Echoes" }

RedirectAddressA = "xxx.no-ip.com"
RedirectAddressB = "xxx2.no-ip.com"

function DoDcPlusChecks(user) 

for key,checkWord in Donkey do 
if strfind(user.sMyInfoString, checkWord, 1, 1) then 
user:SendData("$ForceMove "..RedirectAddressA.."|")
end
end


function CheckBadClients(user)

for key,chekword in badClients do
if strfind(user.sMyInfoString, checkword, 1, 1) then
user:SendData("$ForceMove "..RedirectAddressB.."|")
end
end
end
end
Guarding    

SMF spam blocked by CleanTalk