Jump to content
chain

WebClient Ban Substitution

Recommended Posts

  • Administrators
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;                 WebClient Ban Subsitution                                   ;
;                                                                             ;
; This script works in two phases:                                            ;
; 1) - Detect when a site ban is placed on irccloud/mibbit/kiwiirc.           ;
;    - Unban the site ban that could possibly affect multiple clients.        ;
;    - Set variable and wait for the kick to determine the banned client.     ;
;                                                                             ;
; 2) - After the kick takes place, make sure the variable matches the client. ;
;    - Once verified, place an ident ban for the client who got kicked.       ;
;                                                                             ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Author:  psycho                                                             ;
; Network: Undernet / irc.undernet.org                                        ;
; Channel: #psycho                                                            ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Credits ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; simo for the original idea                                                  ;
; Ouims for helping with the regex code.                                      ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

on *:LOAD:{
  echo -at You just loaded the irccloud/mibbit/kiwiirc ban replacement script
  echo -at This Script does not require additional configuration
  echo -at Simply load it and wait for the magic to happen.
}

on *:UNLOAD:{
  echo -at What the hell??
  echo -at Alrighty then!
}

ON *:BAN:#:{
  if ($nick(#,$me,@%&~)) {
    if ($regex($banmask,/(mibbit|irccloud|kiwiirc|192.184.9.108|192.184.9.110|192.184.9.112|192.184.8.73|192.184.10.9|192.184.10.118|107.161.19.109|207.192.75.252|64.62.228.82|78.129.202.38|87.98.219.117|107.161.19.53|109.169.31.4|109.169.29.95|195.154.53.5|195.154.52.250|212.83.148.225)/i)) { mode $chan -b $banmask | set %webchatc $addtok(%webchatc,$banmask,32) }
    if ($regex($banmask,/([su]id\D|^\*!~?\*@(?:\*$|\?+))/i)) { mode $chan -b $banmask }
  }
}

ON ^*:KICK:#:{ 
  if ($istok(%webchatc,$address($knick,2),32)) && ($nick(#,$me,@%&~)) {
    mode # +b $+($gettok($address($knick,0),1,64),@*)
    set %webchatc $remtok(%webchatc,$address($knick,2),32)  
  }
}

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...


×
×
  • Create New...