This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

need to know how mIRC's notify list works

Help for those learning Tcl or writing their own scripts.
Post Reply
w
willyw
Revered One
Posts: 1199
Joined: Thu Jan 15, 2009 12:55 am

need to know how mIRC's notify list works

Post by willyw »

Hello,

I'd like to know how mIRC's notify list works. I'm kicking around some ideas, and could use that sort of functionality.


How it appears to me:
Upon my logging in to the irc server, it checks to see if the nicks that I've put in the Notify list are online. Those found are listed.
This is not the function I'm looking for.

While mIRC is online, any time a nick that is in the Notify list either comes online, or goes offline, a one line message appears in mIRC's status window, to tell me. It does not report on my whole list, but only the one nick that either logged on or off.
This is the function I'm looking for.

I found this short thread:
http://forum.egghelp.org/viewtopic.php? ... ght=notify
It does not address my question... it seems to be saying that the client must ask for the info and would apparently report on the whole list.

The way it appears to me, when I use this function in mIRC - mIRC is not asking for the info. To respond as fast as it does, it would have to be asking once per second.
Somehow, the server is announcing to everyone online, I guess, that a nick has either logged on, or off ( or changed nicks), and my client then checks the list I've config'd, and lets me know if found.

If I knew what the server was sending, maybe I could work with that, in some TCL scripts.

Any and all info on this will be appreciated.

Thanks.
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

Actually, ISON queries are the most reliable method across different networks to see if someone is online. Some networks provide additional services for online notifications (such as NoteServ on ircnet), though their implementations and availability varies.

Servers generally don't announce connects, disconnects, or nickname changes to other clients, unless the client is in the same channel as the other part (disconnect and nickname change). Given the number of clients connecting, changing nicknames, and disconnecting on larger networks, would further make such announces impractical.

If you really want to see the actual network traffic, why not use a network sniffer such as wireshark (or Microsoft Network Monitor for Windows) and record an irc session with mirc notify enabled. Or, I could save you the trouble and let you know that last time I checked (some 5 minutes ago), mIRC still used ISON, making a new query once every minute.

Regarding the script in the thread you posted, it pretty much mimics mIRC's notify feature, though it does not keep track of earlier results - and can thus not say whether someone just went online, or if they've been online for several hours..
NML_375
w
willyw
Revered One
Posts: 1199
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

Thanks for replying.
nml375 wrote: ...
Given the number of clients connecting, changing nicknames, and disconnecting on larger networks, would further make such announces impractical.
I would have thought so too.
...
Or, I could save you the trouble and let you know that last time I checked (some 5 minutes ago), mIRC still used ISON, making a new query once every minute.
This is interesting.

