Anope Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0001662Anope Stable (2.0.x series)[All Projects] Generalpublic2015-09-23 16:552015-12-14 02:43
Reportercapitaine 
Assigned ToAdam 
PrioritynormalSeverityminorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformOSOS Version
Summary0001662: Accesses zero or negative are allowed
DescriptionAnope previous version used levels NOJOIN and AUTODEOP which were negative by default.

Now they're gone, but negative accesses add confusion, because Chanserv acts like if they're actually zero, and it's a change of behaviour.

So I guess command Chanserv ACCESS shoud not allow adding an access of 0 nor negative, and maybe module db_old should delete negative accesses, or print a warning.
Steps To Reproduce/Chanserv LEVELS #channel SET AUTOHALFOP -5
ChanServ - Level for GREET on channel #channel changed to -10.
/Chanserv ACCESS #channel ADD foo -10
ChanServ - foo added to #channel access list at level -5.

When foo joins #channel,
he was not granted anything on Anope 1.8, but is +h on 2.0
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0006775)
Adam (administrator)
2015-12-14 02:43

fixed in 3da2cdb49604f6814e0357e3372389326b1a9152
(0006762)
Adam (administrator)
2015-09-24 23:21

This is because a negative level matches anyone. I'm not sure why, it used to be only -1 matched everyone.
(0006761)
azander (developer)
2015-09-24 14:01

They are not meaningless. I still use negative access levels to control non-registered users in my help channels.

They are useful for dealing with game channels where many, if not most, of the users never register their nicks but keep their host mask.
(0006759)
capitaine (reporter)
2015-09-24 11:55

Ok you're right for 0, sorry. I was mistaken by that message, when do :

/Chanserv ACCESS #channel ADD foo -10000
ChanServ - Access level must be between -9999 and 10000 inclusive.

However negative accesses don't make sense, because the ACCESS help says :
"any unregistered user has a user level -1"
So, even if negative levels are actually useful, adding a neg access is not needed actually, as it must be done for a registered user and it's quite confusing.

For the reproducing steps, you're also right. I've done too many tests and just mixed the replies.
My bad... but here they are :

Anope 1.8

/Chanserv LEVELS #channel SET NOJOIN -100
ChanServ - Level for NOJOIN on channel #channel changed to -100.
/Chanserv LEVELS #channel SET AUTOHALFOP -5
ChanServ - Level for AUTOHALFOP on channel #channel changed to -5.
/Chanserv ACCESS #channel ADD foo -10
ChanServ - foo added to #channel access list at level -10.

:foo!user@---97EFBFD9 JOIN :#channel
:ChanServ!services@example.com MODE #channel -o :foo


Then Anope 2.0

/Chanserv LEVELS #channel SET AUTOHALFOP -5
ChanServ - Level for AUTOHALFOP on channel #channel changed to -5.
/Chanserv ACCESS #channel ADD foo -10
ChanServ - foo added to #channel access list at level -10.

:foo!user@---97EFBFD9 JOIN :#channel
:ChanServ!services@example.com MODE #channel +rh-o foo :foo


Finally, that -1 to -9999 access range has been inherited from the previous Anope, and is meaningless now.
(0006758)
Adam (administrator)
2015-09-24 00:38

Also your steps to reproduce makes no sense because:

(18:37:17) <@Adam> for example he sets autohalfop to -5, and the reply from chanserv is greet set to -10
(18:37:22) <@Adam> and then he sets access add foo -10
(18:37:25) <@Adam> and it replies added at level -5
(18:37:36) <@Adam> so.. what
(18:37:41) <@Adam> I cant tell at all what is what
(0006756)
Adam (administrator)
2015-09-23 23:26

ACCESS has never allowed adding an access of 0, if it does now that is a bug. I think it does not because of

                if (!level)
                {
                        source.Reply(_("Access level must be non-zero."));
                        return;
                }

Negative access can be useful with negative levels, so I don't think it should be removed.

- Issue History
Date Modified Username Field Change
2015-09-23 16:55 capitaine New Issue
2015-09-23 23:26 Adam Note Added: 0006756
2015-09-24 00:38 Adam Note Added: 0006758
2015-09-24 11:55 capitaine Note Added: 0006759
2015-09-24 14:01 azander Note Added: 0006761
2015-09-24 23:21 Adam Note Added: 0006762
2015-12-14 02:43 Adam Note Added: 0006775
2015-12-14 02:43 Adam Status new => resolved
2015-12-14 02:43 Adam Resolution open => fixed
2015-12-14 02:43 Adam Assigned To => Adam


Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker