Skip to content

Commit b2b3d31

Browse files
committed
Merge branch 'wikimedia-REL1_45' into REL1_45
2 parents 80c0deb + 4a78c01 commit b2b3d31

533 files changed

Lines changed: 18020 additions & 7340 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

RELEASE-NOTES-1.45

Lines changed: 125 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,131 @@ PHP 8.3 workboard: https://phabricator.wikimedia.org/tag/php_8.3_support/
66
PHP 8.4 workboard: https://phabricator.wikimedia.org/tag/php_8.4_support/
77
PHP 8.5 workboard: https://phabricator.wikimedia.org/tag/php_8.5_support/
88

9+
== MediaWiki 1.45.4 ==
10+
11+
THIS IS NOT A RELEASE YET
12+
13+
=== Changes since 1.45.3 ===
14+
* Localisation updates.
15+
16+
== MediaWiki 1.45.3 ==
17+
18+
This is a maintenance release of the MediaWiki 1.45 branch.
19+
20+
=== Changes since 1.45.2 ===
21+
* Fixed backport issues.
22+
23+
== MediaWiki 1.45.2 ==
24+
25+
This is a security and maintenance release of the MediaWiki 1.45 branch.
26+
27+
=== Changes since 1.45.1 ===
28+
* Localisation updates.
29+
* (T386108) Upgrade pear/pear-core-minimal to v1.10.17.
30+
* (T412194) Upgrading justinrainbow/json-schema (5.3.0 => 5.3.1).
31+
* (T411213) Upgrade wikimedia/less.php from 5.2.2 to 5.5.0.
32+
* (T413538) MultiHttpClient: Remove curl_close() call.
33+
* (T413565) Search: Replace deprecated SplObjectStorage methods.
34+
* Mime: Change mime type video/x-matroska to video/matroska.
35+
* (T413625) LinksMigration: Correctly filter for equal namespaces.
36+
* (T413582) ShellboxClientFactory: Handle $service being null in getUrl().
37+
* (T413672) EtcdConfigTest: Add return value for some MultiHttpClient mocks.
38+
* (T413675) DBConnRefTest: Add a temporary variable for return value in
39+
testRoleExceptions.
40+
* (T413580) LanguageCodeTest: Remove unnecessary null assertion.
41+
* Allow wikimedia/testing-access-wrapper ^4.0.0.
42+
* Logging: Handle possible null as type for LogPage.
43+
* (T411019) Logging: Set default for log type on dropdown via LogEventsList.
44+
* (T413690) libs: Fix closure detection in MemoizedCallable.
45+
* (T413923) Don't use null offsets in BlockManager::getUniqueBlocks.
46+
* SiteConfiguration: Optimize processSetting for default-only case.
47+
* SiteConfiguration: Use \array_key_exists().
48+
* SiteConfiguration: Use use function syntax.
49+
* Config: Use use function array_key_exists some more.
50+
* (T413924, T413925) tests: PHP 8.5 compatibility in AuthManager tests.
51+
* (T413573) [php8.4] Use DOMCompat::innerHTML() instead of Element::nodeValue.
52+
* Update documentation from which versions you can upgrade.
53+
* (T413673) tests: Fix PHP8.5 error when casting float(INF) as integer.
54+
* (T414355) Fix PHP 8.5 deprecation warnings in IcuCollation.
55+
* (T414351) Avoid coercing NAN/INF/-INF to string.
56+
* (T404636) tests: Hide deprecation warning for PHPSessionHandler.
57+
* (T414323) tests: Use setAttributeForTest() correctly.
58+
* (T413674) ParamValidator: Suppress cast warning in IntegerDef.
59+
* (T413577) Parser: Ignore long user provided int in
60+
Sanitizer::decodeCharReferences.
61+
* (T413576) Rdbms: Get strings from SQLPlatform::getDatabaseAndTableIdentifier.
62+
* (T413579) Site: Handle non-stored Site objects in SiteList.
63+
* (T413920) tests: Mock some functions in OutputPageTest.
64+
* (T413926) Do not attempt to get handler for unknown file types.
65+
* (T413919) tests: Use real TitleFormatter in LinkBatchTest.
66+
* (T413930) User: Add fallback 'default' to User::getDatePreference.
67+
* (T413934) JobQueueGroup: avoid PHP 8.5 deprecation from null array offsets.
68+
* (T413922) Rdbms: Handle null from DatabaseDomain::getDatabase in
69+
LBFactoryMulti.
70+
* (T413901) Media: Remove deprecated imagedestroy.
71+
* rdbms::assertTransactionRoundStage: Show transaction name if available.
72+
* (T414350) Language: Handle NAN coercion to string in formatting numbers.
73+
* (T413931) tests: Set module name in ApiBaseTest::doGetParameterFromSettings.
74+
* (T414336) Disable process timeout for Composer phpunit script.
75+
* (T413575) libs>XhprofData: Handle use of NULLs as array keys for PHP8.5.
76+
* (T406744) tests: remove setAccessible() call on Reflection objects.
77+
* tests: Change DomDocument return type in SpecialCreateAccountTest.
78+
* (T415443) Upgrading mck89/peast (v1.16.3 => v1.17.4).
79+
* (T413918) tests: Mock value for RangeChronologicalPager::getTimestampField.
80+
* (T413921) LinksUpdate: Handle nullable el_to_path column in
81+
ExternalLinksUpdate.
82+
* (T413926) Upload: Do not attempt to get handler for unknown file types.
83+
* File: Ensure mime type is set for LocalFile::getMimeType.
84+
* (T413917) Specials: Use empty string as missing type on
85+
Special:RevisionDelete.
86+
* (T415723) Updated phpunit/phpunit from 9.6.21 to 9.6.33.
87+
* Update phpunit/phpunit from 9.6.33 to 9.6.34.
88+
* Update wikimedia/parsoid to 0.22.1.
89+
* (T414599) migrateLinksTable: Handle constant namespace values in mapping.
90+
* VueComponentParser: use Parsoid DOM compatibility methods.
91+
* FileRepo: Add 'userAgent' option in ForeignAPIRepo for wgForeignFileRepos.
92+
* [tests] Add forward-compatibility alias for JsonDeserializableSubClass.
93+
* (T367584) JsonCodec/ParserCache: Forward-compatibility test cases.
94+
* (T413545) Update wikimedia/parsoid to 0.22.2.
95+
* (T417390) mediawiki.util: Don't throw in addSubtitle if the skin lacks a
96+
subtitle.
97+
* (T414884) PostgresInstaller: Handle null password in openConnectionToAnyDB.
98+
* Forward compatibility with ParserOutput::getTitle().
99+
* Upgrade wikimedia/css-sanitizer from 6.1.0 to 6.2.1.
100+
* (T414805, T418745, T418346) WebPHandler: Allow the original being served on
101+
the web.
102+
* (T411013) mediawiki.util: Add adjustThumbWidthForSteps for step sizing in JS.
103+
* (T411013) mediawiki.util,FileRepo: Improve adjustThumbWidthForSteps test
104+
coverage.
105+
* (T411125) Round to original file width if there is no steep between that &
106+
requested.
107+
* (T411125) File: Allow scaling up vectorized images to larger sizes.
108+
* (T360589, T415598) Move handling of ThumbnailSteps to media handlers.
109+
* (T416518) Disable Composer audit.block-insecure option.
110+
* (T419183) ParserOutputFlags: add HAS_SLOT_HEADERS.
111+
* (T419479) sql: Mark pl_target_id as non-nullable in abstract schema.
112+
* (T329183, T417691) Clarify documentation for action=query&list=tags.
113+
* (T391524) EditPage: Handle MWException when serializing the preloaded
114+
content.
115+
* (T417819) ParserOutputFlags: Back-port new flags added in 1.46 for
116+
forward compat.
117+
* (T384147, CVE-2026-34092) SECURITY: Block UI elements in 'tools'-sidebar
118+
shows presence of an autoblocked IP.
119+
* (T410429, CVE-2026-34088) SECURITY: RecentChanges entries expose suppressed
120+
content via generated log page html.
121+
* (T411305, CVE-2026-34091) SECURITY: User localization leaked by AbuseFilter
122+
+ EventStream.
123+
* (T411366, CVE-2026-34090) SECURITY: Suggested investigations: Handle
124+
suppressed usernames.
125+
* (T414547, CVE-2026-34093) SECURITY: Special:UserRights allows viewing user
126+
rights from private wiki.
127+
* (T416090, CVE-2026-34094) SECURITY: Customized help link for page protection
128+
indicator is relative to subpage name, because the link target is missing the
129+
"/wiki/" prefix.
130+
* (T419192, CVE-2026-34095) SECURITY: action=raw with Special:Mypage subpage
131+
title responds with "Content-Type) SECURITY: text/html" on
132+
ctype=text/javascript request.
133+
9134
== MediaWiki 1.45.1 ==
10135

11136
This is a security and maintenance release of the MediaWiki 1.45 branch.

UPGRADE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Important: Upgrading from releases older than two LTS release is not supported a
1818
If you want to upgrade from an old version, please upgrade to a more recent LTS version first,
1919
then to this version.
2020

21-
Currently any upgrade from any version older than 1.35 will fail.
21+
Currently any upgrade from any version older than 1.38 will fail.
2222

2323
=== Consult the release notes ===
2424

composer.json

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@
3535
"ext-xml": "*",
3636
"ext-xmlreader": "*",
3737
"guzzlehttp/guzzle": "7.10.0",
38-
"justinrainbow/json-schema": "5.3.0",
38+
"justinrainbow/json-schema": "5.3.1",
3939
"lcobucci/jwt": "4.1.5",
4040
"liuggio/statsd-php-client": "1.0.18",
41-
"mck89/peast": "1.17.2",
41+
"mck89/peast": "1.17.4",
4242
"monolog/monolog": "2.9.3",
4343
"oojs/oojs-ui": "0.53.0",
4444
"pear/mail": "2.0.0",
@@ -64,15 +64,15 @@
6464
"wikimedia/common-passwords": "0.5.1",
6565
"wikimedia/composer-merge-plugin": "2.1.0",
6666
"wikimedia/cssjanus": "2.3.0",
67-
"wikimedia/css-sanitizer": "6.1.0",
67+
"wikimedia/css-sanitizer": "6.2.1",
6868
"wikimedia/html-formatter": "4.1.0",
6969
"wikimedia/ip-utils": "5.0.0",
7070
"wikimedia/json-codec": "4.0.0",
71-
"wikimedia/less.php": "5.2.2",
71+
"wikimedia/less.php": "5.5.0",
7272
"wikimedia/minify": "2.9.0",
7373
"wikimedia/normalized-exception": "2.1.1",
7474
"wikimedia/object-factory": "5.0.1",
75-
"wikimedia/parsoid": "0.22.0",
75+
"wikimedia/parsoid": "0.22.3",
7676
"wikimedia/php-session-serializer": "3.0.2",
7777
"wikimedia/purtle": "2.0.0",
7878
"wikimedia/relpath": "4.0.2",
@@ -103,12 +103,12 @@
103103
"nikic/php-parser": "^5.5.0",
104104
"php-parallel-lint/php-console-highlighter": "1.0.0",
105105
"php-parallel-lint/php-parallel-lint": "1.4.0",
106-
"phpunit/phpunit": "9.6.21",
107-
"psy/psysh": "^0.12.3",
106+
"phpunit/phpunit": "9.6.34",
107+
"psy/psysh": "^0.12.19",
108108
"seld/jsonlint": "1.11.0",
109109
"wikimedia/alea": "1.0.0",
110110
"wikimedia/langconv": "^0.5.0",
111-
"wikimedia/testing-access-wrapper": "^3.0.0",
111+
"wikimedia/testing-access-wrapper": "^3.0.0 || ^4.0.0",
112112
"wmde/hamcrest-html-matchers": "^1.0.0"
113113
},
114114
"replace": {
@@ -182,7 +182,10 @@
182182
"@lint",
183183
"@phpcs"
184184
],
185-
"phpunit": "phpunit",
185+
"phpunit": [
186+
"Composer\\Config::disableProcessTimeout",
187+
"phpunit"
188+
],
186189
"phpunit:unit": "@phpunit --colors=always --testsuite=core:unit,extensions:unit",
187190
"phpunit:coverage": "@phpunit --testsuite=core:unit --exclude-group Dump,Broken",
188191
"phpunit:coverage-edit": "MediaWiki\\Composer\\ComposerPhpunitXmlCoverageEdit::onEvent",
@@ -215,6 +218,9 @@
215218
"wikimedia/composer-merge-plugin": true,
216219
"composer/installers": true,
217220
"dealerdirect/phpcodesniffer-composer-installer": true
221+
},
222+
"audit": {
223+
"block-insecure": false
218224
}
219225
},
220226
"extra": {

docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# DEVELOPERS.md
77
services:
88
mediawiki:
9-
image: docker-registry.wikimedia.org/dev/bookworm-php83-fpm:1.0.0
9+
image: docker-registry.wikimedia.org/dev/bookworm-php83-fpm:1.0.0-s1
1010
user: "${MW_DOCKER_UID}:${MW_DOCKER_GID}"
1111
volumes:
1212
- ./:/var/www/html/w:cached

includes/Defines.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
*
2121
* @since 1.35 (also backported to 1.33.3 and 1.34.1)
2222
*/
23-
define( 'MW_VERSION', '1.45.1' );
23+
define( 'MW_VERSION', '1.45.3' );
2424

2525
/** @{
2626
* Obsolete IDatabase::makeList() constants

includes/OutputTransform/Stages/ExtractBody.php

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@
55

66
use MediaWiki\Config\ServiceOptions;
77
use MediaWiki\Html\HtmlHelper;
8+
use MediaWiki\MediaWikiServices;
89
use MediaWiki\OutputTransform\ContentTextTransformStage;
910
use MediaWiki\Parser\Parser;
1011
use MediaWiki\Parser\ParserOptions;
1112
use MediaWiki\Parser\ParserOutput;
12-
use MediaWiki\Parser\Parsoid\ParsoidParser;
13+
use MediaWiki\Title\Title;
1314
use MediaWiki\Utils\UrlUtils;
1415
use Psr\Log\LoggerInterface;
1516
use Wikimedia\RemexHtml\Serializer\SerializerNode;
@@ -98,11 +99,14 @@ protected function transformText( string $text, ParserOutput $po, ?ParserOptions
9899
}
99100
}
100101
}
101-
$title = $po->getExtensionData( ParsoidParser::PARSOID_TITLE_KEY );
102-
if ( !$title ) {
102+
$title = $po->getTitle();
103+
if ( $title === null ) {
103104
// We don't think this should ever trigger, but being conservative
104105
$this->logger->error( __METHOD__ . ": Missing title information in ParserOutput" );
106+
$title = Title::newMainPage();
105107
}
108+
$titleFormatter = MediaWikiServices::getInstance()->getTitleFormatter();
109+
$title = $titleFormatter->getPrefixedDBkey( $title );
106110
$pageFragmentPrefix = "./" . $title . "#";
107111
foreach ( $po->getIndicators() as $name => $html ) {
108112
$po->setIndicator(

includes/OutputTransform/Stages/ParsoidLocalization.php

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
use MediaWiki\Page\PageReferenceValue;
1111
use MediaWiki\Parser\ParserOptions;
1212
use MediaWiki\Parser\ParserOutput;
13-
use MediaWiki\Parser\Parsoid\ParsoidParser;
1413
use MediaWiki\Title\TitleFactory;
1514
use Psr\Log\LoggerInterface;
1615
use Wikimedia\Bcp47Code\Bcp47Code;
@@ -146,18 +145,13 @@ private function localizeI18n(
146145
* @return PageReference
147146
*/
148147
private function getPageReference( ParserOutput $po ): PageReference {
149-
$titleDbKey = $po->getExtensionData( ParsoidParser::PARSOID_TITLE_KEY );
150-
if ( !$titleDbKey ) {
151-
// We don't think this should ever trigger, but being conservative
152-
$this->logger->error( __METHOD__ . ": Missing title information in ParserOutput" );
153-
$titleDbKey = 'Special:BadTitle/Localization';
154-
}
155-
// TODO split PARSOID_TITLE_KEY into ns + title & use PageReferenceValue directly
156-
$pageRef = $this->titleFactory->newFromDBkey( $titleDbKey );
157-
if ( !$pageRef ) {
148+
$title = $po->getTitle();
149+
if ( $title === null ) {
158150
$this->logger->error( __METHOD__ . ": Bad title information in ParserOutput" );
159-
$pageRef = PageReferenceValue::localReference( NS_SPECIAL, 'BadTitle/Localization' );
151+
return PageReferenceValue::localReference( NS_SPECIAL, 'BadTitle/Localization' );
160152
}
161-
return $pageRef;
153+
return PageReferenceValue::localReference(
154+
$title->getNamespace(), $title->getDBkey()
155+
);
162156
}
163157
}

includes/Request/FauxResponse.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,11 @@ public function getHeader( $key ) {
8080
return $this->headers[$key] ?? null;
8181
}
8282

83+
/** @return string[] All set headers */
84+
public function getHeaders(): array {
85+
return $this->headers ?? [];
86+
}
87+
8388
/**
8489
* Get the HTTP response code, null if not set
8590
*

0 commit comments

Comments
 (0)