Page MenuHomePhabricator

Consecutive /s merged in PATH_INFO URLs on Apache 2
Closed, ResolvedPublic

Description

Author: gangleri

Description:
Halló!

Please go at http://jadesukka.homelinux.org:8180/betawiki/Luokka:Pseudo_hidden .

Change your prefferences to English. Press CTRL-SHIFT-R in Mozilla Firefox.

There is an entry that looks like <nowiki>Http://bugzilla.wikimedia.org/</nowiki>

a) click on it and you will think it is empty
b) go to Recentchanges
http://jadesukka.homelinux.org:8180/betawiki/Toiminnot:Recentchanges and click on
<nowiki>Http://bugzilla.wikimedia.org/</nowiki>
this will open
<nowiki>http://jadesukka.homelinux.org:8180/mediawiki15c/index.php?title=Http://bugzilla.wikimedia.org/&rcid=696</nowiki>
(hope that the page in bugzilla does not break again)

This is not the only one:

http://jadesukka.homelinux.org:8180/mediawiki15c/index.php?title=/&rcid=581

At
<nowiki>http://jadesukka.homelinux.org:8180/betawiki/K%C3%A4ytt%C3%A4j%C3%A4:Gangleri/feedback#existence_of_objects_.26ndash.3B_anomaly_with_image_namespace</nowiki>
You can see some tests.

There is a line "<nowiki>Compare with: [[: ]], [[:_]], #, [[:+]], /, :, &, ?, %,
$</nowiki>".
Klick on the link "/". This is the same behaviour.

Read the "notes" about behaviour at [[yi:User:Gangleri/tests#curiosity .2F]] .

Hope that [[fi:user:ikerabbit]] can tell you more about his Betawiki.

Thanks for your time reading and fixing this.

Regards Reinhardt


Version: unspecified
Severity: normal
URL: http://jadesukka.homelinux.org:8180/betawiki/A//b

Details

Reference
bz2088

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 8:28 PM
bzimport set Reference to bz2088.
bzimport added a subscriber: Unknown Object (MLST).
  • Bug 2220 has been marked as a duplicate of this bug. ***

zigger wrote:

See also bug 98 and bug 428.

gangleri wrote:

This bug has impacts on [[Special:Random]] because these pages are "selected
randomly" but not displayed properly. It can happen that "this pages does not
exist" will be shown.

See
http://jadesukka.homelinux.org:8180/mediawiki15c/index.php?title=/move&rcid=2646

Regards Reinhardt

zigger wrote:

This is in the ASF bug database for "Apache httpd-2.0". See
http://issues.apache.org/bugzilla/show_bug.cgi?id=10775 ("SCRIPT_NAME wrong
value"), which has a similar underlying issue with PATH_INFO as bug 1519.

A fix could a bit more complicated than the one for bug 1519, as it needs to
deal with two broken environment variables, either one of which may be fixed
first in a future Apache release, and it also needs to handle combinations of
leading, embedded, and trailing slashes.

Alternatively, the code could just parse REQUEST_URI itself. For other Apache
2.0 issues with PATH_INFO, see
http://issues.apache.org/bugzilla/buglist.cgi?query_format=specific&order=relevance+desc&bug_status=__all__&product=Apache+httpd-2.0&content=PATH_INFO

One work-around is to stop using pretty URLs by setting $wgUsePathInfo to false
in LocalSettings.php.

zigger wrote:

(In reply to comment #5)

... Alternatively, the code could just parse REQUEST_URI itself. ...

If this is done, watch out for encoding differences. REQUEST_URI is
URL-encoded, while PATH_INFO and SCRIPT_NAME are normalised.

This should have been resolved by the new title interpolation code in 1.10 or 1.11. Resolving as FIXED; reopen if still encountering such troubles.