From 7acccf2f8f0d7ee81e5aa41863eac71d371623a1 Mon Sep 17 00:00:00 2001 From: William Jacoby Date: Thu, 22 Oct 2026 11:56:29 -0500 Subject: [PATCH 1/2] Require phpBB 3.3.19 and PHP 8.3.36 for extension enablement --- ext.php | 6 +++--- language/en/install_wiki.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ext.php b/ext.php index d7d0e4a..100126b 100644 --- a/ext.php +++ b/ext.php @@ -89,7 +89,7 @@ public function is_enableable() } /** - * Require phpBB 3.3.19 + * Require phpBB 3.3.19 due to several security fixes in the phpBB software. * * @return bool */ @@ -99,13 +99,13 @@ public function check_phpbb_version() } /** - * Require PHP 8.2 + * Requires PHP 8.3.36 due to security fixes. * * @return bool */ public function check_php_version() { - return PHP_VERSION_ID >= 80200; + return PHP_VERSION_ID >= 80336; } /** diff --git a/language/en/install_wiki.php b/language/en/install_wiki.php index 39e87ef..8956506 100644 --- a/language/en/install_wiki.php +++ b/language/en/install_wiki.php @@ -42,6 +42,6 @@ // $lang = array_merge($lang, [ - 'WIKI_NOT_ENABLEABLE' => 'phpBB Modders Wiki could not be enabled. It needs phpBB 3.3.19 or later and PHP 8.2.0 or later.', + 'WIKI_NOT_ENABLEABLE' => 'phpBB Modders Wiki could not be enabled. It needs phpBB 3.3.19 or later and PHP 8.3.36 or later.', 'WIKI_DISABLE_OLD' => 'Disable the old ā€œ%sā€ extension first. Keep its data; do not delete it.', ]); From 61893caf6a69ad36a4c88f05c2b1e10406df82ab Mon Sep 17 00:00:00 2001 From: William Jacoby Date: Thu, 22 Oct 2026 12:30:35 -0500 Subject: [PATCH 2/2] Align CI and support checks with the PHP 8.3.36 security minimum --- .github/workflows/lint.yml | 4 ++-- .github/workflows/tests.yml | 8 ++++---- README.md | 2 +- composer.json | 2 +- docs/compatibility.md | 4 ++-- tests/unit/declared_support_test.php | 16 ++++++++-------- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 990f48b..801537e 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -1,7 +1,7 @@ name: Lint # PHP syntax check on the lowest PHP version this extension supports and the -# newest one phpBB 3.3 supports. tests.yml covers PHP 8.2 with phpBB's own +# newest one phpBB 3.3 supports. tests.yml covers PHP 8.3 with phpBB's own # checks (code sniffer, EPV). on: push: @@ -20,7 +20,7 @@ jobs: runs-on: ubuntu-24.04 strategy: matrix: - php: ['8.2', '8.5'] + php: ['8.3', '8.5'] steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 37f179a..4a09878 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,8 +22,8 @@ jobs: EPV: 0 PHPBB_BRANCH: '3.3.x' RUN_FUNCTIONAL_TESTS: 0 - PRIMARY_PHP_VERSION: '8.2' - PHP_VERSION_MATRIX: '["8.2", "8.3", "8.4", "8.5"]' + PRIMARY_PHP_VERSION: '8.3' + PHP_VERSION_MATRIX: '["8.3", "8.4", "8.5"]' # phpBB 4.0 (master) compatibility call-tests-master: @@ -35,8 +35,8 @@ jobs: EPV: 0 PHPBB_BRANCH: 'master' RUN_FUNCTIONAL_TESTS: 0 - PRIMARY_PHP_VERSION: '8.2' - PHP_VERSION_MATRIX: '["8.2", "8.3", "8.4", "8.5"]' + PRIMARY_PHP_VERSION: '8.3' + PHP_VERSION_MATRIX: '["8.3", "8.4", "8.5"]' # EPV (Extension Pre Validator), failing on any Fatal or Error finding not # listed in .github/epv-allowed.txt diff --git a/README.md b/README.md index 249215b..57b61a1 100644 --- a/README.md +++ b/README.md @@ -195,7 +195,7 @@ Articles and posts written before this feature existed get their links the next ## Requirements - phpBB 3.3.19 or later (also tested on phpBB 4.0) -- PHP 8.2 or later +- PHP 8.3.36 or later Tested versions and compatibility notes: [docs/compatibility.md](docs/compatibility.md). diff --git a/composer.json b/composer.json index 47700ad..c278330 100644 --- a/composer.json +++ b/composer.json @@ -31,7 +31,7 @@ } ], "require": { - "php": ">=8.2" + "php": ">=8.3.36" }, "require-dev": { "phpbb/epv": "dev-master" diff --git a/docs/compatibility.md b/docs/compatibility.md index 5c36a08..d1dcf55 100644 --- a/docs/compatibility.md +++ b/docs/compatibility.md @@ -6,8 +6,8 @@ notifications), on: - phpBB 3.3.x (tested on 3.3.18-dev) - phpBB 4.0.0-a3-dev -PHP 8.2 or later is required (the extension refuses to enable below it). CI runs PHP 8.2, 8.3, 8.4 -and 8.5 on phpBB 3.3.x and on phpBB master; PHP 8.1 and older are past end of life. +PHP 8.3.36 or later is required due to security fixes; the extension refuses to enable below it. +CI runs PHP 8.3, 8.4 and 8.5 on phpBB 3.3.x and on phpBB master. phpBB 3.2.x compatibility is **not independently verified by this fork** — it's carried forward from Crizz0/phpBB.de's original claim for their branch. diff --git a/tests/unit/declared_support_test.php b/tests/unit/declared_support_test.php index 71829a2..709f0b6 100644 --- a/tests/unit/declared_support_test.php +++ b/tests/unit/declared_support_test.php @@ -26,26 +26,26 @@ private function read(string $path): string return file_get_contents(self::ROOT . '/' . $path); } - public function test_composer_requires_php_8_2_or_newer() + public function test_composer_requires_php_8_3_36_or_newer() { $composer = json_decode($this->read('composer.json'), true, 512, JSON_THROW_ON_ERROR); - $this->assertSame('>=8.2', $composer['require']['php']); + $this->assertSame('>=8.3.36', $composer['require']['php']); } public function test_the_extension_refuses_to_enable_below_the_same_version() { - $this->assertMatchesRegularExpression('/return PHP_VERSION_ID >= 80200;/', $this->read('ext.php')); - $this->assertStringContainsString('PHP 8.2.0', $this->read('language/en/install_wiki.php')); + $this->assertMatchesRegularExpression('/return PHP_VERSION_ID >= 80336;/', $this->read('ext.php')); + $this->assertStringContainsString('PHP 8.3.36', $this->read('language/en/install_wiki.php')); } public function test_the_readme_states_the_same_requirement() { - $this->assertStringContainsString('- PHP 8.2 or later', $this->read('README.md')); + $this->assertStringContainsString('- PHP 8.3.36 or later', $this->read('README.md')); } /** @dataProvider workflows_with_a_php_matrix */ - public function test_every_ci_matrix_starts_at_8_2_and_includes_8_5(string $file) + public function test_every_ci_matrix_starts_at_8_3_and_includes_8_5(string $file) { $workflow = $this->read($file); @@ -54,7 +54,7 @@ public function test_every_ci_matrix_starts_at_8_2_and_includes_8_5(string $file { $versions = json_decode(str_replace("'", '"', $matrix), true); usort($versions, 'version_compare'); - $this->assertSame('8.2', $versions[0], $file . ' ' . $matrix); + $this->assertSame('8.3', $versions[0], $file . ' ' . $matrix); $this->assertContains('8.5', $versions, $file . ' ' . $matrix); } } @@ -72,7 +72,7 @@ public function test_both_test_jobs_name_a_primary_php_inside_their_matrix() $workflow = $this->read('.github/workflows/tests.yml'); $this->assertSame(2, preg_match_all("/PRIMARY_PHP_VERSION: '([0-9.]+)'/", $workflow, $primary)); - $this->assertSame(['8.2', '8.2'], $primary[1]); + $this->assertSame(['8.3', '8.3'], $primary[1]); $this->assertSame(2, substr_count($workflow, 'PHP_VERSION_MATRIX')); } }