Page MenuHomePhabricator

Tool Labs: Local webservice should know about HTTPS in original request
Closed, ResolvedPublic

Description

See https://tools.wmflabs.org/liangent-php/detectProtocol.php/enwiki

Feel free to move this bug to MediaWiki product if there's some reliable way to check so there while MediaWiki is unaware of it.


Version: unspecified
Severity: normal
See Also:
https://bugzilla.wikimedia.org/show_bug.cgi?id=64627

Details

Reference
bz53689

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 1:45 AM
bzimport added a project: Toolforge.
bzimport set Reference to bz53689.

(Consequently this causes a redirect loop in MediaWiki installations on Tool-Lab with $wgSecureLogin = true; and this is why I spotted it)

Ah, interesting. The communication between the proxy and the internal webservers currently occur through HTTP over the (virtual) network (with the proxy taking care of encryption) -- it's not immediately clear to me how this could be hidden from the application.

Is it possible to configure the proxy to add X-Forwarded-Proto, like http://www.geekisp.com/faq/6_65_en.html ?

Hm; that should be simple enough actually. Lemme see what I can do.

And indeed, it was. The X-Forwarded-Proto header should now be present.

Looks like this doesn't work anymore, may or may not be caused by tools being additionally proxied to tools-eqiad.

https://tools.wmflabs.org/blankpages/_server.php

[HTTP_X_FORWARDED_PROTO] => http