mirror of
https://github.com/unrealircd/unrealircd.git
synced 2026-06-12 17:14:46 +02:00
Fix deny channel::mask not working if security group. Reported by PeGaSuS.
This commit is contained in:
+12
-12
@@ -10874,12 +10874,22 @@ int _test_deny(ConfigFile *conf, ConfigEntry *ce)
|
|||||||
char has_mask = 0, has_match = 0;
|
char has_mask = 0, has_match = 0;
|
||||||
for (cep = ce->items; cep; cep = cep->next)
|
for (cep = ce->items; cep; cep = cep->next)
|
||||||
{
|
{
|
||||||
if (config_is_blankorempty(cep, "deny channel"))
|
if (!strcmp(cep->name, "match"))
|
||||||
|
{
|
||||||
|
has_match = 1;
|
||||||
|
test_match_block(conf, cep, &errors);
|
||||||
|
}
|
||||||
|
else if (!strcmp(cep->name, "mask"))
|
||||||
|
{
|
||||||
|
has_mask = 1;
|
||||||
|
test_match_block(conf, cep, &errors);
|
||||||
|
}
|
||||||
|
else if (config_is_blankorempty(cep, "deny channel"))
|
||||||
{
|
{
|
||||||
errors++;
|
errors++;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp(cep->name, "channel"))
|
else if (!strcmp(cep->name, "channel"))
|
||||||
{
|
{
|
||||||
if (has_channel)
|
if (has_channel)
|
||||||
{
|
{
|
||||||
@@ -10929,16 +10939,6 @@ int _test_deny(ConfigFile *conf, ConfigEntry *ce)
|
|||||||
}
|
}
|
||||||
has_class = 1;
|
has_class = 1;
|
||||||
}
|
}
|
||||||
else if (!strcmp(cep->name, "match"))
|
|
||||||
{
|
|
||||||
has_match = 1;
|
|
||||||
test_match_block(conf, cep, &errors);
|
|
||||||
}
|
|
||||||
else if (!strcmp(cep->name, "mask"))
|
|
||||||
{
|
|
||||||
has_mask = 1;
|
|
||||||
test_match_block(conf, cep, &errors);
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
config_error_unknown(cep->file->filename,
|
config_error_unknown(cep->file->filename,
|
||||||
|
|||||||
Reference in New Issue
Block a user