From ea9bbe64c139ae9393bc319da42fd5dbc797a597 Mon Sep 17 00:00:00 2001 From: Micke Nordin Date: Tue, 5 May 2026 16:29:09 +0200 Subject: [PATCH] chore: require ext-sodium Promote ext-sodium from recommended to required so RFC 9421 Ed25519 signing/verifying can rely on libsodium unconditionally. Add the matching openssl + sodium psalm stubs. Signed-off-by: Micke Nordin --- apps/settings/lib/SetupChecks/PhpModules.php | 3 +-- build/stubs/openssl.php | 12 ++++++++++++ build/stubs/sodium.php | 13 +++++++++++++ composer.json | 1 + psalm.xml | 2 ++ 5 files changed, 29 insertions(+), 2 deletions(-) create mode 100644 build/stubs/openssl.php create mode 100644 build/stubs/sodium.php diff --git a/apps/settings/lib/SetupChecks/PhpModules.php b/apps/settings/lib/SetupChecks/PhpModules.php index 64fa6e15c0a..d4c3d2c5c2a 100644 --- a/apps/settings/lib/SetupChecks/PhpModules.php +++ b/apps/settings/lib/SetupChecks/PhpModules.php @@ -24,6 +24,7 @@ class PhpModules implements ISetupCheck { 'openssl', 'posix', 'session', + 'sodium', 'xml', 'xmlreader', 'xmlwriter', @@ -35,7 +36,6 @@ class PhpModules implements ISetupCheck { 'exif', 'gmp', 'intl', - 'sodium', 'sysvsem', ]; @@ -58,7 +58,6 @@ class PhpModules implements ISetupCheck { protected function getRecommendedModuleDescription(string $module): string { return match($module) { 'intl' => $this->l10n->t('increases language translation performance and fixes sorting of non-ASCII characters'), - 'sodium' => $this->l10n->t('for Argon2 for password hashing'), 'gmp' => $this->l10n->t('required for SFTP storage and recommended for WebAuthn performance'), 'exif' => $this->l10n->t('for picture rotation in server and metadata extraction in the Photos app'), default => '', diff --git a/build/stubs/openssl.php b/build/stubs/openssl.php new file mode 100644 index 00000000000..5bf410a6774 --- /dev/null +++ b/build/stubs/openssl.php @@ -0,0 +1,12 @@ + + +