Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix(webauthn): do not require bcmath or gmp - not needed anymore
The extensions are not required anymore but only recommended for
performance. See also:
web-auth/webauthn-framework#213

Signed-off-by: Ferdinand Thiessen <[email protected]>
  • Loading branch information
susnux authored and AndyScherzinger committed Apr 1, 2025
commit ff172e178ec7f56596fdad99cd18d3b1e577de34
3 changes: 1 addition & 2 deletions apps/settings/lib/Settings/Personal/Security/WebAuthn.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ public function getForm() {
$this->mapper->findAllForUid($this->userId)
);

return new TemplateResponse('settings', 'settings/personal/security/webauthn', [
]);
return new TemplateResponse('settings', 'settings/personal/security/webauthn');
}

public function getSection(): ?string {
Expand Down
4 changes: 1 addition & 3 deletions apps/settings/lib/SetupChecks/PhpModules.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ class PhpModules implements ISetupCheck {
'zlib',
];
protected const RECOMMENDED_MODULES = [
'bcmath',
'exif',
'gmp',
'intl',
Expand All @@ -58,8 +57,7 @@ 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'),
'bcmath' => $this->l10n->t('for WebAuthn passwordless login'),
'gmp' => $this->l10n->t('for WebAuthn passwordless login, and SFTP storage'),
'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 => '',
};
Expand Down
8 changes: 0 additions & 8 deletions lib/private/Authentication/WebAuthn/Manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -246,14 +246,6 @@ public function deleteRegistration(IUser $user, int $id): void {
}

public function isWebAuthnAvailable(): bool {
if (!extension_loaded('bcmath')) {
return false;
}

if (!extension_loaded('gmp')) {
return false;
}

if (!$this->config->getSystemValueBool('auth.webauthn.enabled', true)) {
return false;
}
Expand Down