version reply empty ?
Posted: Thu Apr 06, 2006 1:08 pm
-> [nick] VERSION
[nick VERSION reply]
version reply is empty ? what is regex
[nick VERSION reply]
version reply is empty ? what is regex
Welcome to the UnrealIRCd Forums!
https://forums.unrealircd.org/
Code: Select all
spamfilter {
regex "^\\x01VERSION \\s*\\x01$";
target private-notice; // CTCP replies are sent via NOTICE.
action kline;
reason "Empty version string.";
};= noaquanight wrote:In this case - it is possible.
There is a difference between no version reply and an empty version reply. Notice that a version string IS in fact being sent back - it simply appears to contain nothing.
(I say appears to because it could very easily consist of whitespace. Or it could use color codes to make the version text the same color as your bg color. The regex considers only the spaces-only situation. Colors can't be checked for in regexes since they get stripped.)
-or-Code: Select all
spamfilter { regex "^\\x01VERSION \\s*\\x01$"; target private-notice; // CTCP replies are sent via NOTICE. action kline; reason "Empty version string."; };
/spamfilter + n gline - Empty_version_string. ^\x01VERSION \s*\x01$
Anonymous wrote:what is regex?
--from http://en.wikipedia.org/wiki/RegexWikipedia wrote:A regular expression (abbreviated as regexp or regex, with plural forms regexps, regexes, or regexen) is a string that describes or matches a set of strings, according to certain syntax rules.
Code: Select all
spamfilter {
regex "\x1VERSION";
target private-notice;
action kill;
reason "exit.";
};
Code: Select all
* Connecting to irc.xxxx.com (6666)
-
-irc.xxxx.com- *** Couldn't resolve your hostname; using your IP address instead
-
[IRC VERSION]
-
Welcome to the xxxx IRC Network
Then why not? If you don't want to accept our help and give us reasons why it won't work, I see no reason to keep this topic open...Guest wrote:= no
Code: Select all
code removed
Code: Select all
in server send /ctcp nick version
Code:
spamfilter {
regex "\x1VERSION";
target private-notice;
action kill;
reason "exit.";
};
good pozitive
but!!!!
Code:
* Connecting to irc.xxxx.com (6666)
-
-irc.xxxx.com- *** Couldn't resolve your hostname; using your IP address instead
-
[IRC VERSION]
-
Welcome to the xxxx IRC Network
nick connect server negative? why?