If I do a whois to my bot, your vhost is different than other commands return.
The matchaddr command returns the real host, that is, the company belonging to the internet .:
mybot!botijo@anteldata.net.uy
The vhost my bot is another:
mybot!botijo@hello.your.best.bot
I need a command to return vhost bot.
I found the solution, but have the problem of getting the value of the variable vhost from one process to another.
Code: Select all
bind mode - "% +b" check:ban
proc check:ban {nick host hand chan mode target} {
global canal_admin vhost
putserv "WHOIS $::botnick"
proc whois::311 {from key botnick } {
global canal_admin vhost
if {[regexp -- {^[^\s]+\s(.+?)\s(.+?)\s(.+?)\s\*\s\:(.+)$} $botnick wholematch nick ident host realname]} {
set vhost [stripcodes bc ${host}]
putserv "PRIVMSG $canal_admin :boT vhost: $vhost"
}
}
set host1 "*!*@[join $vhost]"
.................more stuff................
The problem starts in the following line:
You can not set the host1 variable, because it can not read the vhost variable.set host1 "*!*@[join $vhost]"
Is there any way to fix this code, or another way to get the vhost bot?