Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #START OF DNS LOOKUP
- on *:text:!dns *:#:{ $iif($sock(sitecheck),sockclose sitecheck) | sockopen sitecheck www.downforeveryoneorjustme.com 80 | sockmark sitecheck $2 | dns $2- | set %dns.chan $chan }
- on *:sockopen:sitecheck: { var %x = sockwrite -n $sockname | %x GET $+(/,$sock(sitecheck).mark) HTTP/1.1 | %x Host: www.downforeveryoneorjustme.com | %x Connection: close | %x }
- on *:sockread:sitecheck: { var %x | sockread %x | if $regex(%x,/(.+)[\.!]\s+<.+>(.+)<\/a>(.+)\./) { set %dns.status $reglm(1) $reglm(2) $remove($regml(3),</span>) } }
- on *:DNS:{
- msg %dns.chan Host: $naddress IP: $iaddress
- msg %dns.chan Resolved: $raddress - Status: %dns.status }
- #END OF DNS LOOKUP
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement