Hey humans. I'm updating this thread, because the 3rd one isn't working anymore, and I assume ditto for the others. The reason is that IRCv3 @tags are now being put at the front of the strings seen by ON PARSELINE, so they no longer match. These optional tags at the beginning of the string can be identified by being a token that begins with the '@' character. So the Regex pattern needs to change by allowing for the optional presence of this string. The 1st 2 patterns also search for 'not a colon', but that's a valid character in a @tag, so it's possible that the pattern could dump you out in the middle of a tag instead of where it should be.

In addition, I found this not working at one network where it turned out that the reply to the version check was going outbound as a CNOTICE instead using the normal NOTICE keyword. I don't know if this is still happening, so I allow for it just in case.

So if you use the first 2 methods, you should modify the first 2 by inserting the string...

(?:@[^ ]+ )?

... immediately following the ^ symbol at the beginning of these patterns.

For the 3rd outbound, that stopped working once mIRC started attaching a tag like @label=1234 in front of outbound messages. This forwards whatever tag, if any, precedes the outbound version-reply, and also works with CNOTICE

Code
ON $*:PARSELINE:out:/^(@[^ ]+ |)((NOTICE|CNOTICE \S+) \S+ :\x01VERSION) mIRC/:{ .!parseline -otn $regml(1) $+ $regml(2) Not mIRC $version $+ $iif($beta,. $+ $v1) $+ $chr(1) } ; by SReject 2017 modified maroon



* *

The other common ctcp's that people like to use to snoop at you are with TIME and FINGER. With CTCP TIME, they find out the time your pc clock is set to, which often indicates which country you are in. With CTCP FINGER, the default reply tells them the 'name' and 'email' you've input into your alt+E window, and also gives your $idle value, which tells them how recently you've done something in your client to reset that, which can be using the editbox to send a message to to a channel or query window on that network, but it can also be executing a //command in an alias which doesn't even involve sending traffic to/from the network.

You can either halt these without sending the message first, or you can send back a fake reply first. Both of these examples let you see the incoming CTCP request and shows your reply.

This one sends back an obviously wrong time, as a random time of day sometime on the 1st day of epoch:

Code
ctcp *:time:{ !ctcpreply $nick TIME Thu Jan 01 $time($r(0,86399)) 1970 | !halt }

If you're an @op that doesn't want spammers to get an idea from your clock if you're going to be there to stop them, instead of returning a random time of day, you can just have it return the same time all the time, picking a time that makes it look like you're going to be there.

This one replaces the default finger reply

Code
ctcp *:finger:{ !ctcpreply $nick FINGER get your finger outta there you perv! | !halt }

This one allows the default reply to go out without halting it, but first it sets the $idle value to a fake number. But it also users a timer to reset $idle back to where it 'should be'

Code
ctcp *:finger:{ !.timer 1 0 resetidle $idle | !.resetidle 999999 }