The little experiment I just did, went like this:
Am logged in with my regular everyday mIRC.
Next, logged in via a shell, running irssi.
With irssi, changed nick a few times. (using nicks that are in mIRC's notify list)
Each nick was noted *immediately* in mIRC, as being online. Then again, when it went offline... i.e. a nick change.

As I understand you, my mIRC would be sending out an ISON, once per minute. What I'm not understand now is: how is it then that it can instantly detect when a nick comes online?
(Because of this behavior, is how I came to thinking that it is not mIRC making a request, and getting a reply, that is generating the Notify report for the particular nick)


Further, why does it not list all the nicks in the Notify list, every minute?
ISON would return them as being online.



Thanks.
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

For the first part, if both clients are in the same channel, I recall mirc would use the additional join, nick and quit commands posted about the client.
If that's not the case, try using some network monitor and see if mirc is using some network-specific extensions.

The second part, mirc compares the list of online nicks from the last check to the current, and posts the diff of the two:

Code: Select all

#Result from last ISON:
Nick1 Nick2 Nick3 Nick5
#Result from this ISON:
Nick1 Nick2 Nick4

#Difference:
Nick4 came OnLine
Nick3, Nick5 went OffLine
To achieve this, you'll need to keep a list of who was online last time, and compare each nickname in the current resultset to that list:
If a nick is not in the old list, but in the current resultset - then he just went online.
If a nick is in the old list, but not in the current resultset - then he just went offline.
NML_375
w
willyw
Revered One
Posts: 1199
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

nml375 wrote:For the first part, if both clients are in the same channel,
No channel involved at all.
Just being logged in on the server.
I recall mirc would use the additional join, nick and quit commands posted about the client.
If that's not the case, try using some network monitor and see if mirc is using some network-specific extensions.
You mentioned them earlier, and yesterday I did download MS Network Monitor.
I've no idea which of the two you mentioned is 'better'.

I haven't had time to install it and try it though. Having never used anything like this before, it will be a learning experience. :)
Wish me luck.
(If you have any advice on using these things, tips, tricks, things to watch for ... ... It would be appreciated)

As for network-specific: I doubt it, because this behavior is the same, on any network I've been on, and for a number of years too.


The second part, mirc compares the list of online nicks from the last check to the current, and posts the diff of the two:
...

Ah.
Ok.
Makes sense.



Thanks
C
CtrlAltDel
Halfop
Posts: 49
Joined: Wed Jun 02, 2004 7:58 am

Post by CtrlAltDel »

The major networks use the same raw commands, so I have to agree that it's not network specific.

600 D RPL_LOGON
601 D RPL_LOGOFF

on the mirc command line:
/debug -n @debug (to turn debug on and view raw server messages)
/debug -c off (to turn debug off and close @debug window)
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

To my best knowledge, those codes are only supported on Dalnet (bahamut/Unreal ircd's), and would only be available if the server provides the "WATCH" command.
NML_375
w
willyw
Revered One
Posts: 1199
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

CtrlAltDel wrote:The major networks use the same raw commands, so I have to agree that it's not network specific.

600 D RPL_LOGON
601 D RPL_LOGOFF

I'd made it this far... but only just very recently. :)

It is the
watch
command, that I scoped in on.

Some networks have
/helpop
and it will be listed there.

I found it here too:
http://docs.dal.net/docs/misc.html#4

I don't yet know why, but on two networks that I've tried it on, I don't get a response from the server.
At least not one that I can see. (using mIRC)

But, for fun, I logged into a bot, and did:
.console +rv
Then I used:
.dump watch +nick
And could see the server respond, as expected.

Then, when I changed nicks to and away from the nick being 'watched', I could see the raw incoming 600 and 601 respectively.
:)


This is what I needed!
The command, and the raw numeric.
Now, I think I can play around with some TCL ideas.
on the mirc command line:
/debug -n @debug (to turn debug on and view raw server messages)
/debug -c off (to turn debug off and close @debug window)
Ah.. good.
Thanks.
I thought there should be a way to on view raw server messages, but hadn't found it.

Thanks, all.
w
willyw
Revered One
Posts: 1199
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

nml375 wrote:To my best knowledge, those codes are only supported on Dalnet (bahamut/Unreal ircd's), and would only be available if the server provides the "WATCH" command.
So far, I've tried it on only two types of ircd - InspIRCd-2.0 and Unreal3.2.8 and it worked on both.
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

If you only use those kinds of servers, then the WATCH command should work perfectly fine for you.
If you venture off to some other networks such as IRCNet (ircd 2.11.1p1), you'll find that you need a different solution.
NML_375
w
willyw
Revered One
Posts: 1199
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

nml375 wrote:If you only use those kinds of servers, then the WATCH command should work perfectly fine for you.
Right.
and normally, it seems I do.
If you venture off to some other networks such as IRCNet (ircd 2.11.1p1), you'll find that you need a different solution.
Since we are on the subject, and on the chance that I might someday - now is the time to ask:

Suggestions?
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

For IRCNet and similar servers, ISON.
Additionally, you could try to use the NoteServ service on IRCNet, though you should be aware that it does honor the +i (invisible) usermode - thus it will wait for a period (around 60 seconds I think) to let new users have time to set it before sending any notification.
NML_375
w
willyw
Revered One
Posts: 1199
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

nml375 wrote:For IRCNet and similar servers, ISON.
Oh.. ok.
I thought you were saying that there was more to know, ... methods, etc. .... regarding my original question - on the type of server used by IRCnet - that is: instant notification without having to do a request.


Regarding the use of ISON:
What would you think would be acceptable frequency of use of ISON ?

One wouldn't want to tic off the admins, by appearing to be hammering away. Yet for the basic idea of being notified when some particular nicks log on, it must check fairly frequently.
I wonder what the happy medium is.....

Additionally, you could try to use the NoteServ service on IRCNet, though you should be aware that it does honor the +i (invisible) usermode - thus it will wait for a period (around 60 seconds I think) to let new users have time to set it before sending any notification.
Will have to remember to re-visit this thread, when the time comes. But the info here will likely be useful to somebody else, in the meantime.
Thanks.
Post Reply