View Issue Details

IDProjectCategoryView StatusLast Update
0006606unrealircdpublic2026-01-23 07:48
Reporterprogval Assigned Tosyzop  
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Summary0006606: Regression: services kill users who use post-registration SASL
Description1. User "bar" connects (without authenticating), gets RPL_WELCOME, MOTD, etc.
2. User "bar" SASLs, gets back "My.Little.Server 903 bar :SASL authentication successful"
3. User "bar" gets RPL_WELCOME and MOTD **again**
4. User "bar" gets killed: :My.Little.Services KILL bar :My.Little.Services (Ghost detected via nick collision (new))

This happens with both Atheme and Anope, since https://github.com/unrealircd/unrealircd/commit/0cf0c0faa27ccfc4308834cb98ae92dcc0c31b64
Steps To ReproduceLogs:

1. User "bar" connects (without authenticating), gets RPL_WELCOME, MOTD, etc.

1769034260.675 1: connects to server.
1769034260.675 1 -> S: CAP LS 302
1769034260.675 S -> 1: :My.Little.Server CAP * LS * :unrealircd.org/link-security=2 unrealircd.org/plaintext-policy=user=allow,oper=warn,server=warn unrealircd.org/history-storage=memory draft/metadata-notify-2 draft/metadata-2=max-sub=10,max-valu away-notify invite-notify extended-join userhost-in-names multi-prefix cap-notify sasl setname tls chghost account-notify message-tags batch server-time account-tag echo-message labeled-response draft/chathistory extended-monitor standard-replies draft/no-implicit-names
1769034260.675 S -> 1: :My.Little.Server CAP * LS :draft/extended-isupport unrealircd.org/json-log
1769034260.675 1 -> S: CAP REQ :sasl
1769034260.675 S -> 1: :My.Little.Server CAP * ACK :sasl
1769034260.675 1 -> S: NICK bar
1769034260.675 1 -> S: USER username * * :Realname
1769034260.675 1 -> S: CAP END
1769034260.675 S -> 1: PING :DE5D195F
1769034260.675 1 -> S: PONG :DE5D195F
[info] Client connecting: bar (~username@localhost) [127.0.0.1] [vhost: Clk-4D552FD5] [class: clients] [reputation: 0] [security-groups: unknown-users]
1769034260.675 S -> 1: :My.Little.Server 001 bar :Welcome to the ExampleNET IRC Network bar!~username@localhost
1769034260.676 S -> 1: :My.Little.Server 002 bar :Your host is My.Little.Server, running version UnrealIRCd-6.2.3-git
1769034260.676 S -> 1: :My.Little.Server 003 bar :This server was created Wed Jan 21 2026 at 22:05:35 UTC
1769034260.676 S -> 1: :My.Little.Server 004 bar My.Little.Server UnrealIRCd-6.2.3-git diopqrstwxzBDGHIRSTWZ beIacdfhiklmnopqrstvzCDFGHKLMNOPQRSTVZ
1769034260.676 S -> 1: :My.Little.Server 005 bar ACCOUNTEXTBAN=account,a AWAYLEN=307 BOT=B CASEMAPPING=ascii CHANLIMIT=#:10 CHANMODES=beI,fkL,lFH,cdimnprstzCDGKMNOPQRSTVZ CHANNELLEN=32 CHANTYPES=# CHATHISTORY=50 CLIENTTAGDENY=*,-draft/typing,-typing,-draft/channel-context,-draft/reply DEAF=d ELIST=MNUCT :are supported by this server
1769034260.676 S -> 1: :My.Little.Server 005 bar EXCEPTS EXTBAN=~,acfijmnpqrtACFGOST INVEX KICKLEN=307 KNOCK MAP MAXLIST=b:60,e:60,I:60 MAXNICKLEN=30 METADATA=10 MINNICKLEN=0 MODES=12 MONITOR=128 :are supported by this server
1769034260.676 S -> 1: :My.Little.Server 005 bar MSGREFTYPES=msgid,timestamp NAMELEN=50 NAMESX NETWORK=ExampleNET NICKLEN=30 PREFIX=(qaohv)~&@%+ QUITLEN=307 SAFELIST SILENCE=15 STATUSMSG=~&@%+ TARGMAX=DCCALLOW:,ISON:,JOIN:,KICK:4,KILL:,LIST:,NAMES:1,NOTICE:1,PART:,PRIVMSG:4,SAJOIN:,SAPART:,TAGMSG:1,USERHOST:,USERIP:,WATCH:,WHOIS:1,WHOWAS:1 TOPICLEN=360 :are supported by this server
1769034260.676 S -> 1: :My.Little.Server 005 bar UHNAMES USERIP WALLCHOPS WATCH=128 WATCHOPTS=A WHOX :are supported by this server
1769034260.676 S -> 1: :My.Little.Server 396 bar Clk-4D552FD5 :is now your displayed host
1769034260.676 S -> 1: :My.Little.Server 251 bar :There are 1 users and 2 invisible on 2 servers
1769034260.676 S -> 1: :My.Little.Server 252 bar 2 :operator(s) online
1769034260.676 S -> 1: :My.Little.Server 255 bar :I have 1 clients and 1 servers
1769034260.676 S -> 1: :My.Little.Server 265 bar 1 1 :Current local users 1, max 1
1769034260.676 S -> 1: :My.Little.Server 266 bar 3 3 :Current global users 3, max 3
1769034260.676 S -> 1: :My.Little.Server 375 bar :- My.Little.Server Message of the Day -
1769034260.676 S -> 1: :My.Little.Server 372 bar :- 21/1/2026 23:24
1769034260.676 S -> 1: :My.Little.Server 372 bar :-
1769034260.676 S -> 1: :My.Little.Server 376 bar :End of /MOTD command.
1769034260.676 S -> 1: :bar MODE bar :+iwx
1769034260.676 1 -> S: PING foo
1769034260.677 1 -> S: PING synchronize5404939.277276818
1769034260.677 S -> 1: :My.Little.Server PONG My.Little.Server :foo
1769034260.677 S -> 1: :My.Little.Server PONG My.Little.Server :synchronize5404939.277276818
1769034260.677 1 -> S: PING synchronize5404939.277462928
1769034260.677 S -> 1: :My.Little.Server PONG My.Little.Server :synchronize5404939.277462928

