mediawiki.git
8 years agoUpdated release notes and version number of MediaWiki 1.22.61.22.6
mglaser [Thu, 24 Apr 2014 18:22:25 +0000 (24 20:22 +0200)]
Updated release notes and version number of MediaWiki 1.22.6

This is MediaWiki 1.22.6 security release

Change-Id: I1be03b64a52996e7adcf25e9f9354000c24f38f9

8 years agoSECURITY: escape sortKey in pageInfo
csteipp [Sat, 29 Mar 2014 05:39:57 +0000 (28 22:39 -0700)]
SECURITY: escape sortKey in pageInfo

DEFAULTSORT isn't escaped before being added to the action=info table.

Bug: 63251
Change-Id: I087bfde8cbc69c3507f68ee3cb6e22aba0ffa7db

8 years agoUpdated release notes and version number for MediaWiki 1.22.51.22.5
mglaser [Thu, 27 Mar 2014 20:55:39 +0000 (27 21:55 +0100)]
Updated release notes and version number for MediaWiki 1.22.5

This is MediaWiki 1.22.5 security and maintenance release

Change-Id: I233dc316ddb4aba60d626944261c9a37a6873bb9

8 years agoSECURITY: Add CSRF token on Special:ChangePassword
csteipp [Thu, 27 Mar 2014 00:53:07 +0000 (26 17:53 -0700)]
SECURITY: Add CSRF token on Special:ChangePassword

Use a login token when logged out user is using Special:ChangePassword
(should only happen when a user is forced to reset their password to
complete the login process).

Logged in users are not logged in as an effect of resetting their
password, and for them, the edit token check should be sufficient.

Bug: 62497
Change-Id: I08afed3e1aeeb8c97d24fe9858a3ba2c03e92adf

8 years agoremove duplicates from release notes
se4598 [Wed, 26 Mar 2014 23:00:57 +0000 (27 00:00 +0100)]
remove duplicates from release notes

they came in from a recent manual rebase of an old change, but they are
already listed in the section

Change-Id: Icb4df1b57f5da949d6f35062877838d115ad7c26

8 years agoupdate RELEASE-NOTES-1.22 for bug 60543
se4598 [Wed, 5 Feb 2014 22:27:20 +0000 (5 23:27 +0100)]
update RELEASE-NOTES-1.22 for bug 60543

also adding myself to CREDITS

Change-Id: I5b4477144f76748faf741bf6ef153b69f6d41ac0

8 years agoMerge "Set a title for the context during import on the cli" into REL1_22
jenkins-bot [Wed, 26 Mar 2014 14:59:41 +0000 (26 14:59 +0000)]
Merge "Set a title for the context during import on the cli" into REL1_22

8 years agoFix custom local MediaWiki:Helppage values
Matthew Flaschen [Wed, 26 Mar 2014 03:15:59 +0000 (25 23:15 -0400)]
Fix custom local MediaWiki:Helppage values

Followup to 3a6ea89d4aa4a0fbc36a209fa13b1c6134110ca9

Change-Id: I7effec352d263f536d1d1763e9cd56d2f5154f13
(cherry picked from commit dbede6aad31752fdfe317f7eb66fb1c47c4ec5d4)

8 years agoMerge "Make MySQLi work with non-standard port" into REL1_22
jenkins-bot [Tue, 25 Mar 2014 15:54:30 +0000 (25 15:54 +0000)]
Merge "Make MySQLi work with non-standard port" into REL1_22

8 years agoAdd link to PD help translatable pages from sidebar
Federico Leva [Sat, 7 Sep 2013 08:09:56 +0000 (7 10:09 +0200)]
Add link to PD help translatable pages from sidebar

Reuses the existing helppage default message and
adds it to ignored messages as Special:MyLanguage
is used and translations have to be removed:
this does not bother customised local links.

Now using HTTPS URL to mediawiki.org per Brion
on bug 54835. This slightly increases the footprint
of the change but should keep everything functionally
equivalent. The sidebar is not bothered by full URLs,
except in self-defeating tests which are also fixed here.

Bug: 53887
Change-Id: I999b97729536dbab4a3a5efd8d6f86527f031948

8 years agomediawiki.js: Fix documentation breakage
Timo Tijhof [Tue, 29 Oct 2013 00:30:29 +0000 (29 01:30 +0100)]
mediawiki.js: Fix documentation breakage

* Unformatted code and unclosed <media> tag.
  Depending on which versions of other libs are installed, this
  error can occur. Current version (v4.x) in production doesn't
  require this yet. But local environment with the same version
  does. And the next version of jsduck (v5.x) will consistently
  work this way for compliance with Markdown.

* Simplified @link while at it to use the cleaner implied link
  instead like we do elsewhere ({@link} should rarely be
  used directly).

* Add /** @class */ because half the file was no longer indexed
  as part of mw (instead became part of mw.Message after 4f23099)

* Index the private mw#log as log_ instead because it clashes
  with the public mw#log. This should've clashed in 4f23099, but
  didn't because the other one was seen as part of mw.Message
  by the test.

Change-Id: Ic5b8c5c743ecdb1509652c3655d83e501f6fa9ee
(cherry picked from commit 176e3e44a01dc5d5b020f276649123d743458d8f)

8 years agoSet a title for the context during import on the cli
Mark A. Hershberger [Mon, 10 Mar 2014 02:17:01 +0000 (9 22:17 -0400)]
Set a title for the context during import on the cli

Bug: 62467
Change-Id: I9e0b6a219ea4176f9a3d14b8dbbea08b36c76c59
(cherry picked from commit 2bae4c1cf44473f00283cc09ef8dff38d2aa4241)

