Page MenuHomePhabricator

allow list=deletedrevs&drprop=content with "deletedtext"
Closed, ResolvedPublic

Description

The user right deletedtext should allow viewing of deleted content with list=deletedrevs like Special:Undelete

Thanks.


Version: 1.18.x
Severity: enhancement

Details

Reference
bz28261

Event Timeline

bzimport raised the priority of this task from to Normal.Nov 21 2014, 11:34 PM
bzimport added a project: MediaWiki-API.
bzimport set Reference to bz28261.
Reedy added a comment.May 20 2011, 5:55 PM

What should the behaviour be if the user doesn't have deletedhistory, but has deletedtext? :/

It seems to be, Special:Undelete doesn't allow this

		$this->setHeaders();
		if ( !$this->userCanExecute( $wgUser ) ) {
			$this->displayRestrictionError();
			return;
		}

Or are you literally meaning, if they're allowed to view the history, AND they are allowed to view the text, be able to get the text as a property?

the api is only checked for 'undelete' when using prop=content, but when a user has 'deletedtext' but not 'undelete' he can use the gui to see the content, but not the api.

'deletedhistory' without 'deletedtext' makes no sense, that is right.

'deletedhistory' without 'undelete' also is not allow

Was about to file this but but seems it's already around :). It's possible it would have to be adjusted to require both deletedhistory and deletedtext but it does make sense to allow access via the api without undelete. With the principles of least access you should not have to give someone the ability to undelete the page in order to let them see deleted information.

As an example use case (unsurprisingly from where I discovered it) a researcher may need to see deleted information and is likely to want to use the API rather then just the interface (where they can already view it without undelete). They have no need to actually undelete pages and there is no reason to let them have that ability.

I have another issue to fix first, but then I'll fix this.

Change 107389 had a related patch set uploaded by Anomie:
Improve API query RevDel handling

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

Change 107389 merged by jenkins-bot:
Improve API query RevDel handling

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

This change should be deployed to WMF wikis with 1.23wmf11, see https://www.mediawiki.org/wiki/MediaWiki_1.23/Roadmap for the schedule.