2. User "bar" SASLs, gets back "My.Little.Server 903 bar :SASL authentication successful"

1769034260.677 1 -> S: AUTHENTICATE PLAIN
1769034260.677 S -> 1: AUTHENTICATE +
1769034260.678 1 -> S: AUTHENTICATE amlsbGVzAGppbGxlcwBzZXNhbWU=
[info] Client connecting: bar (~username@localhost) [127.0.0.1] [vhost: Clk-4D552FD5] [class: clients] [account: jilles] [reputation: 0] [security-groups: known-users]

and now it looks bad:

[2026-01-21 23:24:20] user_add(): nick collision on bar
[info] Client killed: bar!~username@localhost [by: My.Little.Services] (My.Little.Services (Ghost detected via nick collision (new)))
1769034260.744 S -> 1: :My.Little.Server 900 bar bar!~username@localhost jilles :You are now logged in as jilles.
[info] Client exiting: bar (~username@localhost) [127.0.0.1] (Killed by My.Little.Services (My.Little.Services (Ghost detected via nick collision (new))))
1769034260.744 S -> 1: :My.Little.Server 903 bar :SASL authentication successful
1769034260.744 S -> 1: :My.Little.Server 001 bar :Welcome to the ExampleNET IRC Network bar!~username@localhost
1769034260.744 S -> 1: :My.Little.Server 002 bar :Your host is My.Little.Server, running version UnrealIRCd-6.2.3-git
1769034260.744 S -> 1: :My.Little.Server 003 bar :This server was created Wed Jan 21 2026 at 22:05:35 UTC
1769034260.744 S -> 1: :My.Little.Server 004 bar My.Little.Server UnrealIRCd-6.2.3-git diopqrstwxzBDGHIRSTWZ beIacdfhiklmnopqrstvzCDFGHKLMNOPQRSTVZ
1769034260.744 S -> 1: :My.Little.Server 005 bar ACCOUNTEXTBAN=account,a AWAYLEN=307 BOT=B CASEMAPPING=ascii CHANLIMIT=#:10 CHANMODES=beI,fkL,lFH,cdimnprstzCDGKMNOPQRSTVZ CHANNELLEN=32 CHANTYPES=# CHATHISTORY=50 CLIENTTAGDENY=*,-draft/typing,-typing,-draft/channel-context,-draft/reply DEAF=d ELIST=MNUCT :are supported by this server
1769034260.744 S -> 1: :My.Little.Server 005 bar EXCEPTS EXTBAN=~,acfijmnpqrtACFGOST INVEX KICKLEN=307 KNOCK MAP MAXLIST=b:60,e:60,I:60 MAXNICKLEN=30 METADATA=10 MINNICKLEN=0 MODES=12 MONITOR=128 :are supported by this server
1769034260.744 S -> 1: :My.Little.Server 005 bar MSGREFTYPES=msgid,timestamp NAMELEN=50 NAMESX NETWORK=ExampleNET NICKLEN=30 PREFIX=(qaohv)~&@%+ QUITLEN=307 SAFELIST SILENCE=15 STATUSMSG=~&@%+ TARGMAX=DCCALLOW:,ISON:,JOIN:,KICK:4,KILL:,LIST:,NAMES:1,NOTICE:1,PART:,PRIVMSG:4,SAJOIN:,SAPART:,TAGMSG:1,USERHOST:,USERIP:,WATCH:,WHOIS:1,WHOWAS:1 TOPICLEN=360 :are supported by this server
1769034260.744 S -> 1: :My.Little.Server 005 bar UHNAMES USERIP WALLCHOPS WATCH=128 WATCHOPTS=A WHOX :are supported by this server
1769034260.744 S -> 1: :My.Little.Server 396 bar Clk-4D552FD5 :is now your displayed host
1769034260.744 S -> 1: :My.Little.Server 251 bar :There are 1 users and 3 invisible on 2 servers
1769034260.744 S -> 1: :My.Little.Server 252 bar 2 :operator(s) online
1769034260.744 S -> 1: :My.Little.Server 253 bar -1 :unknown connection(s)
1769034260.744 S -> 1: :My.Little.Server 255 bar :I have 2 clients and 1 servers
1769034260.744 S -> 1: :My.Little.Server 265 bar 2 2 :Current local users 2, max 2
1769034260.744 S -> 1: :My.Little.Server 266 bar 4 4 :Current global users 4, max 4
1769034260.744 S -> 1: :My.Little.Server 375 bar :- My.Little.Server Message of the Day -
1769034260.744 S -> 1: :My.Little.Server 372 bar :- 21/1/2026 23:24
1769034260.744 S -> 1: :My.Little.Server 372 bar :-
1769034260.744 S -> 1: :My.Little.Server 376 bar :End of /MOTD command.
1769034260.744 S -> 1: :bar MODE bar :+iwx
1769034260.744 1 -> S: PING synchronize5404939.344167136
1769034260.744 S -> 1: :My.Little.Services KILL bar :My.Little.Services (Ghost detected via nick collision (new))
1769034260.744 S -> 1: ERROR :Closing Link: bar[localhost] (Killed by My.Little.Services (My.Little.Services (Ghost detected via nick collision (new))))
3rd party modules

Activities

syzop

2026-01-23 07:48

administrator   ~0023596

Fixed, thanks :D

commit c2db2715c09526aad0afe03070bc57433dbe1d9c (HEAD -> unreal60_dev, origin/unreal60_dev, origin/HEAD)
Author: Bram Matthys <[email protected]>
Date: Fri Jan 23 07:44:36 2026 +0100

    Fix post-registration SASL not working due to change from a few days ago.
    (commit 0cf0c0faa27ccfc4308834cb98ae92dcc0c31b64)
    
    This was caused by register_user() being called twice, while it should
    only have been called if !IsUser().
    
    Reported by ProgVal in https://bugs.unrealircd.org/view.php?id=6606
    My BuildBot screen was also all red :D.

commit a5f1aa7f348aef1979d09c291edc6c3c46a3ecb9
Author: Bram Matthys <[email protected]>
Date: Fri Jan 23 07:42:57 2026 +0100

    Print a [BUG] line if register_user() is called twice. Deliberately crash
    when running in DEBUGMODE.

Issue History

Date Modified Username Field Change
2026-01-21 23:26 progval New Issue
2026-01-23 07:48 syzop Assigned To => syzop
2026-01-23 07:48 syzop Status new => resolved
2026-01-23 07:48 syzop Resolution open => fixed
2026-01-23 07:48 syzop Note Added: 0023596