8 years agoMake MySQLi work with non-standard port
mglaser [Thu, 20 Mar 2014 10:31:20 +0000 (20 11:31 +0100)]
Make MySQLi work with non-standard port

Other than mysql_connect, mysqli_real_connect expects an explicit
port parameter. So we need to parse the port out of $realServer. Note it
is not possible to just use $wgDBport, since that is set to 5432 as a
default and would break all existing sites using mysqli on standard port.

This change is IPv6 safe.

Bug: 58153
Change-Id: I58e690ef2803e205f324a142fbcbd96cc87510f1

8 years agoLink to existing login help page by default from helplogin-url
Federico Leva [Sat, 7 Sep 2013 07:38:06 +0000 (7 09:38 +0200)]
Link to existing login help page by default from helplogin-url

Detailed rationale discussed on bugzilla, bug 53888 and parent,
where consensus on the design was gained.

Using https link per Brion et al. in comments and bug 54835,
with new keys for the messages in order to avoid any conflict
with existing messages. (The translations of the removed messages
will be automatically removed by localisation updates.)

https://www.mediawiki.org/wiki/Help:Logging_in was improved by Lloffiwr
and now also marked for translation. The link is ready for future
translations thanks to the use of the standard Special:MyLanguage, hence
the message is made ignored to allow customisations only locally.

Bug: 53888
Change-Id: I8cefafbcd3bd1d6a03cec7cf1d0efdf607fec21d

8 years ago1.22.4 release notes and version update1.22.4
Mark A. Hershberger [Tue, 11 Mar 2014 14:53:48 +0000 (11 10:53 -0400)]
1.22.4 release notes and version update

Change-Id: Ib9ef58a076902307be94ea34ff74049b95452fc2

8 years agoUpdated release notes1.22.3
mglaser [Thu, 27 Feb 2014 23:25:14 +0000 (28 00:25 +0100)]
Updated release notes

Release notes are now readable without the context of the according bugs

Change-Id: I21dc8c11de264cb461d78f5c09932290df1f5d80

8 years agoUpdated Release Notes and version number for 1.22.3
mglaser [Thu, 27 Feb 2014 21:37:42 +0000 (27 22:37 +0100)]
Updated Release Notes and version number for 1.22.3

This is the MW1.22.3 maintenance release

Change-Id: I9f400338f7f450b097a13fd9932e2b2ec17b5ffb

8 years agoMerge "SECURITY: Disallow non-whitelisted namespaces" into REL1_22
jenkins-bot [Thu, 27 Feb 2014 21:09:08 +0000 (27 21:09 +0000)]
Merge "SECURITY: Disallow non-whitelisted namespaces" into REL1_22

8 years agoMerge "SECURITY: Make token comparison constant time" into REL1_22
jenkins-bot [Thu, 27 Feb 2014 21:07:32 +0000 (27 21:07 +0000)]
Merge "SECURITY: Make token comparison constant time" into REL1_22

8 years agoSECURITY: Disallow non-whitelisted namespaces
csteipp [Thu, 27 Feb 2014 15:18:04 +0000 (27 16:18 +0100)]
SECURITY: Disallow non-whitelisted namespaces

Disallow uploading non-whitelisted namespaces. Also disallow iframe
elements.

User will get an error including the namespace name if they use a non-
whitelisted namespace.

Bug: 60771
Change-Id: Id5c022543184b19b77ad32d9a8a0c2dbbc5e9038

8 years agoSECURITY: API: Don't find links in the middle of api.php links
Brad Jorsch [Fri, 14 Feb 2014 21:48:53 +0000 (14 16:48 -0500)]
SECURITY: API: Don't find links in the middle of api.php links

Bug: 61362
Change-Id: Idf985e4e69c2f11778a8a90503914678441cb3fb
(cherry picked from commit 55cd620157d884af855459f1f7903b0427c992ce)

8 years agoSECURITY: Make token comparison constant time
csteipp [Fri, 14 Feb 2014 01:18:40 +0000 (13 17:18 -0800)]
SECURITY: Make token comparison constant time

It seems like our token comparison would be vulnerable to timing
attacks. This will take constant time.

Bug: 61346
Change-Id: I2a9e89120f7092015495e638c6fa9f67adc9b84f
(cherry picked from commit 74ce391e9c115320e74c06772ee4fcb610ae33c4)

8 years agoAdd sequence support for upsert in DatabaseOracle
umherirrender [Tue, 4 Feb 2014 18:35:10 +0000 (4 19:35 +0100)]
Add sequence support for upsert in DatabaseOracle

In the same way as in selectInsert

Bug: 53710
Change-Id: I26f891da808ecdc932e29eebda71df4c17a29617
(cherry picked from commit 3d0f393ced80206053e18f893a17fbb81be14c8d)

8 years agoMerge "Add error handling if descriptionmsg isn't defined for extension." into REL1_22
jenkins-bot [Wed, 5 Feb 2014 17:37:57 +0000 (5 17:37 +0000)]
Merge "Add error handling if descriptionmsg isn't defined for extension." into REL1_22

8 years agoMerge "Correct sequence name for fresh Postgres installation" into REL1_22
jenkins-bot [Wed, 5 Feb 2014 17:35:04 +0000 (5 17:35 +0000)]
Merge "Correct sequence name for fresh Postgres installation" into REL1_22

8 years agoVarious fixes to job running code in Wiki.php
Aaron Schulz [Tue, 21 Jan 2014 19:32:18 +0000 (21 11:32 -0800)]
Various fixes to job running code in Wiki.php

* Make it async on Windows
* Fixed possible "invalid filename" errors on Windows
* Redirect output to dev/null to avoid hanging PHP

bug: 60231
bug: 58719
Change-Id: If4e52b86fb3a1bff283dfba3dfac213367f47543
(cherry picked from commit 96b678e110f90237d66eb095fa6cf223524d7ff4)

