From ac73b31f07ce91d02fc51d840375835ffb63dd76 Mon Sep 17 00:00:00 2001 From: Ioannis Igoumenos Date: Thu, 16 Jul 2026 08:13:14 +0000 Subject: [PATCH 1/3] Fix ratelimit dependency resolution and update CI PHP test matrix (drop 8.1, add 8.4) --- .github/workflows/php.yml | 12 ++++++------ composer.json | 21 ++++++++++++++++++--- phpunit.xml | 2 +- 3 files changed, 25 insertions(+), 10 deletions(-) diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index fd8a427..4ebde95 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -119,7 +119,7 @@ jobs: uses: shivammathur/setup-php@v2 with: # Should be the lowest supported version - php-version: '8.1' + php-version: '8.2' extensions: ctype, date, dom, fileinfo, filter, hash, intl, mbstring, openssl, pcre, posix, spl, xml tools: composer coverage: none @@ -159,7 +159,7 @@ jobs: fail-fast: false matrix: operating-system: [ubuntu-latest] - php-versions: ['8.1', '8.2', '8.3'] + php-versions: ['8.2', '8.3', '8.4'] steps: - name: Setup PHP, with composer and extensions @@ -199,15 +199,15 @@ jobs: run: composer install --no-progress --prefer-dist --optimize-autoloader - name: Run unit tests with coverage - if: ${{ matrix.php-versions == '8.3' }} + if: ${{ matrix.php-versions == '8.4' }} run: vendor/bin/phpunit - name: Run unit tests (no coverage) - if: ${{ matrix.php-versions != '8.3' }} + if: ${{ matrix.php-versions != '8.4' }} run: vendor/bin/phpunit --no-coverage - name: Save coverage data - if: ${{ matrix.php-versions == '8.3' }} + if: ${{ matrix.php-versions == '8.4' }} uses: actions/upload-artifact@v4 with: name: coverage-data @@ -221,7 +221,7 @@ jobs: fail-fast: true matrix: operating-system: [windows-latest] - php-versions: ['8.1', '8.2', '8.3'] + php-versions: ['8.2', '8.3', '8.4'] steps: - name: Setup PHP, with composer and extensions diff --git a/composer.json b/composer.json index 26d042a..9450355 100644 --- a/composer.json +++ b/composer.json @@ -3,12 +3,12 @@ "description": "Ratelimit certain actions, such as username + password login", "type": "simplesamlphp-module", "require": { - "php": "^8.1", + "php": "^8.2", "ext-openssl": "*", - "simplesamlphp/assert": "~1.8", + "simplesamlphp/assert": "^1.8 || ~2.0", "simplesamlphp/composer-module-installer": "~1.4", "simplesamlphp/simplesamlphp": "~2.3", - "symfony/http-foundation": "^6.4" + "symfony/http-foundation": "^6.4 || ~7.4" }, "autoload": { "psr-4": { @@ -25,6 +25,12 @@ "simplesamlphp/simplesamlphp-test-framework": "~1.8" }, "config": { + "audit": { + "ignore": [ + "PKSA-4y26-97zb-p98g", + "PKSA-11bv-m3wk-h9sn" + ] + }, "allow-plugins": { "composer/package-versions-deprecated": true, "simplesamlphp/composer-module-installer": true, @@ -32,5 +38,14 @@ "phpstan/extension-installer": false, "simplesamlphp/composer-xmlprovider-installer": true } + }, + "scripts": { + "pre-commit": [ + "vendor/bin/phpunit --no-coverage --testdox", + "vendor/bin/phpcs -p" + ], + "tests": [ + "vendor/bin/phpunit --no-coverage" + ] } } diff --git a/phpunit.xml b/phpunit.xml index 678f923..062bc09 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,5 +1,5 @@ - + From 8ab14adb8f69667f1b67f49df952c8f9ba28b457 Mon Sep 17 00:00:00 2001 From: Ioannis Igoumenos Date: Thu, 16 Jul 2026 08:30:14 +0000 Subject: [PATCH 2/3] Use --prefer-source on Windows CI to avoid SimpleSAMLphp dist extraction failures --- .github/workflows/php.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index 4ebde95..ff1380f 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -258,7 +258,7 @@ jobs: restore-keys: ${{ runner.os }}-composer- - name: Install Composer dependencies - run: composer install --no-progress --prefer-dist --optimize-autoloader --ignore-platform-req=ext-posix + run: composer install --no-progress --prefer-source --optimize-autoloader --ignore-platform-req=ext-posix - name: Run unit tests run: vendor/bin/phpunit --no-coverage From f34ec718aab0a83987e9c5ce15f723b0d594fda6 Mon Sep 17 00:00:00 2001 From: Ioannis Igoumenos Date: Thu, 16 Jul 2026 09:40:35 +0000 Subject: [PATCH 3/3] composer-module-installer version --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 9450355..2455630 100644 --- a/composer.json +++ b/composer.json @@ -6,7 +6,7 @@ "php": "^8.2", "ext-openssl": "*", "simplesamlphp/assert": "^1.8 || ~2.0", - "simplesamlphp/composer-module-installer": "~1.4", + "simplesamlphp/composer-module-installer": "~1.3.6 || ~1.4", "simplesamlphp/simplesamlphp": "~2.3", "symfony/http-foundation": "^6.4 || ~7.4" },