Page MenuHomePhabricator

Attempting to fetch privileged log type no longer yields a permission denied error
Closed, InvalidPublic

Description

Visit https://en.wikipedia.org/w/api.php?letype=spamblacklist&action=query&list=logevents&lelimit=10 when logged out. Compare https://en.wikipedia.org/wiki/Special:Log?type=spamblacklist&user=&page=&wpdate=&tagfilter= .

Expected: Permission denied error
Actual: No output. If you want to deny the existence of the log, do it properly: https://en.wikipedia.org/w/api.php?letype=fffffff&action=query&list=logevents&lelimit=10.

The regression occurred some time after November 18 2018.

Event Timeline

Anomie subscribed.

The regression occurred some time after November 18 2018.

This does not seem to be the case. It seems that this behavior actually goes back 10 years earlier, to rMW5e24e3b85c92: Add getExcludeClause(), hide items from API too.

If you want to deny the existence of the log, do it properly: https://en.wikipedia.org/w/api.php?letype=fffffff&action=query&list=logevents&lelimit=10.

That's not a valid comparison. In that case log type "fffffff" is not known to MediaWiki at all, while in the letype=spamblacklist the type does exist but the user lacks the rights necessary to see any of the log entries. The current behavior is correct.