8 years agoCorrect sequence name for fresh Postgres installation
umherirrender [Mon, 27 Jan 2014 19:38:59 +0000 (27 20:38 +0100)]
Correct sequence name for fresh Postgres installation

Spotted by gebhkla on bug 60083

Bug: 60083
Change-Id: I34283c2539f4ce9d1b85756b3e1c16d255000ed5
(cherry picked from commit 305622fbc95a50fdb83cb9a4dda8c27f61710ede)

8 years agoAvoid variable naming conflicts in DatabasePostgres::selectSQLText
umherirrender [Tue, 28 Jan 2014 16:52:57 +0000 (28 17:52 +0100)]
Avoid variable naming conflicts in DatabasePostgres::selectSQLText

Spotted by gebhkla on bug 60531

Bug: 60531
Change-Id: Iaf100ea0db05b142549bd98da108e48eae8b9101

8 years agoFix rebuildall.php fatal error with PostgreSQL
lethosor [Sun, 26 Jan 2014 16:49:16 +0000 (26 11:49 -0500)]
Fix rebuildall.php fatal error with PostgreSQL

The fix for 47055 introduced a fatal error when running rebuildall.php. This
is a workaround suggested by gebhkla on Bugzilla (idle for 10+ days). It just
checks to make sure $options is actually an array before calling array_search
on it.

Bug: 60094
Change-Id: Ib54420b5a749c60b82a4757a9f5fa511f48fdb72
(cherry picked from commit afb297d175963d19735735c0283396a6cdcdf35a)

8 years agoAdd error handling if descriptionmsg isn't defined for extension.
Brian Wolff [Fri, 31 Jan 2014 01:29:21 +0000 (30 21:29 -0400)]
Add error handling if descriptionmsg isn't defined for extension.

Warning, Untested. Nobody likes fatals in the installer.
See bug 43817 comment 12.

Change-Id: I51453c38e59a635e8f0ad69e84daf2589750742f
Bug: 43817

8 years agoSpecial:PrefixIndex omits stripprefix=1 for "Next page" link
se4598 [Wed, 29 Jan 2014 22:32:56 +0000 (29 23:32 +0100)]
Special:PrefixIndex omits stripprefix=1 for "Next page" link

backport from I05c26db132d0f7edadb82a798fdba37277a3eddb

Bug: 60543
Change-Id: I92348b66e95e51fa5cff97cd316012d6a9cf5a86

8 years agoUpdate Release Notes and Version number1.22.2
csteipp [Mon, 27 Jan 2014 23:58:44 +0000 (27 15:58 -0800)]
Update Release Notes and Version number

Change-Id: If71074f25a73c6c078a11b9ef453c27d0125ab42

8 years agoSECURITY: Sanitize shell command args
csteipp [Mon, 27 Jan 2014 23:49:31 +0000 (27 15:49 -0800)]
SECURITY: Sanitize shell command args

Add validation and sanitization to several code paths.

Bug: 60339
Change-Id: Id124281d21ec730a2e0bbace843dd97194a712b4

8 years agoCheck for very old PCRE versions in installer and updater
Kevin Israel [Mon, 16 Dec 2013 16:02:51 +0000 (16 11:02 -0500)]
Check for very old PCRE versions in installer and updater

RE_IPV6_ADD uses (?(-n)) ("relative reference condition"), and CSSMin uses
\K ("reset start of match"), which only work in PCRE 7.2 and later -- newer
versions than the PCRE 6.6 included with Red Hat Enterprise Linux 5 and its
derivatives (e.g. CentOS 5).

Because the WMF developers, in general, do not seem to support maintaining
compatibility with such old software versions, I have opted to add a check
to the MediaWiki installer for these versions of PCRE. Affected users are
directed to a MediaWiki.org page advising the use of a different PHP package
that uses the bundled PCRE version instead of the older system version.

For now, the minimum PCRE version is set to 7.2, the oldest version not
known to break MediaWiki core. Once PHP 5.3 support is dropped, we may be
able to require PCRE 8.12 (bundled with PHP 5.4.0) or later.

The existing check for mere existence of the PCRE functions is removed;
since PHP 5.3, it is impossible to compile PHP without PCRE support.

Bug: 58213
Change-Id: Icf3732b6f84eeb25990178ae8fe3bd0fe4cc833f
(cherry picked from commit b215d91224f711e263126ae3b8546e022f33ef00)

8 years agoMake WikiPage::$mPreparedEdit public
Reedy [Tue, 7 Jan 2014 22:59:17 +0000 (7 22:59 +0000)]
Make WikiPage::$mPreparedEdit public

Partial revert of I2c34baaf8b64b204444efa1bfa6ea356e0124c54

Bug: 60054

Change-Id: Id4e90c612941ff2bdb50d7a68f4e18b004c9f744
(cherry picked from commit 09f84556bd33d2eeca29cf0d01b641030f50fb8a)

8 years agoUpdate Release Notes1.22.1
csteipp [Tue, 14 Jan 2014 04:58:28 +0000 (13 20:58 -0800)]
Update Release Notes

Change-Id: Icc4757e167bce1c466ba3f39be65b5d2eba4482b

8 years agoMerge "rel notes" into REL1_22
jenkins-bot [Tue, 14 Jan 2014 04:46:00 +0000 (14 04:46 +0000)]
Merge "rel notes" into REL1_22

8 years agorel notes
Mark A. Hershberger [Tue, 14 Jan 2014 00:05:30 +0000 (13 19:05 -0500)]
rel notes

Change-Id: I5a6f61503b4a2d86518fd2853bbb8b045afd66b3

