Page MenuHomePhabricator

Special:RecentChanges shouldn't show "rollback" for namespaces the user can't edit
Closed, ResolvedPublic

Description

To reproduce:

  1. Login using an account that has rollback rights but not admin rights.
  2. View [[Special:RecentChanges]] in MediaWiki namespace.

Current result:

There is a "rollback" link after the name of each Mediawiki page. Clicking that link gives an error: "You do not have permission to quickly rollback the edits of the last user who edited a particular page... etc"

Expected result:

This shouldn't be links to rollback MediaWiki pages in recent changes for non-admin users because they can't edit pages in MediaWiki namespace.

This bug was encountered on arwiki.

MediaWiki 1.22wmf4 (281e88a)
PHP 5.3.10-1ubuntu3.6+wmf1 (apache2handler)
MySQL 5.1.53-wm-log
LuaSandbox 1.6-1
Lua 5.1.4

Event Timeline

bzimport raised the priority of this task from to Low.Nov 22 2014, 1:25 AM
bzimport set Reference to bz48731.

I cannot seem to replicate this issue. Is anybody else experiencing this?

Screenshot

Notice the blue circle

Attached:

Capture.PNG (1×1 px, 272 KB)

I couldn't replicate it either.

(In reply to comment #3)

I couldn't replicate it either.

The bug summary is wrong. This happens for pages in MediaWiki namespace only not any page the user can't edit.

Realized why I couldn't replicate: forgot to give my user rollback permissions. ;)

Will have a patch momentarily.

Related URL: https://gerrit.wikimedia.org/r/66191 (Gerrit Change I3a037af5839b20d1161dcfbb5329df1e9f2989ec)

Change 66191 abandoned by Parent5446:
Fixed permissions check for showing rollback link in RC

Reason:
Doesn't seem to be a way to fix this.

https://gerrit.wikimedia.org/r/66191

Change 415899 had a related patch set uploaded (by Matěj Suchánek; owner: Matěj Suchánek):
[mediawiki/core@master] Ensure whether user can rollback page in ChangesList

https://gerrit.wikimedia.org/r/415899

Restricted Application added a subscriber: alaa. · View Herald TranscriptMar 2 2018, 5:25 PM

Change 415899 merged by jenkins-bot:
[mediawiki/core@master] Ensure whether user can rollback page in ChangesList

https://gerrit.wikimedia.org/r/415899