diff --git a/.patches/x509-loadcrl-param-fix.diff b/.patches/x509-loadcrl-param-fix.diff new file mode 100644 index 000000000..2ca9d5830 --- /dev/null +++ b/.patches/x509-loadcrl-param-fix.diff @@ -0,0 +1,11 @@ +--- a/phpseclib/File/X509.php ++++ b/phpseclib/File/X509.php +@@ -2393,7 +2393,7 @@ class X509 + /** + * Load a Certificate Revocation List + * +- * @param string $crl ++ * @param string|array $crl + * @param int $mode + * @return mixed + */ diff --git a/REUSE.toml b/REUSE.toml index f23815ba8..4aa653512 100644 --- a/REUSE.toml +++ b/REUSE.toml @@ -17,6 +17,7 @@ SPDX-License-Identifier = "CC0-1.0" [[annotations]] path = [ ".devcontainer/devcontainer.json", + ".patches/**", "appinfo/info.xml", "composer.json", "composer.lock", @@ -38,6 +39,8 @@ path = [ "openapi.json", "package-lock.json", "package.json", + "patches.json", + "patches.lock.json", "tests/php/phpunit.xml", "psalm.xml", "src/types/openapi/openapi-administration.ts", diff --git a/composer.json b/composer.json index 253245a30..8cf35f955 100644 --- a/composer.json +++ b/composer.json @@ -10,7 +10,8 @@ "classmap-authoritative": true, "sort-packages": true, "allow-plugins": { - "bamarni/composer-bin-plugin": true + "bamarni/composer-bin-plugin": true, + "cweagans/composer-patches": true }, "platform": { "php": "8.2" @@ -38,7 +39,8 @@ "bamarni-bin": { "bin-links": true, "forward-command": true - } + }, + "patches-file": "patches.json" }, "autoload": { "psr-4": { @@ -55,6 +57,7 @@ } }, "require": { + "cweagans/composer-patches": "^2.0", "phpseclib/phpseclib": "^3.0" } } diff --git a/composer.lock b/composer.lock index 64dcd6898..4444ae7f0 100644 --- a/composer.lock +++ b/composer.lock @@ -4,8 +4,131 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "91238b439ac9dd20efffb65df99cbb6e", + "content-hash": "2d156caa65de467a656e1bd439e02820", "packages": [ + { + "name": "cweagans/composer-configurable-plugin", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/cweagans/composer-configurable-plugin.git", + "reference": "15433906511a108a1806710e988629fd24b89974" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/cweagans/composer-configurable-plugin/zipball/15433906511a108a1806710e988629fd24b89974", + "reference": "15433906511a108a1806710e988629fd24b89974", + "shasum": "" + }, + "require": { + "php": ">=8.0.0" + }, + "require-dev": { + "codeception/codeception": "~4.0", + "codeception/module-asserts": "^2.0", + "composer/composer": "~2.0", + "php-coveralls/php-coveralls": "~2.0", + "php-parallel-lint/php-parallel-lint": "^1.0.0", + "phpro/grumphp": "^1.8.0", + "sebastian/phpcpd": "^6.0", + "squizlabs/php_codesniffer": "^3.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "cweagans\\Composer\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Cameron Eagans", + "email": "me@cweagans.net" + } + ], + "description": "Provides a lightweight configuration system for Composer plugins.", + "support": { + "issues": "https://github.com/cweagans/composer-configurable-plugin/issues", + "source": "https://github.com/cweagans/composer-configurable-plugin/tree/2.0.0" + }, + "funding": [ + { + "url": "https://github.com/cweagans", + "type": "github" + } + ], + "time": "2023-02-12T04:58:58+00:00" + }, + { + "name": "cweagans/composer-patches", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/cweagans/composer-patches.git", + "reference": "bfa6018a5f864653d9ed899b902ea72f858a2cf7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/cweagans/composer-patches/zipball/bfa6018a5f864653d9ed899b902ea72f858a2cf7", + "reference": "bfa6018a5f864653d9ed899b902ea72f858a2cf7", + "shasum": "" + }, + "require": { + "composer-plugin-api": "^2.0", + "cweagans/composer-configurable-plugin": "^2.0", + "ext-json": "*", + "php": ">=8.0.0" + }, + "require-dev": { + "codeception/codeception": "~4.0", + "codeception/module-asserts": "^2.0", + "codeception/module-cli": "^2.0", + "codeception/module-filesystem": "^2.0", + "composer/composer": "~2.0", + "php-coveralls/php-coveralls": "~2.0", + "php-parallel-lint/php-parallel-lint": "^1.0.0", + "phpro/grumphp": "^1.8.0", + "sebastian/phpcpd": "^6.0", + "squizlabs/php_codesniffer": "^4.0" + }, + "type": "composer-plugin", + "extra": { + "_": "The following two lines ensure that composer-patches is loaded as early as possible.", + "class": "cweagans\\Composer\\Plugin\\Patches", + "plugin-modifies-downloads": true, + "plugin-modifies-install-path": true + }, + "autoload": { + "psr-4": { + "cweagans\\Composer\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Cameron Eagans", + "email": "me@cweagans.net" + } + ], + "description": "Provides a way to patch Composer packages.", + "support": { + "issues": "https://github.com/cweagans/composer-patches/issues", + "source": "https://github.com/cweagans/composer-patches/tree/2.0.0" + }, + "funding": [ + { + "url": "https://github.com/cweagans", + "type": "github" + } + ], + "time": "2025-10-30T23:44:22+00:00" + }, { "name": "paragonie/constant_time_encoding", "version": "v3.1.3", diff --git a/patches.json b/patches.json new file mode 100644 index 000000000..f1babfa7b --- /dev/null +++ b/patches.json @@ -0,0 +1,10 @@ +{ + "patches": { + "phpseclib/phpseclib": [ + { + "description": "Fix loadCRL method parameter type annotation", + "url": ".patches/x509-loadcrl-param-fix.diff" + } + ] + } +} diff --git a/patches.lock.json b/patches.lock.json new file mode 100644 index 000000000..b8559e42c --- /dev/null +++ b/patches.lock.json @@ -0,0 +1,17 @@ +{ + "_hash": "ab356137968384649e209979dfb836f69e34d12fc79faf576840ce575607c97d", + "patches": { + "phpseclib/phpseclib": [ + { + "package": "phpseclib/phpseclib", + "description": "Fix loadCRL method parameter type annotation", + "url": ".patches/x509-loadcrl-param-fix.diff", + "sha256": "902d4ccdbc5178bba4d27f4ee3b57d8e41227492ced56e2252e05da0d65a4956", + "depth": 1, + "extra": { + "provenance": "patches-file:patches.json" + } + } + ] + } +}