8 years agoSECURITY: Return error on invalid XML for SVGs
csteipp [Tue, 14 Jan 2014 04:23:53 +0000 (13 20:23 -0800)]
SECURITY: Return error on invalid XML for SVGs

Return an error from UploadBase::detectScriptInSvg when the svg has
XML that cannot be parsed. Usually the XML is invalid, or the parser has
run out of memory trying to parse the file.

This patch is rebased on top of bug 57550.

Bug: 58553
Change-Id: Ib5f6e975431e338c662a748fdd5e9847b25aa50f

8 years agoSECURITY: Don't normalize U+FF3C to \
mglaser [Mon, 6 Jan 2014 23:38:24 +0000 (7 00:38 +0100)]
SECURITY: Don't normalize U+FF3C to \

Bug: 58088
Change-Id: If2494d2beca3fff8e3b855a95dee9b35bfda4b03

8 years agoMerge "SECURITY: Improve css javascript detection" into REL1_22
MarkAHershberger [Tue, 14 Jan 2014 01:52:27 +0000 (14 01:52 +0000)]
Merge "SECURITY: Improve css javascript detection" into REL1_22

8 years agoSECURITY: Don't cache when a call could autocreate
csteipp [Thu, 14 Nov 2013 22:36:24 +0000 (14 14:36 -0800)]
SECURITY: Don't cache when a call could autocreate

Fixes for action=raw (used when sites include other site's javascript),
and stashed images.

Bug: 53032
Change-Id: I8f915f6a4756f750c74d9ee9bec58f7ba6c0c827
(cherry picked from commit 636c64482dc740e05b3a114927655a62acd1eca6)

8 years agoSECURITY: Improve css javascript detection
csteipp [Tue, 8 Oct 2013 23:16:17 +0000 (8 16:16 -0700)]
SECURITY: Improve css javascript detection

* Forbid vertical tabs
* Convert Fullwidth, sup/sub script, IPA, and repetition unicode to
ascii, for ie6

Bug: 55332
Change-Id: I41a71b5b8fbecadd0f958cf57cc90d4c2fd9366e
(cherry picked from commit feb23b469f98772d8ae0d054d0dba8883d677f05)

8 years agoMerge "SECURITY: Fix RevDel log entry information leaks" into REL1_22
MarkAHershberger [Tue, 14 Jan 2014 01:22:56 +0000 (14 01:22 +0000)]
Merge "SECURITY: Fix RevDel log entry information leaks" into REL1_22

8 years agoMerge "SECURITY: Disallow -o-link in styles" into REL1_22
jenkins-bot [Tue, 14 Jan 2014 01:22:52 +0000 (14 01:22 +0000)]
Merge "SECURITY: Disallow -o-link in styles" into REL1_22

8 years agoSECURITY: Disallow stylesheets in svg
mglaser [Wed, 8 Jan 2014 22:39:52 +0000 (8 23:39 +0100)]
SECURITY: Disallow stylesheets in svg

Bug: 57550
Change-Id: I73d148519c077e628d82a89280faa088bac9bdf5

8 years agoSECURITY: Fix RevDel log entry information leaks
mglaser [Wed, 8 Jan 2014 12:01:30 +0000 (8 13:01 +0100)]
SECURITY: Fix RevDel log entry information leaks

DELETED_ACTION is supposed to hide the target of the log entry. But a
few places weren't doing this properly.

This fixes:
* API list=logevents no longer returns the pageid when the target is
  hidden.
* Enhanced RecentChanges no longer includes the log target page in the
  CSS class. This should also make the CSS class actually useful.
* Watchlist no longer shows log entries with DELETED_ACTION unless the
  user has deletedhistory, and with SUPPRESSED_ACTION unless the user
  has suppressrevision.

Bug: 58699
Change-Id: I5f03d38e46db3eb3decc9aee6a9de252f9a3de76

8 years agoSECURITY: Disallow -o-link in styles
mglaser [Wed, 8 Jan 2014 12:14:37 +0000 (8 13:14 +0100)]
SECURITY: Disallow -o-link in styles

Opera will execute javascript from -o-link css attributes.

Bug: 58472
Change-Id: I0b9eb66159c4bd8e767af52726309de478ec3962

8 years agobump version number
Mark A. Hershberger [Tue, 14 Jan 2014 00:30:35 +0000 (13 19:30 -0500)]
bump version number

Change-Id: I52e87ac50e0bae8547fa7050cb7a35f0f3635a20

8 years agoAvoid extra parsing in prepareContentForEdit()
Aaron Schulz [Thu, 14 Nov 2013 20:26:00 +0000 (14 12:26 -0800)]
Avoid extra parsing in prepareContentForEdit()

* WikiPage::clear() no longer resets mPreparedEdit
* Also actually made mPreparedEdit protected

bug: 57026
Change-Id: I2c34baaf8b64b204444efa1bfa6ea356e0124c54
(cherry picked from commit a87989717086b114e0acf3353160063de1914114)

8 years agoAdd function to clear mPreparedEdit, to use in cases of mutable content
aude [Sun, 17 Nov 2013 09:32:15 +0000 (17 10:32 +0100)]
Add function to clear mPreparedEdit, to use in cases of mutable content

In Wikibase, EntityContent is mutable and needs to clear
prepared edit before performing a save.

Follow-up to I2c34baa

Change-Id: I770bf2dc960c0a67a9b8315b7cdf24f3b89b6480
(cherry picked from commit 8842bc95fc06c8114e50574cdae33ac8fbf5d6a0)

8 years agoMerge "Fixed fatal error when getLocalCopy() fails" into REL1_22
jenkins-bot [Mon, 13 Jan 2014 23:24:37 +0000 (13 23:24 +0000)]
Merge "Fixed fatal error when getLocalCopy() fails" into REL1_22

8 years agoInclude short descriptions for extensions bundled in the release
Mark A. Hershberger [Mon, 13 Jan 2014 01:24:45 +0000 (12 20:24 -0500)]
Include short descriptions for extensions bundled in the release

Also fix styling for the list of extensions.

Bug: 43817
Change-Id: I5335225683ec8f1c163bb67f478787ebc52ee3b0
(cherry picked from commit e04a30f287a0a9efb2737a465077e7a5cc74e746)

8 years agoCouple of updates for RELEASE-NOTES
Mark A. Hershberger [Mon, 13 Jan 2014 23:09:29 +0000 (13 18:09 -0500)]
Couple of updates for RELEASE-NOTES

Change-Id: I26dd1652e976276d603e5f33ea296c62764fd6f3

8 years agoMake MagicWordArray compatible with PCRE 8.34+
Kevin Israel [Sun, 22 Dec 2013 06:24:07 +0000 (22 01:24 -0500)]
Make MagicWordArray compatible with PCRE 8.34+

In PCRE 8.34, a subpattern's name must not start with a digit; work around
this by replacing digits in the synonym's index with letters. Amazingly,
this part of the name seems to have the sole purpose of ensuring uniqueness;
none of the matching functions actually use it for anything.

Adding a single-letter prefix was considered, though it would risk breaking
extension code that may have used 29- or 30- character magic word IDs.
(PCRE limits subpattern names to 32 characters.) Likewise, moving the magic
word's ID to the front would not work if it were to start with a digit.

Bug: 58640
Change-Id: Ic69f9000addbf18c4747105187e6f13191828fbb

8 years agoRevert "Include short descriptions for extensions bundled in the release"
MarkAHershberger [Mon, 13 Jan 2014 20:06:40 +0000 (13 20:06 +0000)]
Revert "Include short descriptions for extensions bundled in the release"

This reverts commit 2e1852ad6c54808bdd9b14000e7f1438ec1856c7.

Change-Id: I721b694d45ecba7918cc7b53a33868867ea12e9f

8 years agoMerge "Changed FOR UPDATE handling in Postgresql" into REL1_22
jenkins-bot [Mon, 13 Jan 2014 03:17:07 +0000 (13 03:17 +0000)]
Merge "Changed FOR UPDATE handling in Postgresql" into REL1_22

8 years agoChanged FOR UPDATE handling in Postgresql
Tyler Anthony Romeo [Thu, 20 Jun 2013 19:20:37 +0000 (20 19:20 +0000)]
Changed FOR UPDATE handling in Postgresql

Postgresql cannot handle FOR UPDATE with outer joins, but it allows
specifying which tables can be locked. This changes DatabasePostgresql
to render proper FOR UPDATE statements that only include the main
table and any tables in inner joins.

Bug: 47055
Change-Id: I1ac587ac39f448b9e7f4befb44826b43044ad6f0
(cherry picked from commit 63d32eeb6f23b68ed783d6f6b5c6b39067b6316b)

8 years agoAdd sequence support for externallinks table
umherirrender [Fri, 3 Jan 2014 19:36:20 +0000 (3 20:36 +0100)]
Add sequence support for externallinks table

Database field el_id was added with
Ib6b0fc3736d173fa4ba7b786ecfc710b2f4711bb, but due to autoincrement in
mysql no sequence support was added.

For mysql this is a nop, it adds a field to the insert but that is null
and mysql autoincrement will fill it.
INSERT /* LinksUpdate::incrTableUpdate 127.0.0.1 */ IGNORE
  INTO `externallinks` (el_id,el_from,el_to,el_index)
VALUES
(NULL,'1610','http://de.wikipedia.org/wiki/Hauptseite','http://org.wikipedia.de./wiki/Hauptseite')

At least Oracle will need it

Bug: 58435
Change-Id: I3f68ea8d99c5450c0c66feeb1469ef0ee6cc4eab

8 years agomake release notes ordering more consistant
Mark A. Hershberger [Sun, 12 Jan 2014 03:45:26 +0000 (11 22:45 -0500)]
make release notes ordering more consistant

Change-Id: Ia48e44a33f5317f2435d65c5021714a9c0dc5806

8 years agoFixed fatal error when getLocalCopy() fails
Aaron Schulz [Wed, 20 Nov 2013 21:37:16 +0000 (20 13:37 -0800)]
Fixed fatal error when getLocalCopy() fails

bug: 40166
Change-Id: Ibfcddc1a9c05fad4ac0b51a5a046d1ffaeb49db8
(cherry picked from commit 6c5104111cb2545b04f16fcb4a7efe419344b44e)

8 years agoMerge "DatabaseInstaller::setVarsFromRequest needs array" into REL1_22
jenkins-bot [Sun, 12 Jan 2014 02:58:33 +0000 (12 02:58 +0000)]
Merge "DatabaseInstaller::setVarsFromRequest needs array" into REL1_22

8 years agoWebInstaller: Don't call getSoftwareLink()
Mark A. Hershberger [Thu, 9 Jan 2014 01:50:21 +0000 (8 20:50 -0500)]
WebInstaller: Don't call getSoftwareLink()

This gets the web installer working without the mysql or mysqli
PHP extension, which is not needed for other database systems.

* Avoid "lego" construction: put link text directly in the messages,
  which because the messages are parsed as wikitext, is easy to do.
* Put URLs in separate, ignored messages to avoid duplication in
  Database*::getSoftwareLink().
* Because I had to touch a MySQL-related i18n message, I figured
  this would be a good time to address bug 28281 (regarding MySQL
  forks and Special:Version).
* Other miscellaneous message changes, such as recommending the
  mysqli PHP extension over the old, deprecated mysql extension.

Bug: 28281
Bug: 58167
Manually cherry picked from Change-Id: I6dbc9d32c8c2d8f233a67d574229b80444885aea

Change-Id: I6296a106ffaf5f24fca29eacadc7721d9b83340c

8 years agoMore RELEASE-NOTES-1.22 improvments
Mark A. Hershberger [Sat, 11 Jan 2014 21:32:55 +0000 (11 16:32 -0500)]
More RELEASE-NOTES-1.22 improvments

Added note about curl, moved section about 1.22.1 ahead of 1.22.0

Change-Id: I70970c03dbcfcb567881a007cda3e739be89d5dd

8 years agoDatabaseInstaller::setVarsFromRequest needs array
umherirrender [Tue, 7 Jan 2014 18:54:27 +0000 (7 19:54 +0100)]
DatabaseInstaller::setVarsFromRequest needs array

Method is not marked as var args.

Bug: 58434
Follow-Up: I920b0231db1b70b68c6c8907257c288a0e112668
Change-Id: Ief7f7c06e75efbe7ae1da13f5021a9062483f690
(cherry picked from commit 29c2ab3da0d561428f1fc969daadcac463e675b6)

8 years agoBackport the CLDR 24 changes from 1.23
Tim Starling [Wed, 11 Dec 2013 23:45:07 +0000 (12 10:45 +1100)]
Backport the CLDR 24 changes from 1.23

Bug: 56931
Change-Id: I24be55a4cef02a408c378791dcd42d3f2efb9d68

8 years agoCorrected memcached.txt in MediaWiki 1.22
tinajohnson.1234 [Tue, 17 Dec 2013 16:02:39 +0000 (17 21:32 +0530)]
Corrected memcached.txt in MediaWiki 1.22

The sentence, "The newer PECL module is not yet supported." is wrong.
It is changed to "The newer PECL module is supported.".

Bug: 47486
Change-Id: I3111f82843360c3fa57394a980272b62cea8148e

8 years agoThe Release Notes for Mediawiki 1.22 was updated.
tonythomas01 [Tue, 17 Dec 2013 16:03:22 +0000 (17 21:33 +0530)]
The Release Notes for Mediawiki 1.22 was updated.

Depends on change #102132
The line "MediaWiki 1.22 is a large release that contains many new features and bug fixes"
was inserted.

Bug: 58233
Change-Id: I7c5cc929826e4f5eb3b8974574aff34886a66738

8 years agoMerge "Corrected the MediaWiki 1.22 Release notes" into REL1_22
jenkins-bot [Tue, 17 Dec 2013 15:34:23 +0000 (17 15:34 +0000)]
Merge "Corrected the MediaWiki 1.22 Release notes" into REL1_22

8 years agoMerge "Fixes for plural handling" into REL1_22
MarkAHershberger [Tue, 17 Dec 2013 13:50:12 +0000 (17 13:50 +0000)]
Merge "Fixes for plural handling" into REL1_22

8 years agoUpdate .gitreview for REL1_22 branch
Bartosz Dziewoński [Tue, 17 Dec 2013 13:25:32 +0000 (17 14:25 +0100)]
Update .gitreview for REL1_22 branch

Change-Id: I837bf55af31fc2a5b1d021213098664486f51280

8 years agoCorrected the MediaWiki 1.22 Release notes
tonythomas01 [Tue, 17 Dec 2013 13:04:53 +0000 (17 18:34 +0530)]
Corrected the MediaWiki 1.22 Release notes

The MediaWiki 1.22 Release notes say "THIS IS NOT A RELEASE YET", which was corrected.
The stable release version is 1.22.0, not 1.22.

Bug: 58233
Change-Id: I20e2754912b9fd76a4c57e980d5166545229c417

8 years agoFixes for plural handling
Pavel Selitskas [Tue, 3 Dec 2013 08:37:14 +0000 (3 14:07 +0530)]
Fixes for plural handling

* A new protected method looks for explicitly defined forms. Every
  overriden language class is required to use this method.
* Make explicit plural forms work for Russian. Russian has overridden
  convertPlural method, that was not taking care of explicit plural
  forms.
* Plural rules were updated to CLDR 24 for Manx (gv).

Bug: 46422
Bug: 47099
Bug: 54514
Change-Id: I46ab3dadc7fe08c1e60bbd81a1ee841e166e9608

8 years agoRestore compatibility with curl < 7.16.2
Kevin Israel [Mon, 9 Dec 2013 16:29:28 +0000 (9 11:29 -0500)]
Restore compatibility with curl < 7.16.2

Follows-up 58f71c7e9eca, which assumed that the CURLOPT_CONNECTTIMEOUT_MS
constant was defined.

Bug: 58178
Change-Id: Id31a3ec56e4c7cac7d3edb2653c87be467d1a471
(cherry picked from commit 33bc02fad1b73a06e402ea0d19d951b60ca30256)

8 years agoRaised version number to 1.22.0 (stable)1.22.0
mglaser [Fri, 6 Dec 2013 21:32:48 +0000 (6 22:32 +0100)]
Raised version number to 1.22.0 (stable)

This is the MediaWiki 1.22.0 stable release

Change-Id: I0f265b2f996021e4e11321bbb32cd785e6c86038

8 years agoMerge "Sync RELEASE-NOTES-1.22 between master and REL1_22" into REL1_22
jenkins-bot [Fri, 6 Dec 2013 20:48:38 +0000 (6 20:48 +0000)]
Merge "Sync RELEASE-NOTES-1.22 between master and REL1_22" into REL1_22

8 years agoRestore Signupstart and Signupend messages for account creation
Mark A. Hershberger [Sat, 23 Nov 2013 05:32:59 +0000 (23 00:32 -0500)]
Restore Signupstart and Signupend messages for account creation

This was removed during the redesign of the login process in
I50f25583, but I found that 5-10% of non-wmf wiki sites used this
message to display notices, previously.  We should keep this around or
at the very least provide advance notice for people.

Bug: 56455
Change-Id: I79423c1a05f0359c902d1940c3ffcd5e509dcf97
(cherry picked from commit 8cfedc494ab6dcdfd0c0ac8202b1685b2ab9581f)

8 years agoSync RELEASE-NOTES-1.22 between master and REL1_22
Alexandre Emsenhuber [Fri, 22 Nov 2013 20:47:43 +0000 (22 21:47 +0100)]
Sync RELEASE-NOTES-1.22 between master and REL1_22

Part II: REL1_22

Change-Id: I9bdf2f15be248c5d24aa67d10d063658fde38d51

8 years agobump version
Mark A. Hershberger [Fri, 22 Nov 2013 20:18:36 +0000 (22 15:18 -0500)]
bump version

Change-Id: I0e843378d679b9528b327e6d5cc3f1832fe7e727

8 years agoFix login with temporary password with $wgSecureLogin = true1.22.0rc-FINAL
Alexandre Emsenhuber [Fri, 22 Nov 2013 09:32:18 +0000 (22 10:32 +0100)]
Fix login with temporary password with $wgSecureLogin = true

The problem is that FauxRequest sets the protocol to http by default,
thus triggering the redirect when executing Special:UserLogin in the
background to log the user in after having reset his password.

DerivativeRequest is now used instead of FauxRequest so that the
protocol is correctly forwarded, and the redirect will not be
triggered.

Bug: 57289
Change-Id: I252351ff7d446283c9d1ab5f79b5cdbce71b76e0
(cherry picked from commit bb2ad0e816ce8ba579960148c2300f37510a1651)

8 years agoLocalisation updates from https://translatewiki.net.
Siebrand Mazeland [Thu, 21 Nov 2013 09:48:08 +0000 (21 10:48 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Ie9a137065158aef78700c4be029367d12521bc49

8 years agoAdd ar_id and el_id sequences for PostgreSQL
saper [Mon, 28 Oct 2013 22:08:52 +0000 (28 23:08 +0100)]
Add ar_id and el_id sequences for PostgreSQL

PostgreSQL needs sequences created before nextval
is used as the default value, populating newly
created fields.

Followup to: Ib6b0fc3736d173fa4ba7b786ecfc710b2f4711bb

Bug: 56185
Change-Id: Ia21d5bddead257a33a13e3ff2ec508041843613b
(cherry picked from commit a52b64ea714ca239034ec06c35d15c016121b226)

8 years agoRC21.22.0rc2
Mark A. Hershberger [Fri, 15 Nov 2013 03:36:17 +0000 (14 22:36 -0500)]
RC2

Change-Id: I5887dcf0d634c6cd827694caab68db74e3e1dd9a

8 years agoRename mw.util.wikiGetlink to getUrl
Bartosz Dziewoński [Fri, 18 Oct 2013 17:02:59 +0000 (18 19:02 +0200)]
Rename mw.util.wikiGetlink to getUrl

Old name still works, but is deprecated.

The new one has the nice property of being the same as a function
defined on mw.Title which does the same thing.

Replaced all occurences throughout the codebase.

Bug: 55764
Change-Id: I8704a6620ece44d374e199c05464b8a553e12e74
(cherry picked from commit 35970fb460060cab9a3984030241987a86146f09)

8 years agomw.util.addPortletLink: Check length before access array index
umherirrender [Sun, 10 Nov 2013 17:09:35 +0000 (10 18:09 +0100)]
mw.util.addPortletLink: Check length before access array index

This avoids "TypeError: Cannot read property 'parentNode' of undefined",
when the given nextNode is a jQuery object without elements.

Adding a test for this case and for the case of unknown id, which
internally results in a empty jQuery object.

Bug: 56770
Change-Id: I56de9e6bc15449e294b538743baf0f0c1cc0abb1
(cherry picked from commit c5eae531868df4f37c6f4ce6ac2506adf7528bd0)

8 years agoInclude short descriptions for extensions bundled in the release
Mark A. Hershberger [Fri, 11 Oct 2013 21:13:40 +0000 (11 21:13 +0000)]
Include short descriptions for extensions bundled in the release

Also fix styling for the list of extensions.

Bug: 43817
Change-Id: I5335225683ec8f1c163bb67f478787ebc52ee3a9
(cherry picked from commit 0a8cc7436f213cd2890d89cf119e8d805c7c3725)

8 years agoChange interlanguage link title message key
Siebrand Mazeland [Tue, 12 Nov 2013 13:17:17 +0000 (12 14:17 +0100)]
Change interlanguage link title message key

The term or abbreviation "iwiki" doesn't exist and has no meaning in
MediaWiki.

Bug: 56129
Change-Id: I0796b897e9646c122a46de449aaabf4d7a867f00
(cherry picked from commit d5aac9f6e001dfe11f3b6e67bb7cb24dbbb224ff)

8 years agoDo not escape title attribute twice for tooltip-iwiki
umherirrender [Mon, 11 Nov 2013 20:34:22 +0000 (11 21:34 +0100)]
Do not escape title attribute twice for tooltip-iwiki

When building the html the title attribute gets already escaped,
so getting text is enough here.

Bug: 55847
Change-Id: I779d3df414b0dbdfab415129baa3e7209e4067d6
(cherry picked from commit 65bb689f66b7e3eaf6b14f6cedabd382731ea8fa)

8 years agoReady RC1
Mark A. Hershberger [Sat, 9 Nov 2013 02:33:38 +0000 (8 21:33 -0500)]
Ready RC1

* Rearrange release notes
* Bump version

Change-Id: Iaf209f596185a8168118395d4e9ca58ea3bdc180

8 years agoCorrect tooltip of "Next n results" on query special pages.
Alexandre Emsenhuber [Fri, 8 Nov 2013 17:45:42 +0000 (8 18:45 +0100)]
Correct tooltip of "Next n results" on query special pages.

Was showing "Previous n results".

Bug: 56707
Change-Id: I9f51d70f9e1fe3c314a1226950f1324ab22f4199

8 years agoFix call to function applyPatch in MysqlUpdater
umherirrender [Tue, 5 Nov 2013 18:58:13 +0000 (5 19:58 +0100)]
Fix call to function applyPatch in MysqlUpdater

Change-Id: Ieefc8968ae3d397482df939e5d1ccd15df0c4705
(cherry picked from commit 1db6a5925b65590421fa1a9ec30902195d51e264)

8 years agoMake it possible to install extensions using Composer
jeroendedauw [Thu, 31 Oct 2013 23:37:10 +0000 (1 00:37 +0100)]
Make it possible to install extensions using Composer

With this change it is possible for users to create a composer.json
file in which they list the extensions they want to have installed
and then install them via Composer. They can copy composer-example.json
to get started.

Before this change there was an actual composer.json file tracked by
git, so people would get a change tracked by git if they modified it.

Surprisingly this is all that is needed to get extension installation
to work, for the extensions that already support it. Kudos to hashar
and others that already did the other required work.

With this change core no longer pretends to be a component that is
installable via composer. This never worked, and core will need to
be modified in several ways before this can work. In other words,
no working functionality is lost, and quite a lot is gained.

Example usage:

* Copy composer-example.json to composer.json.
* Run "composer require diff/diff 0.9"
* Hit Special:Version and be happy

Change-Id: Ib125bea00cd29a800c22f260e87dfe3327a0b618
(cherry picked from commit d6e69d774d613e3097d7b1640540b62ec89d2685)

8 years agoMerge "FormatJson: Remove whitespace from empty arrays and objects" into REL1_22
MarkAHershberger [Fri, 8 Nov 2013 02:09:00 +0000 (8 02:09 +0000)]
Merge "FormatJson: Remove whitespace from empty arrays and objects" into REL1_22

8 years agoMerge changes I8a9b4831,I3d570a63 into REL1_22
jenkins-bot [Fri, 8 Nov 2013 02:07:09 +0000 (8 02:07 +0000)]
Merge changes I8a9b4831,I3d570a63 into REL1_22

* changes:
  MWException: Cleanup exception message output
  redact exception traces and abstract getTrace

8 years agoMerge "UploadStash::removeFileNoAuth shouldn't need auth" into REL1_22
MarkAHershberger [Fri, 8 Nov 2013 02:05:45 +0000 (8 02:05 +0000)]
Merge "UploadStash::removeFileNoAuth shouldn't need auth" into REL1_22

8 years agoMerge "MySQL method to find out view + fix fatal in tests" into REL1_22
MarkAHershberger [Fri, 8 Nov 2013 01:58:54 +0000 (8 01:58 +0000)]
Merge "MySQL method to find out view + fix fatal in tests" into REL1_22

8 years agoMerge "wikibits: Add some missing deprecation messages" into REL1_22
jenkins-bot [Thu, 7 Nov 2013 22:39:33 +0000 (7 22:39 +0000)]
Merge "wikibits: Add some missing deprecation messages" into REL1_22

8 years agowikibits: Add some missing deprecation messages
Bartosz Dziewoński [Thu, 7 Nov 2013 22:06:15 +0000 (7 23:06 +0100)]
wikibits: Add some missing deprecation messages

Follow-up to Iab65de1a.

Change-Id: I8925f7dc34b295d6ae3704813e18a4b191f08819
(cherry picked from commit 47b6592f963b2e543f3b564c97d428f45f2c3d8b)

8 years agoMigrate usage of wikibits in legacy protect.js and upload.js
Timo Tijhof [Thu, 7 Nov 2013 17:35:24 +0000 (7 18:35 +0100)]
Migrate usage of wikibits in legacy protect.js and upload.js

Follows-up fcf4934a52.

protect:
* Use jQuery instead.
* Removing now-obsolete dependency.
* Make cell.appendChild more obvious and potentialy faster
  by grouping the dom actions in 1 sequence.

config:
* Removing obsolete dependency.

upload:
* Use jquery.spinner instead.
* Removing now-obsolete dependency.

jquery.spinner:
* While at it, updated documentation to be included in our
  jsduck index, similar to jquery.localize.

jsduck/external.js:
* Added @static to jQuery.ajax which was missing, it showed up
  between instance methods like jQuery#injectSpinner.

The only module left using mediawiki.legacy.wikibits is
mediawiki.legacy.ajax which remains in tact for now.

Bug: 56726
Change-Id: I712112626a99dc2d0090f554c56052770cd0ae88
(cherry picked from commit af4ef8153354b02ec910fd98ec7af024c64ab104)

8 years agoMySQL method to find out view + fix fatal in tests
AlephNull [Fri, 24 May 2013 15:14:40 +0000 (24 11:14 -0400)]
MySQL method to find out view + fix fatal in tests

We were missing a method to list out views defined in a database. This
patch adds in MysqlBase::isView() and MysqlBse::listViews().

Since listViews() cache its result in DatabaseBase::$allViews, we also
introduce a final DatabaseBase::clearViewsCache() to let us clear the
per process cache.

Finally, fixed fatal error when duplicating VIEWs in MySQL.

Conflicts:
RELEASE-NOTES-1.22

bug: 43571
Change-Id: I8650baa4b721fe69ea3e1d557dd76745c0c7754e
(cherry picked from commit e9d53667f43230e84302d0a6653ea7e78a7841ce)