Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mode change string failing to parse on clients #1636

Closed
adamus1red opened this issue May 7, 2019 · 4 comments
Closed

Mode change string failing to parse on clients #1636

adamus1red opened this issue May 7, 2019 · 4 comments

Comments

@adamus1red
Copy link

@adamus1red adamus1red commented May 7, 2019

Description

Mode change string failing to parse on clients.

The recent 3.0 update breaks the nicklist update on many IRC clients (Confirmed HexChat & have had it reported as affecting mIRC)

Reported upstream to hexchat (hexchat/hexchat#2335) and issue appears to be caused by the MODE change having the : without any spacing before the nickname
i.e. MODE #test +o :Guest3 Vs MODE #test +o : Guest3

Steps to reproduce the issue:

  1. User joins channel
  2. Recieve mode change (i.e. +o, +h, etc)

Describe the results you received:
Client side nicklist on client is not updated with status change.

Describe the results you expected:
Client side nick list is updated with correct status change

Additional information you deem important (e.g. issue happens only occasionally):
Hexchat message log

>> @time=2019-05-06T15:07:29.000Z :Guest3!~a@testnet-qs3.dod.0sg3ho.IP PART :#test
>> @time=2019-05-06T15:07:29.000Z :Guest3!~a@testnet-qs3.dod.0sg3ho.IP JOIN #test * :realname
<< MODE #test
<< WHO #test %chtsunfra,152
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 332 Guest3 #test :Feel free to test any bots, scripts, etc in this channel.
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 333 Guest3 #test admin :1403572744
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 353 Guest3 = #test :Guest3 @God @^Quark^
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 366 Guest3 #test :End of /NAMES list.
>> @time=2019-05-06T15:07:29.000Z :God!God@the.all.mighty.one NOTICE Guest3 :[#test] Welcome to #test. Feel free to test any bots, scripts, etc in this channel.
>> @time=2019-05-06T15:07:29.000Z :God!God@the.all.mighty.one MODE #test +o :Guest3
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 324 Guest3 #test :+Pnt
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 329 Guest3 #test :1403572555
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 354 Guest3 152 #test ~a testnet-qs3.dod.0sg3ho.IP irc.deb1.lan Guest3 H@s 0 :realname
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 354 Guest3 152 #test God the.all.mighty.one irc.deb1.lan God H@ 0 :Also known as Satan
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 354 Guest3 152 #test ~quantum quark.lan irc.deb1.lan ^Quark^ H@s ^Quark^ :Quarkly
>> @time=2019-05-06T15:07:29.000Z :irc.deb1.lan 315 Guest3 #test :End of /WHO list.
<< PING LAG2327093070
>> @time=2019-05-06T15:07:32.000Z :irc.deb1.lan PONG irc.deb1.lan :LAG2327093070
<< NAMES #test
>> @time=2019-05-06T15:07:57.000Z :irc.deb1.lan 353 Guest3 = #test :@Guest3 @God @^Quark^
>> @time=2019-05-06T15:07:57.000Z :irc.deb1.lan 366 Guest3 #test :End of /NAMES list.
<< WHO #test %chtsunfra,152
<< PING LAG2327123071
>> @time=2019-05-06T15:08:02.000Z :irc.deb1.lan 354 Guest3 152 #test ~a testnet-qs3.dod.0sg3ho.IP irc.deb1.lan Guest3 H@s 0 :realname
>> @time=2019-05-06T15:08:02.000Z :irc.deb1.lan 354 Guest3 152 #test God the.all.mighty.one irc.deb1.lan God H@ 0 :Also known as Satan
>> @time=2019-05-06T15:08:02.000Z :irc.deb1.lan 354 Guest3 152 #test ~quantum quark.lan irc.deb1.lan ^Quark^ H@s ^Quark^ :Quarkly
>> @time=2019-05-06T15:08:02.000Z :irc.deb1.lan 315 Guest3 #test :End of /WHO list.
>> @time=2019-05-06T15:08:02.000Z :irc.deb1.lan PONG irc.deb1.lan :LAG2327123071
<< PING LAG2327153071

Workaround of running a manual /names fixes the issue, until someone else joins.

Output of ./bin/inspircd --version:
InspIRCd-3.0.0

@SadieCat

This comment has been minimized.

Copy link
Member

@SadieCat SadieCat commented May 7, 2019

This is a client issue (which is why HexChat have fixed it in Git) as the messages we send are entirely valid according to the formatting rules in part 2.3.1 of RFC 1459 (note two is of specific relevance here). If mIRC is also having problems parsing the messages we send then please report them to the developer.

This is also unfortunately not something we can really work around because of the changes in how we emit messages which were necessary for robust tag support. In order to work around these client bugs we would need to go through every single place that messages are sent and manually specify whether a message should be emitted with a <trailing> parameter or not which would take many days of effort and would have a performance hit on InspIRCd's message serialisation.

Contrary to some of the claims which have been made recently in #inspircd we could not just check if the final parameter of a message is empty or contains a space because the same broken parsers would choke on messages like :foo!bar@baz PRIVMSG #test hi.

This isn't a difficult bug for client developers to fix (ircdocs even provides parser test vectors) so please ask them to fix it.

@sacredland

This comment has been minimized.

Copy link

@sacredland sacredland commented Aug 3, 2019

I got the same trouble, only with inspircd v3. Why you need client to get fixed, when they work well on other ircd? It's clearly due to something wrong into inpsircd v3.

On androirc same thing happen, but when you do /names or /list it's duplicate the nickname list and adding status to user, so you have @nick and nick into the nick list.. just duplication. with and without status.

And "you better code your clients to fix our mistake" or "it's a client issue" isn't a good answer, as it is not an issue on any other ircd (ircu [even from undernet!!], nafarious2, bahamut, ratbox, plexus, charybdis). I hope you don't think this is a viable way to promote inspircd v3.

@SadieCat

This comment has been minimized.

Copy link
Member

@SadieCat SadieCat commented Aug 3, 2019

. Why you need client to get fixed, when they work well on other ircd?

Just because it happens to work with other IRC server implementations doesn't mean its not broken.

The parsing rules in RFC 1459 are very clear about how messages should be parsed and InspIRCd emits messages which are valid according to those rules. We can't work around this bug without a ton of effort and essentially reverting to the way messages were handled in v2 which isn't compatible with tags.

There's plenty of clients which actually follow the IRC specs. Maybe use one of those instead?

@inspircd inspircd locked as too heated and limited conversation to collaborators Aug 3, 2019
@inspircd inspircd deleted a comment from sacredland Aug 3, 2019
@SadieCat

This comment has been minimized.

Copy link
Member

@SadieCat SadieCat commented Dec 21, 2019

Update: this is now fixed in HexChat 2.14.3.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
3 participants
You can’t perform that action at this time.