Auto Identify

By D34th on Jan 20, 2011

This is my Chatspace and iRCD Identify script. This holds 2 passwords in %'s and if it is on it identifys for you.

Chatspace feature: This identifys when Raw 512 is passed ( for all who dont know it that is the raw that tells your irc the chat is asking for your password )

iRCD Feature: This works on notice event. ( When Nickserv Notices you with the word Identify in it it will send your password )

The script is pretty self explainitory Click the on radio select weither the pass stored in either storage is to be used for IRCD or Chatspace ( Checks to the right of the box's )

Enter your password into the edit click set click finished then you may connect to the server you wish this is mainly for users who have same passwords for all servers but you can adjust them as you wish i have tested and it works flawlessly for my mIRC Version im not 100% sure if the version will effect how it works for you but regardless i hope you enjoy it ~D34th~

Alias Ident { 
  If (!$Dialog(Ident)) { Dialog -m Ident Ident }
  Else { Echo -a ***14,1(4Auto Ident Is already Running14)*** }
}
Menu Channel {
  Ident: Ident
}
dialog Ident {
  title "Auto Ident"
  size -1 -1 166 84
  option dbu
  box "Password 1", 1, 1 14 106 27
  edit "", 2, 4 24 94 10, pass autohs
  box "Password 2", 3, 1 42 106 27
  edit "", 4, 4 53 94 10, pass autohs
  check "Chatspace", 5, 110 19 50 8
  check "iRCD", 6, 110 30 50 8
  check "Chatspace", 7, 110 47 50 8
  check "iRCD", 8, 109 58 50 8
  button "Set", 9, 2 70 76 12
  button "Finished", 10, 87 70 76 12
  radio "Auto Identify On", 11, 16 4 58 8
  radio "Auto Identify Off", 12, 84 4 65 8
}
On *:Dialog:Ident:*:*:{
  If ($devent == Init) {
    If (%AutoPass1 == Cs) { Did -c $dname 5 }
    If (%AutoPass1 == IRC) { Did -c $dname 6 }
    If (%AutoPass2 == CS) { Did -c $dname 7 }
    If (%AutoPass2 == IRC) { Did -c $dname 8 }
    If (%AutoId == On) { Did -c $dname 11 }
    If (%AutoId == Off) { Did -c $dname 12 }
    Did -a $dname 2 %AutoPass1.Pass
    Did -a $dname 4 %AutoPass2.Pass
  }
  If ($devent == Sclick) {
    If ($did = 5) { Set %AutoPass1 CS | Did -u $dname 6 }
    If ($did = 6) { Set %AutoPass1 IRC | Did -u $dname 5 }
    If ($did = 7) { Set %AutoPass2 CS | Did -u $dname 8 }
    If ($did = 8) { Set %AutoPass2 IRC | Did -u $dname 7 }
    If ($did = 9) { Set %AutoPass1.Pass $did(2) | Set %AutoPass2.Pass $did(4) }
    If ($did = 10) { Dialog -x $dname $dname }
    If ($did = 11) { Set %AutoId On }
    If ($did = 12) { Set %AutoId Off }
  }
}
Raw 512:*:{ 
  If (%AutoId == On) {
  If (%AutoPass1 == CS) { Pass %AutoPass1.Pass }
  If (%AutoPass2 == CS) { Pass %AutoPass2.Pass }
}
}
On *:Notice:*:*:{
  If (%AutoId == On) { 
 If ($nick == Nickserv) && (Identify Isin $Strip($1-)) {
    If (%AutoPass1 == IRC) { Msg Nickserv Identify %AutoPass1.Pass }
    If (%AutoPass2 == IRC) { Msg Nickserv Identify %AutoPass2.Pass }
  }
}
}

Comments

Sign in to comment.
D34th   -  Jan 21, 2011

Lol malcolm you and your damn ini files >.<

More
 Respond  
SkIdDy_KiLlEr   -  Jan 21, 2011
1:snotice:*pass*:/pass %pass

would work but let me see if i can think of a better way hold on.

on *:snotice:*pass* {
  if ($readini(test.ini,Autoidentfy,Autoserver1) = $server) {
    PASS $readini(test.ini,Autoidentfy,pass1)
  }
  if ($readini(test.ini,Autoidentfy,Autoserver2) = $server) {
    PASS $readini(test.ini,Autoidentfy,pass2)
  }
}

dialog fix to make this work would be erm change this

 If ($did = 9) { Set %AutoPass1.Pass $did(2) | Set %AutoPass2.Pass $did(4) }

to

 If ($did = 9) {  writeini autoidentify.ini autoidentify pass1 $did(2) | writeini autoidentify.ini autoidentify pass2 $did(4) }

same for the cs ircd stuff alot better and if you work with it, you can save a hell of alot more then two servers.

More
 Respond  
blackvenomm666   -  Jan 21, 2011

also fo chatspace you don't have to use a raw event. you could just use something like on 1:snotice:pass:/pass %pass that would only work for one site atm but can be changed easily. not sayin your way was wrong just another way to do it

More
 Respond  
D34th   -  Jan 20, 2011

About the stripping nickserv message it was because the text shows up with bold and underline so i was not sure if this would throw it off.

As for the replace thank you i didnt think of doing it like that.

More
 Respond  
_Teen_   -  Jan 20, 2011

i dont see a reason to strip the nickserv messages using replace, we can short many parts of ur code, example

    Did -c $dname $replace(%autopass1, CS, 5, IRC, 6)
    Did -c $dname $replace(%autopass2, CS, 7, IRC, 8)
    Did -c $dname $replace(%Autoid, ON, 11, OFF, 12)
More
 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.