Page MenuHomePhabricator

Bind the 'sendemail' user right to a wiki page
Closed, DeclinedPublic

Description

The 'sendemail' user right is currently not bound to any specific page; in the code, this means that authorization is done simply by checking if the user has the right or not. This prevents us from using Authority methods such as authorizeRead/authorizeWrite, which require a title. And in turn, this means that Authority won't be able to check the ratelimiter for us once T310476 is resolved.

The main question would be what page it should be bound to. Binding the right to a page means that the authorization process will also check other things like partial blocks. Depending on whether we want this to be the case for emails (which is the second question), the implementation would be different.

Event Timeline

Note that this may not be necessary (at least for what concerns the ratelimiter rationale) if r814359 is implemented.

Declining in favour of the proposed authorizeDo approach.