Last modified: 2014-02-02 18:49:57 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T36670, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 34670 - Check all wikis for inclusions of http resources on https
Check all wikis for inclusions of http resources on https
Status: ASSIGNED
Product: Wikimedia
Classification: Unclassified
General/Unknown (Other open bugs)
unspecified
All All
: Normal normal (vote)
: ---
Assigned To: Chris Steipp
:
Depends on:
Blocks: 38516
  Show dependency treegraph
 
Reported: 2012-02-24 02:20 UTC by Sam Reed (reedy)
Modified: 2014-02-02 18:49 UTC (History)
9 users (show)

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


Attachments

Description Sam Reed (reedy) 2012-02-24 02:20:38 UTC
Per IRC, it was noted numerous sites were including arbitrary http files in CSS, JS and otherwise which isn't good.

If we can gather a list of offending wikis, we can look at trying to fix them up.

Visiting the main page on all wikis via HTTPS should be enough
Comment 1 Sam Reed (reedy) 2012-02-24 04:06:07 UTC
Chris, just a further note on this - It's not something we need to do every upgrade, it's a "1 off" task post our proper HTTPS switchover in the latter half of last year.
Comment 3 Sam Reed (reedy) 2012-02-24 14:58:52 UTC
Links don't matter so much, but inclusion of resources does more
Comment 4 Sam Reed (reedy) 2012-02-24 15:09:14 UTC
<Nemo_bis> Reedy, hoo has switched about 3000 MediaWiki messages (with CSS, JS, whatever) to protocol-relative URLs and this should have fixed most of it on most wikis
<Nemo_bis> except evil JS which produce HTTP links with string manipulation
Comment 5 Chris McMahon 2012-02-27 18:57:26 UTC

If I understand the correctly, checking on commons, given that commons seems to be the most complex wiki to have gotten 1.19 so far, I find on https://commons.wikimedia.org/w/index.php?title=Special%3ASearch&profile=advanced&search=http%3A%2F%2F&fulltext=Search&ns8=1&profile=advanced many hundreds of results for "http://"

A quick check of the first few dozen results yields some suspicious links:

