Page 1 of 1
Automatically redirect unregistered
Posted: Thu Jun 04, 2026 1:56 pm
by David
Hi, I'm running UnrealIRCd 6.2.5. I want to automatically redirect unregistered users (not identified to NickServ) from channel #alfa to channel #beta. Is it possible to use "deny channel" with "redirect" and "mask { security-group unknown-users; }" to achieve this? If not, what is the correct syntax to redirect unregistered users to another channel?
Thx
Re: Automatically redirect unregistered
Posted: Thu Jun 04, 2026 2:55 pm
by PeGaSuS
Hi,
The
unknown-users security-group doesn't match
only unregistered users but also users that have a new IP even if they're old users (unless they use SASL).
One way to achieve what you want is by doing:
Code: Select all
/mode #alfa +b ~forward:#beta:~account:0
which will redirect users from #alfa to #beta that are not identified to services.
Useful reading:
UnrealIRCd Extended bans
Re: Automatically redirect unregistered
Posted: Thu Jun 04, 2026 3:02 pm
by CrazyCat
I think you can.
The documentation for deny channel doesn't seem to be up to date, but in the Security-group's documentation, I can see:
Where security groups are used
In any mask { } item in the configuration file, like oper Oper { mask { security-group xyz; } ...
That is in: allow::mask, ban user::mask, require authentication::mask, oper::mask, except ban::mask, tld::mask, vhost::mask, link::incoming::mask, deny channel::mask, allow channel::mask, connthrottle::except, blacklist::except, set::restrict::commands::except, set::antimixedutf8::except and set::antirandom::except
Doc:
https://www.unrealircd.org/docs/Security-group_block
Re: Automatically redirect unregistered
Posted: Thu Jun 04, 2026 3:21 pm
by David
I insisted on a permanent direction in the settings, but by setting the room to +P and entering +b, it still remains fixed.
Thanks PeGaSuS for your help
Re: Automatically redirect unregistered
Posted: Thu Jun 04, 2026 4:37 pm
by PeGaSuS
as CrazyCat pointed (and well), you can also use the config. I'd use something like:
Code: Select all
deny channel {
channel "#alfa";
reason "You need to have a registered account to join this channel.";
redirect "#beta";
mask {
exclude-identified yes;
}
}
I'm just a bit unsure about the
mask, but you can test the different variations from
here.
Just remember you will need to create a
deny channel block for each channel and on every server. OTOH, if you use Anope your users can do
/CS SET PERSIST #channel ON and then the channel won't be closed when the last user leaves and therefore any extban will be kept active, which makes this kind of management easier.
Re: Automatically redirect unregistered
Posted: Thu Jun 04, 2026 6:03 pm
by David
I tried as CrazyCat suggested and it gives me this error PeGaSuS.
Code: Select all
config.CONFIG_ERROR_GENERIC [error] /unrealircd/conf/unrealircd.conf:417: deny channel::mask specified without a value
I finally did the Persist mode and the ban and it works fine.
Thanks to both of you for your help.
Re: Automatically redirect unregistered
Posted: Thu Jun 04, 2026 9:31 pm
by CrazyCat
Didn't test but I think you needto create a security group first:
Code: Select all
security-group unidentified { identified no; }
And then your deny:
Code: Select all
deny channel {
channel "#alfa";
reason "You need to have a registered account to join this channel.";
redirect "#beta";
mask { security-group unidentified; }
}
EDIT does the same error...
Re: Automatically redirect unregistered
Posted: Fri Jun 05, 2026 2:58 pm
by PeGaSuS
David wrote: Thu Jun 04, 2026 6:03 pm
I tried as CrazyCat suggested and it gives me this error PeGaSuS.
Code: Select all
config.CONFIG_ERROR_GENERIC [error] /unrealircd/conf/unrealircd.conf:417: deny channel::mask specified without a value
I finally did the Persist mode and the ban and it works fine.
Thanks to both of you for your help.
Well, thanks to this another bug was fixed and now it should work as expected, if you don't want to use persistent channels.
