Last modified: 2010-05-15 15:59:41 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 12418 - Database error when trying to view a Special: page without read permission
Database error when trying to view a Special: page without read permission
Status: RESOLVED DUPLICATE of bug 11668
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
All All
: Lowest trivial (vote)
: ---
Assigned To: Nobody - You can work on this!
Depends on:
  Show dependency treegraph
Reported: 2007-12-26 02:34 UTC by Dan Jacobson
Modified: 2010-05-15 15:59 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Description Dan Jacobson 2007-12-26 02:34:08 UTC
In case one is looking for ways to generate PHP error messages, in
LocalSettings.php set $wgGroupPermissions['*']['read']=false; and then
browse e.g., [[Special:zzzzzz]], [[Special:Specialpages]].
Comment 1 Victor Vasiliev 2007-12-26 07:47:45 UTC
I can't see any error messages. May you show which error messages are shown?
Comment 2 Roan Kattouw 2007-12-26 17:58:45 UTC
(In reply to comment #1)
> I can't see any error messages. May you show which error messages are shown?

A database query syntax error has occurred. This may indicate a bug in the software. The last attempted database query was:

    SELECT * FROM `protected_titles` WHERE pt_namespace = '-1' AND pt_title = 'Specialpages' 

from within function "Database::select". MySQL returned error "1146: Table 'wiki.protected_titles' doesn't exist (localhost)".

Could that be the error message? In that case you have to run maintenance/update.php

I also don't get any errors, neither in 1.12svn nor in 1.11.0
Comment 3 Dan Jacobson 2007-12-28 00:06:16 UTC
OK, perhaps you can reproduce the following from my _offline_ _simulated_

In LocalSettings.php use
$wgShowExceptionDetails = true;

Note the incorrect behavior with title=Special:Zzz,
and the correct behavior with title=Zzz, both of which do not exist.

  $ w3m -dump\&uselang=en
  [transgende]Internal error

  Invalid special page name ""


  #0 /var/lib/mediawiki-1.11.0/includes/Title.php(1305): SpecialPage::getTitleFor
  #1 /var/lib/mediawiki-1.11.0/includes/Wiki.php(133): Title->userCanRead()
  #2 /var/lib/mediawiki-1.11.0/includes/Wiki.php(43): MediaWiki->
  preliminaryChecks(Object(Title), Object(StubObject), Object(WebRequest))
  #3 /var/lib/mediawiki-1.11.0/index.php(89): MediaWiki->initialize(Object
  (Title), Object(StubObject), Object(User), Object(WebRequest))
  #4 {main}

  $ w3m -dump\&uselang=en
  Login Required ... You must log in to view other pages...

So we see requests for special pages that don't exist bypass some
checks, getting themselves into trouble.

What is worst is requests for special pages that _do_ exist.

  $ w3m -dump\&uselang=en

  Warning: in_array() []: Wrong datatype for second argument in
  /var/lib/mediawiki-1.11.0/includes/Title.php on line 1306

  Login Required... You must log in to view other pages.

The error message jabs itself into the HTML...

Same error e.g., for Special:Listusers.

(Browser above doesn't send any cookies, but that doesn't matter.)
(The above is from a vanilla fresh install of 1.11. No need to run update.php.)
Comment 4 Brion Vibber 2007-12-28 01:12:51 UTC

*** This bug has been marked as a duplicate of bug 11668 ***

Note You need to log in before you can comment on or make changes to this bug.