egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Changing Tcl Script ! Need Help

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests
View previous topic :: View next topic  
Author Message
aboutme
Voice


Joined: 23 Nov 2015
Posts: 2

PostPosted: Sun Oct 18, 2020 4:27 am    Post subject: Changing Tcl Script ! Need Help Reply with quote

Hi All , I am using tcl script for proxys
Quote:

REMOTECONNECT: Client connecting at irc.server.info: user123!webirc@89.205.133.232 (89.205.133.232) [https://****.info]

From this Remoteconnect my code is taking the ip 89.205.133.232 :
Code:

roc rem_conn {nick uhost hand chan text} {
global cds cdsstatus
if {$chan == "#services"} {
set text [string trim $text]
set cds(current-nick) [lindex [string map -nocase [list "!" " "] [lindex $text 5]] 0]
set cds(current-target) [string map -nocase [list "(" "" ")" ""] [lindex $text 6]]
if {[regexp -- {([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})} $cds(current-target) match a b c d]} {
 foreach server [split $cds(lists) " "] {
 dnslookup "$d.$c.$b.$a.$server" cds:iplookup $cds(current-nick) $server
 set cdsstatus($server) "[expr [lindex $cdsstatus($server) 0] + 1] [lindex $cdsstatus($server) 1]"
 set cdsstatus(total) "[expr $cdsstatus(total) + 1]"

NOW I want to make a new code
To take the ip from this letter :
REMOTEANNOUNCEMENT: From irc.server.info: Connecting user 653AAUJB0 detected as using CGI:IRC (root.server.info), changing real host to 212.233.145.178 from root.server.info

I want to take this ip 212.233.145.178
What i have to change in my code? Please help
Back to top
View user's profile Send private message
CrazyCat
Revered One


Joined: 13 Jan 2002
Posts: 1032
Location: France

PostPosted: Sun Oct 18, 2020 7:14 am    Post subject: Reply with quote

First: do not double post.

Second: I guess you use a bind pub (or pubm), can you show us which one you use ?
You probably can use the same proc whith changing the bind to catch another keyword, as your proc extract the IP from the text.
_________________
https://www.eggdrop.fr - French IRC network
Offer me a coffee - Do not ask me help in PM, we are a community.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber