Commit graph

128486 commits

Author SHA1 Message Date
Zvi "CtrlZvi" Effron
db82379f65 installer: fix MySQL create user permissions check
The previous check for the necessary permissions to create a user were
no longer correct. They did not check for the CREATE USER global
permission, which is also sufficient for user creation. Additionally,
they were checking for the ability to grant permissions by comparing
the IS_GRANTABLE column against a boolean true (integer 1). The column
is a varchar(3) that stores the string 'YES' to indicate the presence
of the permission, so the comparison against the integer boolean is
always false.

MySQL has had both the CREATE USER permission and the use of a
varchar(3) column for IS_GRANTABLE since at least MySQL 5.0, so they
are present for all supported versions of MySQL/MariaDB.

This was likely not a problem until 3f852f7ddc, at which point the
checks were added to the web installer flow.

Now, the CREATE USER permission is also accepted and IS_GRANTABLE is
compared against 'YES', so the web installer will be able to present
the option to create users if the database administrator account has
the correct permissions.

Bug: T391179
Change-Id: I5c2454599d6e91559d9996fe7c274eb8daab44bd
(cherry picked from commit daff6d03638f5c7108339f0a8774d2cfd9fbc0f0)
2025-04-18 03:02:04 +00:00
Lucas Werkmeister
c60a5c4206 SECURITY: Escape newpage message in FeedUtils
Bug: T386175
Change-Id: Ida72c4c03c379cf5a340b2f229f0fe842694559c
(cherry picked from commit 14205eb16d32439b745537906c1d37146b60793b)
2025-04-17 19:13:20 +00:00
Máté Szabó
145d205b4c specials: Fix PHP Warning on Special:PasswordReset for crafted input
Why:

- Special:PasswordReset uses raw POST values to add username and email
  info to success messages post-submit.
- These values may be parsed by PHP as arrays if a client supplied
  crafted input with multi-value fields.
- Instead of doing our own param validation in onSuccess(), we can reuse
  parsed values in onSubmit() and do the rendering there.

What:

- Move success message processing to onSubmit().

Bug: T392086
Change-Id: I9b0e115c417d0f3080e711441c79608d782932ce
(cherry picked from commit 37d63156c841f9a19080c9438cdf66cf58a7da7a)
2025-04-16 21:01:12 +00:00
Abijeet Patro
96f6631007 Merge "Localisation updates from https://translatewiki.net." into REL1_43 2025-04-16 06:58:53 +00:00
Translation updater bot
2b78ce9d78 Update git submodules
* Update skins/Vector from branch 'REL1_43'
  to 3b1380e2dc4128604d6853f47a300b1fb28c3bd5
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I4666b645d518eda566d0a7cd746d4ce109feb0d6
2025-04-15 06:29:58 +00:00
Translation updater bot
1cd779d92e Update git submodules
* Update skins/MinervaNeue from branch 'REL1_43'
  to c0a1ed22874285de977665e387f03e13097f39a2
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I565b964eb6daaf3115e575c33df255863fa4ad9e
2025-04-15 06:29:56 +00:00
Translation updater bot
8abfa41348 Update git submodules
* Update extensions/VisualEditor from branch 'REL1_43'
  to 25f48f8dfd7e3ffd3d74aa4ad756abdae3caa434
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I91aa63c29747d3141b27cc324a379278d7176271
2025-04-15 06:28:37 +00:00
Translation updater bot
5905af45ed Update git submodules
* Update extensions/WikiEditor from branch 'REL1_43'
  to c627ce9b01d8c0fdde15371a40c0211842b34d49
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I13742d4dff2a7682280faea6db5aecfb8b5580dd
2025-04-15 06:28:35 +00:00
Translation updater bot
43a4e78890 Update git submodules
* Update extensions/Scribunto from branch 'REL1_43'
  to 87916a34e0516c1dd1eaed4adf5b2d44603c7c3c
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I6f7ef6462c8fd4c499bf4ea0d9ee0f3b0c39e1d0
2025-04-15 06:28:31 +00:00
Translation updater bot
067f58e5b7 Update git submodules
* Update extensions/Thanks from branch 'REL1_43'
  to b9cc839a0a3f62dc3a13ab2c76c0ec1e45328551
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: If992ed5c7e31969970d26b378a1a373298b9d846
2025-04-15 06:28:18 +00:00
Translation updater bot
5a7bab1b05 Update git submodules
* Update extensions/LoginNotify from branch 'REL1_43'
  to 0fe872ed32d55852fccc8e1f1c28a6d2b6f4b6b5
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I39c299dd7667abc0685739f7c9908da25de9622c
2025-04-15 06:28:10 +00:00
Translation updater bot
ae18e4a738 Update git submodules
* Update extensions/Cite from branch 'REL1_43'
  to 67f62f9a65e3686e07574e3362f81bf494ed4d8f
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: Id680ec353b27ada02836f9c644d0bc080a791878
2025-04-15 06:28:09 +00:00
Translation updater bot
63e2cf8202 Update git submodules
* Update extensions/CategoryTree from branch 'REL1_43'
  to bd89d6d9a1ad59701baddc1099596e531c51eabe
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I1b007293048df70e9180ee6be84186ef0d0e9955
2025-04-15 06:28:06 +00:00
Translation updater bot
759517be80 Update git submodules
* Update extensions/Echo from branch 'REL1_43'
  to bab9504f6ebdda74f48b5926335d7240568f1d5a
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I931e7c0b15f638b0d3cdf53c297d46a4db18783b
2025-04-15 06:28:03 +00:00
Translation updater bot
4947419051 Update git submodules
* Update extensions/OATHAuth from branch 'REL1_43'
  to 72d8ec5feebd8a160199d5a5dfa6789f1dd99d74
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I0387c52c562ad664b034de994310e628c40435b1
2025-04-15 06:27:58 +00:00
Translation updater bot
49d6bbb4d4 Update git submodules
* Update extensions/Linter from branch 'REL1_43'
  to 8600393f64c095dbf1c344d5e555f524c9a797d5
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I39c299dd7667abc0685739f7c9908da25de9622c
2025-04-15 06:27:56 +00:00
Translation updater bot
581feeeb45 Update git submodules
* Update extensions/DiscussionTools from branch 'REL1_43'
  to 123e7732c17aba2969dc60ab982f20b2904707db
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I3bb30c250ba693be81f9da720bb42a8a3812e23c
2025-04-15 06:27:53 +00:00
Translation updater bot
624c6f5288 Update git submodules
* Update extensions/CiteThisPage from branch 'REL1_43'
  to 53d0e706a4863e9b1155b6e782936b89da9d7b17
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I034af01f283e5837a1de20c41cacabaab283ce9e
2025-04-15 06:27:49 +00:00
Translation updater bot
2b7647b850 Update git submodules
* Update extensions/Nuke from branch 'REL1_43'
  to 96798529616368805af951aee745ba5c2d12b7c1
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I7c29571fae1de16d186e922519d331323e7e59ad
2025-04-15 06:27:45 +00:00
Translation updater bot
107e26494f Update git submodules
* Update extensions/MultimediaViewer from branch 'REL1_43'
  to 94438020a3660a00d99a575a5d62494b3321ed43
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: If0aac57bee3e712f9b67c6cf617c75fed7d9a129
2025-04-15 06:27:44 +00:00
Translation updater bot
93725cfec4 Update git submodules
* Update extensions/Math from branch 'REL1_43'
  to 6e27f6acd4e255e7133467117bcdd7e7c585cb86
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I1aba04c29f56c32a8f6967033a634e6bbd23e7e5
2025-04-15 06:27:43 +00:00
Translation updater bot
024db2ff03 Update git submodules
* Update extensions/InputBox from branch 'REL1_43'
  to 10a4dd9588a1bc5e4f69497aa55dfd7621282ef1
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I28d9ff879dadedf97012ba73fa3dc50d5a0c3356
2025-04-15 06:27:40 +00:00
Translation updater bot
16ca08e900 Update git submodules
* Update extensions/ConfirmEdit from branch 'REL1_43'
  to cc9dc0cf90b9b38ab873fb42b004cc63ca8f4c7e
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I913b95ff735ec64a7d70d51e7eff146eef31c055
2025-04-15 06:27:34 +00:00
Translation updater bot
dcf8c6e470 Update git submodules
* Update extensions/AbuseFilter from branch 'REL1_43'
  to ef2dde18bd6d059b8dd312fe55ba9d9ace53b7ca
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I7cec52c07aeb74121b64c245f9d5e1fe3d1ae8d1
2025-04-15 06:26:56 +00:00
Translation updater bot
0f365d630b
Localisation updates from https://translatewiki.net.
Change-Id: I7757816ae8ab62edf8825b2055bbcab9e9b7c6f8
2025-04-15 07:32:55 +02:00
daniel
e3c2412ed0 swagger-ui: Add licenses of packages used by Swagger UI bundle
Why:
- Since we re-distribute a Swagger bundle that includes all the
  libraries, we should also supply the licenses associated with these
  libraries.
- See https://github.com/swagger-api/swagger-ui/issues/8317

What:
- Create a directory containing the relevant OSI licenses.
- Create a list of all the libraries included in Swagger UI
  and their respective licenses.

Bug: T382086
Change-Id: I30be1fee2b3ebd7352fa6255a95969e91a75d575
(cherry picked from commit ea8d04800ff074f15ab4c83b39db438bb26fa617)
2025-04-14 19:55:42 +00:00
Umherirrender
44ea90fa03 tests: Add test cases for UploadFromChunks
Change-Id: Iab7453ec19cf467894246ad1bd6d3f6e8baa1cfd
(cherry picked from commit 39e7e27b41cd8a181110b3d435a2c19395bfc0d5)
2025-04-13 10:43:22 +00:00
Bartosz Dziewoński
691767b387 UploadBase: makeWarningsSerializable() should accept MessageParam objects
Bug: T390001
Change-Id: Icc151fc2bf32df044d85bf8aa89e843b0c0bf25f
(cherry picked from commit 5e7a5f87183b4cbeee949dc1882db52ff281c72a)
2025-04-12 22:40:51 +00:00
jenkins-bot
0422213b8a Merge "filebackend: Avoid passing null to FileBackend::normalizeContainerPath" into REL1_43 2025-04-11 17:14:00 +00:00
xtex
71726683d8 Update git submodules
* Update extensions/OATHAuth from branch 'REL1_43'
  to 5ecf5c046d909136d5e6b0fae7956a701cbbed93
  - OATHManage: Fix missing placeholder in oathauth-switch-method-next-step
    
    Change-Id: I1396c0f195b1624b6fb7abf796dd6ec129d8717d
2025-04-11 14:05:51 +00:00
Umherirrender
69832205c4 filebackend: Avoid passing null to FileBackend::normalizeContainerPath
strtr(): Passing null to parameter #1 ($string) of type string is
deprecated in php8.1

Change-Id: I224d8e8baa9d878db3635cb6c46eb62eb6f60469
(cherry picked from commit 596589d9032b5e7a3f9b4ed7e0558b42cf66690b)
2025-04-10 21:54:42 +00:00
Pppery
65d32263fd Diffs: avoid getContentHandler on null error
Bug: T388708
Change-Id: I4dbbeb70a53c6ca0b3c44995d13e2c5de097ddf2
(cherry picked from commit 7aee965efdbe316f8ea13b1d03b4c1afab11d255)
2025-04-10 21:37:29 +00:00
Gergő Tisza
810a248988 Update git submodules
* Update extensions/OATHAuth from branch 'REL1_43'
  to b6cb1d5739c3ff3d165ae56d6131c85481deb5a1
  - Do not make Copy button the default submit action on TOTP form
    
    Bug: T354028
    Change-Id: I30d4bae47141e06aa6993c22836f7336ba758a14
2025-04-10 18:49:02 +00:00
Reedy
f2e8ddf41b Start 1.43.2
Change-Id: I360072dbca1772bf04ecfedf77bf8324bd42f1fa
2025-04-10 17:19:01 +00:00
Reedy
cde4276870 Prep 1.43.1
Change-Id: I3744e15fcaa6727d9984acaa9da3ee60fe1cd038
2025-04-10 17:18:51 +00:00
Dreamy Jazz
bfea732c5b Update git submodules
* Update extensions/AbuseFilter from branch 'REL1_43'
  to 6ebcd929c7f7a2f8be715dfe39c59b53570829f0
  - SECURITY: Use correct bitwise operator on CentralDBNotAvailableException
    
    Why:
    * When FilterLookup::getFilter throws a
      CentralDBNotAvailableException, the code which calls it
      sometimes catches the exception and then assumes the filter
      has the maximum privacy level.
    * This logic is broken as the wrong PHP bitwise operator is used
      ("&" instead of "|").
    
    What:
    * Update all uses of "&" to "|" in the affected places.
    
    Bug: T389235
    Change-Id: Idb08add69a55fb387ec51fb220cafc46542afd1a
2025-04-10 17:17:47 +00:00
Daimona Eaytoy
449e0ed49d SECURITY: escape section labels in HTMLMultiSelectField
CVE-2025-3469

Only use HtmlSnippet when the labels are not coming from a message, to
avoid XSS-via-i18n vulnerabilities.

Bug: T358689
Change-Id: If91500bc76b3ed8cdc58da4f9de326df6d201398
2025-04-10 15:56:06 +01:00
C. Scott Ananian
94f193a894 SECURITY: Ensure emitted HTML is safe against Unicode NFC normalization
CVE-2025-32699

Ensure that Unicode NFC normalization can be applied to our HTML
output safely.  Even though the W3C officially recommends against
normalizing HTML

https://www.w3.org/International/questions/qa-html-css-normalization#converting

this is still easily done inadvertently, especially when using the
MediaWiki action API which normalizes parameters and results by
default.

See also I671648603c4635a35585c860b4857f5ea085e47f in Parsoid, and
T266140 / I2e78e660ba1867744e34eda7d00ea527ec016b71 for another similar
issue.

The following changes are made:

* The various HTML serializers (Remex/Tidy-derived, as well as the
  Html::* helpers) are tweaked to entity-escape U+0338 wherever it
  appears.

* Similarly, Message::escaped() is tweaked to entity-escape U+0338.

* Finally, a post-processing pass is added to the OutputTransform
  pipeline to catch any remaining U+0338 and entity-escape them.
  This catches U+0338 added during any of the previous OutputTransform
  stages (like TOC insertion, section edit links, etc).
  *When backporting* this code will likely need to be moved to
  ParserOutput::getText(), as the OutputTransform pipeline wasn't added
  until MW 1.42.

Bug: T387130
Change-Id: I66564e14e730f5393f4fa5780b80f24de6075af5
2025-04-10 15:56:06 +01:00
Bartosz Dziewoński
8702751d5e SECURITY: Fix log entry search revealing suppressed data to users with 'deletedhistory' rights
CVE-2025-32698

Bug: T385958
Change-Id: Id0588baf6a1587d326b262d075d4e943dc5daacd
2025-04-10 15:56:06 +01:00
Reedy
4d9b508c04 tests: Rename invalid json files to txt
Same as was done in 5f2584b648

Bug: T391586
Follows-Up: I966cddb337c9373ed3a369496548a8d8c538ae84
Change-Id: I757eb043f8043d6620fb69bd072d9bb9e97ad163
(cherry picked from commit 7a84c34398639d3422f81ab9711539c34d435621)
2025-04-10 14:38:25 +00:00
Bartosz Dziewoński
3aab5f1f3d RestrictionStore: Remove short-circuit mode when fetching cascading sources
Almost every call to isCascadeProtected() (which uses short-circuit
mode) is followed by a call to getCascadeProtectionSources() (which
doesn't), so this attempted optimization (skipping a loop that does
some very cheap operations) actually results in worse performance
in the common case (because the result of the database query can't
be cached in short-circuit mode, and we must query it again), and
it makes the code really annoying to read or modify.

Relevant code: https://codesearch.wmcloud.org/search/?q=getCascadeProtectionSources\(|isCascadeProtected\(&excludeFiles=RestrictionStore.php|HISTORY|tests%2F

Change-Id: Ib9eb6cab28492776d40a10cbfb28e9c1cec8c1d2
(cherry picked from commit f9180c4a36fb8874fc0211f05a1eebaceb67aa0c)
2025-04-09 13:25:44 +00:00
Reedy
9c9440249f RELEASE-NOTES-1.43: Update
Change-Id: Iad6fb917ffa7d274268c0d22a9be0215c281ff2f
2025-04-09 12:46:31 +00:00
jenkins-bot
334b860bc7 Merge "block: Fix DBS::acquireTarget() race using GET_LOCK()" into REL1_43 2025-04-08 23:04:22 +00:00
Bartosz Dziewoński
0d5d80b7e1 LanguageConverter: Only set mTablesLoaded once they're really loaded
If something inside the callback above throws an exception (e.g.
`parseCachedTable()` when the database is down), and it is caught,
`$this->mTablesLoaded` and `$this->mTables` will be left in an
inconsistent state for the rest of the request, causing confusing
errors elsewhere.

Bug: T388807
Change-Id: I79704d6d5c03d5e028c0c762a37fd55b953a4a6a
(cherry picked from commit 6d4f287059521fd4e7fe094ccb00aca54906b31f)
2025-04-08 08:34:42 +00:00
Translation updater bot
b1d2516673 Update git submodules
* Update skins/Vector from branch 'REL1_43'
  to a4a127342e106a27d89253921cc771a978523a68
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I9189d564e985d3115d39dc29d2894421c0c491d4
2025-04-08 06:32:33 +00:00
Translation updater bot
9e555977c4 Update git submodules
* Update skins/MinervaNeue from branch 'REL1_43'
  to 9dfbada4fe1994e279828289a424ecbfdc8b754c
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I54de52119783721703597574d7f2f6289c2db456
2025-04-08 06:32:29 +00:00
Translation updater bot
455e31f96f Update git submodules
* Update extensions/VisualEditor from branch 'REL1_43'
  to b890dad267289a9ecec8c02c3e6fedc957948e9f
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: Ic7a4e06cc699ce46a339ffdbdb56f67e6be8a24c
2025-04-08 06:31:08 +00:00
Translation updater bot
234836ce4e Update git submodules
* Update extensions/TemplateData from branch 'REL1_43'
  to 514b72c1cd263c641d0fcf6eb6e564eec8b5f593
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I6379ffa6a64588002bb3c09704be965b326b5488
2025-04-08 06:31:07 +00:00
Translation updater bot
1f16ae2b3c Update git submodules
* Update extensions/TitleBlacklist from branch 'REL1_43'
  to 8e8ebe02588343ea0d0c44095c2765632194f241
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: Icb7281fa197293315391243f8784a1500b2e3999
2025-04-08 06:31:03 +00:00
Translation updater bot
b6e85e7436 Update git submodules
* Update extensions/WikiEditor from branch 'REL1_43'
  to 67f6158919d1d2e0de0a716c7cf4f7fbd240445a
  - Localisation updates from https://translatewiki.net.
    
    Change-Id: I1f4573b9768b025f17c6d20884fb75dc4fd91790
2025-04-08 06:30:47 +00:00