IRCForumları - IRC ve mIRC Kullanıcılarının Buluşma Noktası

IRCForumları - IRC ve mIRC Kullanıcılarının Buluşma Noktası (https://www.ircforumlari.net/)
-   mIRC Scripting Sorunları (https://www.ircforumlari.net/mirc-scripting-sorunlari/)
-   -   !whoisd domain (https://www.ircforumlari.net/mirc-scripting-sorunlari/181133-whoisd-domain.html)

yaLin 18 Şubat 2009 23:36

!whoisd domain
 
Kod:

#whoisd.debug on
;debug mode so you know whats going on
alias -l whoisd.debug {
  if (!$window(@whoisd)) { window -e @whoisd }
  if ($1-) { aline @whoisd $timestamp $1- }
}
alias -l sockwrite {
  whoisd.debug > sockwrite $1-
  sockwrite $1-
}
alias -l sockopen {
  whoisd.debug > sockopen $1-
  sockopen $1-
}
#whoisd.debug end
#!whois on
on *:text:!whois *:#: { whoisd $strip($2) $chan | $repeatcheck(!whois) }
#!whois end
#!tld on
on *:text:!tld *:#: { tld $strip($2) $chan | $repeatcheck(!tld) }
#!tld end
;Main whois lookup server - You don't need to adjust this
alias whoisd.server { return whois.iana.org }
alias -l repeatcheck { ;v0.12 by HM2K - will disable the appropriate group if its flooded
  var %rep.lim = 3
  var %rep.t.lim = 25
  var %rep.t.expr = 10
  if (%rep.lockusr- [ $+ [ $nick ] ]) { echo $ifmatch | haltdef }
  inc $+(-u,%rep.t.lim,$chr(32),%,rep-,$nick,.,$len($strip($1-)),.,$hash($strip($1-),32)) 1
  if (%rep- [ $+ [ $nick ] $+ . $+ [ $len($strip($1-)) ] $+ . $+ [ $hash($strip($1-),32) ] ] == %rep.lim) {
    ;ignore -u60 $address($nick,5)
    if ($group($chr(35) $+ $1) == on) { .disable $chr(35) $+ $1 | .echo -gat $1 is $group($chr(35) $+ $1) due to a repeat flood from $iif($chan,$nick in $chan,$nick) $+ , to re-enable: /enable $chr(35) $+ $1 }
    .set $+(-u,%rep.t.expr,$chr(32),%,rep.lockusr-,$nick) 1
  }
}
alias whoisd { ;Usage: <domain> [nick/chan]
  if (!$1) { $whoisd.out Usage: /whoisd <domain> [nick/chan] | halt }
  var %i ^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,6}$
  if ($regex($1,%i) != 1) { $whoisd.out Invalid domain | halt }
  whoisd.open $whoisd.server $1 $2
}
alias whoisds { whoisd $1 $active }
alias tld { ;Usage: <domain> [nick/chan]
  if (!$1) { $whoisd.out Usage: /tld <tld> [nick/chan] | halt }
  if (($left($1,1) != .) && (*.* iswm $1)) { $whoisd.out Invalid TLD | halt }
  whoisd.open $whoisd.server $1 $2
}
alias tlds { tld $1 $active }
alias -l whoisd.out {
  var %prefix whoisd:
  var %out echo $color(info2) -gat
  if ($modespl) {
    if ($1) {
      if (($ifmatch != Status Window) && ($ifmatch != -)) {
        if ($left($1,1) != $chr(35)) { var %out msg $1 }
        elseif ($chan($1)) { var %out msg $1 }
      }
    }
    elseif (($nick) && ($nick != $me)) var %out notice $nick
  }
  return %out %prefix
}
alias whoisd.open { ;Usage: <server[:port]> <domain> [nick/chan]
  if (!$1) { $whoisd.out Usage: /whoisd.open <server[:port]> <domain> [nick/chan] | halt }
  if ($sock($whoisd.id($2))) { sockclose $whoisd.id($2) }
  if ($1) { sockopen $whoisd.id($2) $iif(: isin $1,$replace($1,:,$chr(32)),$1 43) }
  else { $whoisd.out Usage: /whoisd.open <server[:port]> <domain> [nick/chan] | halt }
  set % $+ $whoisd.id($2) $1 $strip($2) $3
}
alias -l whoisd.id { return whoisd. $+ $md5($1) }
on *:sockopen:whoisd.*: {
  if ($sockerr > 0) { return }
  if ($whoisd.server isin $gettok($(% $+ $sockname,2),1,32)) { $iif($numtok($gettok($(% $+ $sockname,2),2,32),46),.sockwrite -nt $sockname $gettok($gettok($(% $+ $sockname,2),2,32),$ifmatch,46),) }
  else { .sockwrite -nt $sockname $gettok($(% $+ $sockname,2),2,32) }
}
on *:sockread:whoisd.*: {
  if ($sockerr > 0) { return }
  :i
  if ($sock($sockname)) { sockread -f %whoisd.y }
  if ($sockbr == 0) { return }
  if ($whoisd.server isin $gettok($(% $+ $sockname,2),1,32)) {
    if ($left($gettok($(% $+ $sockname,2),2,32),1) == .) || (*.* !iswm $gettok($(% $+ $sockname,2),2,32)) {
      if (*not found.* iswm %whoisd.y) {
        $whoisd.out($gettok($(% $+ $sockname,2),3,32)) Invalid TLD
        sockclose $sockname
        halt
      }
      if (*Organization: * iswm %whoisd.y) {
        sockmark $sockname $gettok(%whoisd.y,2-,32)
      }
      if (*Country: * iswm %whoisd.y) {
        $whoisd.out($gettok($(% $+ $sockname,2),3,32)) $gettok($(% $+ $sockname,2),2,32),1) is $gettok(%whoisd.y,2-,32) $iif($sock($sockname).mark,$+([,$sock($sockname).mark,]))
        sockclose $sockname
        halt
      }
    }
    else {
      if (Whois Server == $gettok(%whoisd.y,1-2,32)) {
        .timer 1 1 whoisd.open $+($gettok(%whoisd.y,5,32),:,$remove($gettok(%whoisd.y,4,32),:,$chr(41))) $gettok($(% $+ $sockname,2),2-,32)
        if ($sock($sockname)) sockclose $sockname
        halt
      }
      elseif (*URL for registration services:* iswm %whoisd.y) {
        ;$whoisd.out($gettok($(% $+ $sockname,2),3,32)) This TLD has no whois server, try: $gettok(%whoisd.y,5,32) - $(% $+ $sockname,2)
        ;sockclose $sockname
        ;halt
      }
      if (*not found.* iswm %whoisd.y) {
        $whoisd.out($gettok($(% $+ $sockname,2),3,32)) Invalid TLD
        sockclose $sockname
        halt
      }
    }
  }
  ;if (*"=xxx"* iswm %whoisd.y) {
  ;  .timer 1 1 whoisd.open $gettok($(% $+ $sockname,2),1,32) = $+ $gettok($(% $+ $sockname,2),2-,32)
  ;  if ($sock($sockname)) sockclose $sockname
  ;  halt
  ;}
  if ((*Error for* iswm %whoisd.y) || (*ERROR: Invalid search string.* iswm %whoisd.y) || (*Bad Characters in query* iswm %whoisd.y) || (*Domain error* iswm %whoisd.y)) {
    $whoisd.out($gettok($(% $+ $sockname,2),3,32)) $gettok($(% $+ $sockname,2),2,32) caused an error...
    sockclose $sockname
    halt
  }
  if ((*No match* iswm %whoisd.y) || (*Not found* iswm %whoisd.y) || (*Status:*FREE* iswm %whoisd.y)) {
    $whoisd.out($gettok($(% $+ $sockname,2),3,32)) $gettok($(% $+ $sockname,2),2,32) is available!
    sockclose $sockname
    halt
  }
  goto i
}
on *:sockclose:whoisd.*: {
  if ($whoisd.server !isin $gettok($(% $+ $sockname,2),1,32)) { $whoisd.out($gettok($(% $+ $sockname,2),3,32)) $gettok($(% $+ $sockname,2),2,32) is taken! }
  else { $whoisd.out($gettok($(% $+ $sockname,2),3,32)) could not lookup data for $gettok($(% $+ $sockname,2),2,32) }
  unset $(% $+ $sockname,1)
}
#whoisd.sockdebug on
;debug mode for sockets v0.02 by HM2K
alias -l sockdebug {
  var %win @sockdebug
  if (!$window(%win)) { window -e %win }
  if ($1-) { aline %win $timestamp $1- }
}
alias -l sockopen {
  sockopen $1-
  sockdebug -> sockopen $1-
}
alias -l sockwrite {
  sockwrite $1-
  sockdebug > sockwrite $1-
}
alias -l sockread {
  sockread $($1-,1)
  sockdebug < sockread $sockname $($1-,2)
}
alias -l sockclose {
  sockclose $1-
  sockdebug <- sockclose $1-
}
#whoisd.sockdebug end

Selam..
Bu Kodun kullanımı /whoisd domain.uzantı şeklinde
bunu userlerinde kulanabilmesi için,
!whoisd domain.uzantisi gibi yapabilirmiyiz arkadaşlar?

Difuzyon 19 Şubat 2009 02:07

Cevap: !whoisd domain
 
on *:text:!whois *:#: { whoisd $strip($2) $chan | $repeatcheck(!whois) }

satırını aşağıdaki şekilde yapman yeterli.

on *:text:!whoisd *:#: { whoisd $strip($2) $chan | $repeatcheck(!whois) }

Karadenizliyim 19 Şubat 2009 23:29

Cevap: !whoisd domain
 
Alıntı:

VazGeciLmezimsiN Nickli Üyeden Alıntı (Mesaj 642834)
Kod:

#whoisd.debug on
;debug mode so you know whats going on
alias -l whoisd.debug {
  if (!$window(@whoisd)) { window -e @whoisd }
  if ($1-) { aline @whoisd $timestamp $1- }
}
alias -l sockwrite {
  whoisd.debug > sockwrite $1-
  sockwrite $1-
}
alias -l sockopen {
  whoisd.debug > sockopen $1-
  sockopen $1-
}
#whoisd.debug end
#!whois on
on *:text:!whois *:#: { whoisd $strip($2) $chan | $repeatcheck(!whois) }
#!whois end
#!tld on
on *:text:!tld *:#: { tld $strip($2) $chan | $repeatcheck(!tld) }
#!tld end
;Main whois lookup server - You don't need to adjust this
alias whoisd.server { return whois.iana.org }
alias -l repeatcheck { ;v0.12 by HM2K - will disable the appropriate group if its flooded
  var %rep.lim = 3
  var %rep.t.lim = 25
  var %rep.t.expr = 10
  if (%rep.lockusr- [ $+ [ $nick ] ]) { echo $ifmatch | haltdef }
  inc $+(-u,%rep.t.lim,$chr(32),%,rep-,$nick,.,$len($strip($1-)),.,$hash($strip($1-),32)) 1
  if (%rep- [ $+ [ $nick ] $+ . $+ [ $len($strip($1-)) ] $+ . $+ [ $hash($strip($1-),32) ] ] == %rep.lim) {
    ;ignore -u60 $address($nick,5)
    if ($group($chr(35) $+ $1) == on) { .disable $chr(35) $+ $1 | .echo -gat $1 is $group($chr(35) $+ $1) due to a repeat flood from $iif($chan,$nick in $chan,$nick) $+ , to re-enable: /enable $chr(35) $+ $1 }
    .set $+(-u,%rep.t.expr,$chr(32),%,rep.lockusr-,$nick) 1
  }
}
alias whoisd { ;Usage: <domain> [nick/chan]
  if (!$1) { $whoisd.out Usage: /whoisd <domain> [nick/chan] | halt }
  var %i ^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,6}$
  if ($regex($1,%i) != 1) { $whoisd.out Invalid domain | halt }
  whoisd.open $whoisd.server $1 $2
}
alias whoisds { whoisd $1 $active }
alias tld { ;Usage: <domain> [nick/chan]
  if (!$1) { $whoisd.out Usage: /tld <tld> [nick/chan] | halt }
  if (($left($1,1) != .) && (*.* iswm $1)) { $whoisd.out Invalid TLD | halt }
  whoisd.open $whoisd.server $1 $2
}
alias tlds { tld $1 $active }
alias -l whoisd.out {
  var %prefix whoisd:
  var %out echo $color(info2) -gat
  if ($modespl) {
    if ($1) {
      if (($ifmatch != Status Window) && ($ifmatch != -)) {
        if ($left($1,1) != $chr(35)) { var %out msg $1 }
        elseif ($chan($1)) { var %out msg $1 }
      }
    }
    elseif (($nick) && ($nick != $me)) var %out notice $nick
  }
  return %out %prefix
}
alias whoisd.open { ;Usage: <server[:port]> <domain> [nick/chan]
  if (!$1) { $whoisd.out Usage: /whoisd.open <server[:port]> <domain> [nick/chan] | halt }
  if ($sock($whoisd.id($2))) { sockclose $whoisd.id($2) }
  if ($1) { sockopen $whoisd.id($2) $iif(: isin $1,$replace($1,:,$chr(32)),$1 43) }
  else { $whoisd.out Usage: /whoisd.open <server[:port]> <domain> [nick/chan] | halt }
  set % $+ $whoisd.id($2) $1 $strip($2) $3
}
alias -l whoisd.id { return whoisd. $+ $md5($1) }
on *:sockopen:whoisd.*: {
  if ($sockerr > 0) { return }
  if ($whoisd.server isin $gettok($(% $+ $sockname,2),1,32)) { $iif($numtok($gettok($(% $+ $sockname,2),2,32),46),.sockwrite -nt $sockname $gettok($gettok($(% $+ $sockname,2),2,32),$ifmatch,46),) }
  else { .sockwrite -nt $sockname $gettok($(% $+ $sockname,2),2,32) }
}
on *:sockread:whoisd.*: {
  if ($sockerr > 0) { return }
  :i
  if ($sock($sockname)) { sockread -f %whoisd.y }
  if ($sockbr == 0) { return }
  if ($whoisd.server isin $gettok($(% $+ $sockname,2),1,32)) {
    if ($left($gettok($(% $+ $sockname,2),2,32),1) == .) || (*.* !iswm $gettok($(% $+ $sockname,2),2,32)) {
      if (*not found.* iswm %whoisd.y) {
        $whoisd.out($gettok($(% $+ $sockname,2),3,32)) Invalid TLD
        sockclose $sockname
        halt
      }
      if (*Organization: * iswm %whoisd.y) {
        sockmark $sockname $gettok(%whoisd.y,2-,32)
      }
      if (*Country: * iswm %whoisd.y) {
        $whoisd.out($gettok($(% $+ $sockname,2),3,32)) $gettok($(% $+ $sockname,2),2,32),1) is $gettok(%whoisd.y,2-,32) $iif($sock($sockname).mark,$+([,$sock($sockname).mark,]))
        sockclose $sockname
        halt
      }
    }
    else {
      if (Whois Server == $gettok(%whoisd.y,1-2,32)) {
        .timer 1 1 whoisd.open $+($gettok(%whoisd.y,5,32),:,$remove($gettok(%whoisd.y,4,32),:,$chr(41))) $gettok($(% $+ $sockname,2),2-,32)
        if ($sock($sockname)) sockclose $sockname
        halt
      }
      elseif (*URL for registration services:* iswm %whoisd.y) {
        ;$whoisd.out($gettok($(% $+ $sockname,2),3,32)) This TLD has no whois server, try: $gettok(%whoisd.y,5,32) - $(% $+ $sockname,2)
        ;sockclose $sockname
        ;halt
      }
      if (*not found.* iswm %whoisd.y) {
        $whoisd.out($gettok($(% $+ $sockname,2),3,32)) Invalid TLD
        sockclose $sockname
        halt
      }
    }
  }
  ;if (*"=xxx"* iswm %whoisd.y) {
  ;  .timer 1 1 whoisd.open $gettok($(% $+ $sockname,2),1,32) = $+ $gettok($(% $+ $sockname,2),2-,32)
  ;  if ($sock($sockname)) sockclose $sockname
  ;  halt
  ;}
  if ((*Error for* iswm %whoisd.y) || (*ERROR: Invalid search string.* iswm %whoisd.y) || (*Bad Characters in query* iswm %whoisd.y) || (*Domain error* iswm %whoisd.y)) {
    $whoisd.out($gettok($(% $+ $sockname,2),3,32)) $gettok($(% $+ $sockname,2),2,32) caused an error...
    sockclose $sockname
    halt
  }
  if ((*No match* iswm %whoisd.y) || (*Not found* iswm %whoisd.y) || (*Status:*FREE* iswm %whoisd.y)) {
    $whoisd.out($gettok($(% $+ $sockname,2),3,32)) $gettok($(% $+ $sockname,2),2,32) is available!
    sockclose $sockname
    halt
  }
  goto i
}
on *:sockclose:whoisd.*: {
  if ($whoisd.server !isin $gettok($(% $+ $sockname,2),1,32)) { $whoisd.out($gettok($(% $+ $sockname,2),3,32)) $gettok($(% $+ $sockname,2),2,32) is taken! }
  else { $whoisd.out($gettok($(% $+ $sockname,2),3,32)) could not lookup data for $gettok($(% $+ $sockname,2),2,32) }
  unset $(% $+ $sockname,1)
}
#whoisd.sockdebug on
;debug mode for sockets v0.02 by HM2K
alias -l sockdebug {
  var %win @sockdebug
  if (!$window(%win)) { window -e %win }
  if ($1-) { aline %win $timestamp $1- }
}
alias -l sockopen {
  sockopen $1-
  sockdebug -> sockopen $1-
}
alias -l sockwrite {
  sockwrite $1-
  sockdebug > sockwrite $1-
}
alias -l sockread {
  sockread $($1-,1)
  sockdebug < sockread $sockname $($1-,2)
}
alias -l sockclose {
  sockclose $1-
  sockdebug <- sockclose $1-
}
#whoisd.sockdebug end

Selam..
Bu Kodun kullanımı /whoisd domain.uzantı şeklinde
bunu userlerinde kulanabilmesi için,
!whoisd domain.uzantisi gibi yapabilirmiyiz arkadaşlar?

Bu Kodun anLamı nedir peki.ne işe yarar.biraz açarmısınız.hoşca paylaşımlar

yaLin 19 Şubat 2009 23:55

Cevap: !whoisd domain
 
Domain sorgulamak icindir bu kod.. boş veya dolu oldugunu gösterir.

[23:38] <@KahiN> !whoisd ircforumlari.net
[23:38] <VazGeciLmezimSiN> whoisd: ircforumlari.net is taken!
gibi..


Tüm Zamanlar GMT +3 Olarak Ayarlanmış. Şuanki Zaman: 05:50.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
Search Engine Friendly URLs by vBSEO
Copyright ©2004 - 2025 IRCForumlari.Net Sparhawk