http://toolserver.org
http://stats.wikimedia.org
http://s23.org/wikistats/wmspecials_html.php
http://www.wikilovesmonuments.be
Comment 6 Nemo 2012-08-23 23:28:53 UTC
Reference to the cleanup mentioned above: [[m:Stewards'_noticeboard/Archives/2012-04#Fixing_HTTPS_on_Wikimedia_wikis]].

(In reply to comment #5)
> A quick check of the first few dozen results yields some suspicious links:
> 
> http://toolserver.org
> http://stats.wikimedia.org
> http://s23.org/wikistats/wmspecials_html.php
> http://www.wikilovesmonuments.be

What do you mean suspicious? 
Hoo, in the link above, said that Commons had already taken care of the problem. Most URLs in the search results, from a cursory reading, seem simple external links which can't always be replaced (although interwikis can be used for many toolserver.org URLs and all stats.wikimedia.org resources).
I'm not sure, however, if anyone went through all of them.
Comment 7 Marius Hoch 2012-08-24 16:04:22 UTC
It's true, that I already fixed several thousand of MediaWiki: pages including http only URIs, but there are some that can't be fixed that easily (eg. were the scripts are obfuscated or using nested imports [scripts which include even other scripts]).

Chris Steipp is working on that following an idea of mine, together with the 3rd party include problem. The idea behind that project is to scan the wikis using a real-user browser scenario, so that we find all inclusions, no matter how they're produced.

CCed and assigned to Chris... he'll post the result on meta wiki as soon as he got them.
Comment 8 Nemo 2012-08-24 18:12:29 UTC
(In reply to comment #7)
> Chris Steipp is working on that following an idea of mine, together with the
> 3rd party include problem. The idea behind that project is to scan the wikis
> using a real-user browser scenario, so that we find all inclusions, no matter
> how they're produced.

This also needs enabling (or otherwise including) all gadgets.
Comment 9 Nemo 2012-12-08 08:41:04 UTC
(In reply to comment #7)
> Chris Steipp is working on that following an idea of mine, together with the
> 3rd party include problem. The idea behind that project is to scan the wikis
> using a real-user browser scenario, so that we find all inclusions, no matter
> how they're produced.

Hoo, Chris, any update here, or way to help?
Comment 10 Marius Hoch 2012-12-17 17:28:21 UTC
Yes, I can give you an update... this is work in progress:
Chris had it running on his personal laptop but it broke after a change. As doing this on a laptop isn't a to good idea for such a large automated task the plan is to migrate it to a labs instance after the scripts have been fixed.
Comment 11 Chris Steipp 2013-09-27 21:47:58 UTC
I (finally) got around to writing a phantomjs script that loads Main_Page on all 878 wikis in all.dblist over https, and looks for any calls to http urls.

Current result for this issue:

https://ce.wikipedia.org
loads http://upload.wikimedia.org/wikipedia/commons/1/10/Wikipedia-logo-v2-200px-transparent.png

https://sa.wikipedia.org 
loads http://strategywiki.org/w/index.php?title=User:Najzere/edit_counter.js&action=raw&ctype=text/javascript

https://ve.wikimedia.org redirects to http://wikimedia.org.ve, no ssl on that domain
Comment 14 Sam Reed (reedy) 2013-09-27 22:37:48 UTC
(In reply to comment #11)
> https://ve.wikimedia.org redirects to http://wikimedia.org.ve, no ssl on that
> domain

Redirect works fine for me in my browser... No HTTPS on the target, but it doesn't try to go to HTTPS
Comment 15 Nemo 2013-09-28 05:22:27 UTC
(In reply to comment #11)
> I (finally) got around to writing a phantomjs script that loads Main_Page on
> all 878 wikis in all.dblist over https, and looks for any calls to http urls.

Does the script work as unregistered user? The easy bulk of such problems (stuff loaded by default, "http" mentions in MediaWiki namespace) was already resolved, though of course people keep reintroducing more, but gadgets are more unpredictable.
Quentinv57 has a JavaScript for global preferences change, maybe it can be adapted to enable all gadgets on all wikis for the test account.
Comment 16 Chris Steipp 2013-09-30 15:57:47 UTC
Next iteration will be to have it log in, and add every gadget available on every wiki... but I haven't figured that part out yet.
Comment 17 Nemo 2013-10-21 06:00:58 UTC
Quentin, can you confirm your script can enable all gadgets on all wikis for a test account for Chris?
Comment 18 Chris Steipp 2013-10-21 16:37:56 UTC
Does Quentin have a script for that? I haven't had the time to get one working yet, so it would be great to get that.
Comment 19 Nemo 2013-10-21 18:36:06 UTC
(In reply to comment #18)
> Does Quentin have a script for that? I haven't had the time to get one
> working
> yet, so it would be great to get that.

Yes, [[m:User:Pathoschild/Scripts/Synchbot#Global_settings_change]].
I think this applies: "Due to the potential for misuse, this bot is not open-source". https://github.com/Pathoschild/Wikimedia-contrib#readme
Maybe Pathoschild can give you the source too.
Comment 20 Chris Steipp 2013-11-01 23:50:06 UTC
Nemo was right. Ran a script to add all the gadgets to my user, and then reran my script to check Main_Page, action=edit for my user page, and Special:RecentChanges. These all popped up.


aswiki
* http://en.wikipedia.org/w/index.php?title=User:ProveIt_GT/ProveIt.js&action=raw&ctype=text/javascript

bnwikibooks
* http://en.wikipedia.org/w/index.php?title=User:ProveIt_GT/ProveIt.js&action=raw&ctype=text/javascript

dewikiversity
* http://toolserver.org/~w/ggu/?format=cssmarker&localuser=Benutzer&query=sysop@dewikiversity@P%7Cbureaucrat@dewikiversity@B
* http://toolserver.org/~w/ggu/?format=cssmarker&localuser=Benutzer&query=sysop@dewikiversity@P%7Cbureaucrat@dewikiversity@B%7Csysop@commonswiki@C%7Csteward@metawiki@S

dvwiktionary
* http://commons.wikimedia.org/w/index.php?title=MediaWiki:Gadget-HotCat.js&action=raw&ctype=text/javascript

elwiki
* http://prototype.wikimedia.org/mwe-gadget/mwEmbed/remotes/mediaWiki.js?uselang=el

elwikinews
* http://meta.wikimedia.org/w/index.php?title=MediaWiki:Wikiminiatlas.js&action=raw&ctype=text/javascript&smaxage=21600&maxage=86400
* http://commons.wikimedia.org/w/index.php?title=MediaWiki:Gadget-HotCat.js&action=raw&ctype=text/javascript&smaxage=21600&maxage=86400
* http://en.wikipedia.org/w/index.php?title=MediaWiki:Gadget-popups.js&action=raw&ctype=text/javascript&smaxage=21600&maxage=86400
* http://meta.wikimedia.org/w/index.php?title=MediaWiki:Wikiminiatlas.js&action=raw&ctype=text/javascript&smaxage=21600&maxage=86400
* http://commons.wikimedia.org/w/index.php?title=MediaWiki:Gadget-HotCat.js&action=raw&ctype=text/javascript&smaxage=21600&maxage=86400

eswikiquote
* http://commons.wikipedia.org/skins-1.5/monobook/headbg.jpg
* http://es.wikipedia.org/skins-1.5/amethyst/chat.png
* http://upload.wikimedia.org/wikipedia/commons/b/ba/Search_button_bckg.png
* http://es.wikipedia.org/skins-1.5/amethyst/configure.png
* http://es.wikipedia.org/skins-1.5/amethyst/connect.png
* http://es.wikipedia.org/skins-1.5/amethyst/mainpage.png
* http://es.wikipedia.org/skins-1.5/amethyst/portal.png
* http://es.wikipedia.org/skins-1.5/amethyst/recentchanges.png
* http://es.wikipedia.org/skins-1.5/amethyst/random.png
* http://es.wikipedia.org/skins-1.5/amethyst/help.png
* http://es.wikipedia.org/skins-1.5/amethyst/sitesupport.png
* http://es.wikipedia.org/skins-1.5/amethyst/chat.png
(and a few more amethyst urls)

euwiki
* http://prototype.wikimedia.org/mwe-gadget/mwEmbed/remotes/mediaWiki.js?uselang=eu
* http://prototype.wikimedia.org/mwe-gadget/mwEmbed/remotes/mediaWiki.js?uselang=eu
* http://upload.wikimedia.org/wikipedia/commons/e/ea/Button_easy_cite.png

orwiktionary
* http://commons.wikimedia.org/w/index.php?title=MediaWiki:Gadget-HotCat.js&action=raw&ctype=text/javascript

ruwikinews
* http://ru.wikipedia.org/w/index.php?action=raw&ctype=text/javascript&title=MediaWiki:Stemmer.js
Comment 21 Ruslan 2013-11-03 16:36:27 UTC
I fixed all above except bnwikibooks (can not find anything), eswikiquote and also
http://upload.wikimedia.org/wikipedia/commons/e/ea/Button_easy_cite.png on euwiki (can not find either).

It was a good news actually that so few of them turned up.

In fact, a bigger problem is 404 errors.

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


Navigation
Links