Skip to content

500 Error during FIDO2 Key Registration #1456

Description

@miracuruzrh

Describe the bug
When trying to register a new WebAuthn/FIDO2 security key, the process fails with a "500 Internal Server Error".

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'User settings' and then to the 2FA section.
  2. Select tab 'Sicherheitsschlüssel (U2F)'
  3. Click on 'Neuen Sicherheitsschlüssel registrieren'
  4. Enter a key name in field keyName. For example "Key1"
  5. Click on 'Schlüssel hinzufügen'
  6. Select either physical key or software like 1Password and try to add/update the key
  7. Error message appears.

Expected behavior
The FIDO2 security key should be successfully registered without throwing an exception.

** Error message **

500
Internal Server Error
Something bad happened internally.
There is nothing you could do about this, except trying to reload the page.
You can try to [Go Back](https://partdb-simon.miracuru.ch/de/webauthn/register#) or [Visit the homepage](https://partdb-simon.miracuru.ch/de/).

If this error persists, please contact your administrator.

Infos for Admin: You could try following things, if this error is unexpected:
Check var/log/prod.log (or docker logs when Part-DB is running inside a docker container) for additional informations
Run php bin/console cache:clear and php bin/console cache:pool:clear --all to clear caches
If you think that this is an error in Part-DB, open an Issue on [GitHub](https://github.com/Part-DB/Part-DB-server/issues).

You can disable these hints in config/parameters.yaml by setting partdb.error_pages.show_help to false.

Note; following the hints to clear caches did not help.

Screenshots
Image

Server Side

  • Part-DB:
    • Part-DB Version: [Version: 2.13.3]
    • Installation type: [docker]
  • OS: debian trixie
    • VERSION_CODENAME=trixie
    • DEBIAN_VERSION_FULL=13.6
  • PHP Version: [PHP 8.4.23 (cli) (built: Jul 3 2026 12:26:56) (NTS)]
  • php-fpm version: [PHP 8.4.23 (cli) (built: Jul 3 2026 12:26:56) (NTS)]
  • Docker version: [Docker version 29.6.2, build dfc4efb]
  • Docker compose version: [Docker Compose version v5.3.1]
  • Database Server [mariadb from 12.3.2-MariaDB, client 15.2 for debian-linux-gnu (x86_64) using EditLine wrapper]

Desktop (please complete the following information):

  • OS: [Windows 11 25H2 Build 26200.8894]
  • Browser [Brave Browser (Shields turned off)]
  • Version [Brave 1.92.141 Chromium: 150.0.7871.128 (Offizieller Build) (64-Bit)]

Smartphone (please complete the following information):
n/a

Docker log

partdb_simon  | [2026-07-21T20:58:53.595723+00:00] request.INFO: Matched route "webauthn_register". {"route":"webauthn_register","route_parameters":{"_route":"webauthn_register","_controller":"App\\Controller\\WebauthnKeyRegistrationController::register","_locale":"de"},"request_uri":"https://partdb-simon.miracuru.ch/de/webauthn/register","method":"POST"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596762+00:00] security.DEBUG: Checking for authenticator support. {"firewall_name":"main","authenticators":5} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596771+00:00] security.DEBUG: Checking support on authenticator. {"firewall_name":"main","authenticator":"App\\Security\\ApiTokenAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596776+00:00] security.DEBUG: Authenticator does not support the request. {"firewall_name":"main","authenticator":"App\\Security\\ApiTokenAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596778+00:00] security.DEBUG: Checking support on authenticator. {"firewall_name":"main","authenticator":"Scheb\\TwoFactorBundle\\Security\\Http\\Authenticator\\TwoFactorAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596785+00:00] security.DEBUG: Authenticator does not support the request. {"firewall_name":"main","authenticator":"Scheb\\TwoFactorBundle\\Security\\Http\\Authenticator\\TwoFactorAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596786+00:00] security.DEBUG: Checking support on authenticator. {"firewall_name":"main","authenticator":"Nbgrp\\OneloginSamlBundle\\Security\\Http\\Authenticator\\SamlAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596789+00:00] security.DEBUG: Authenticator does not support the request. {"firewall_name":"main","authenticator":"Nbgrp\\OneloginSamlBundle\\Security\\Http\\Authenticator\\SamlAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596790+00:00] security.DEBUG: Checking support on authenticator. {"firewall_name":"main","authenticator":"Symfony\\Component\\Security\\Http\\Authenticator\\FormLoginAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596793+00:00] security.DEBUG: Authenticator does not support the request. {"firewall_name":"main","authenticator":"Symfony\\Component\\Security\\Http\\Authenticator\\FormLoginAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596794+00:00] security.DEBUG: Checking support on authenticator. {"firewall_name":"main","authenticator":"Symfony\\Component\\Security\\Http\\Authenticator\\RememberMeAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.596801+00:00] security.DEBUG: Remember-me cookie detected. [] {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.597199+00:00] security.DEBUG: Read existing security token from the session. {"key":"_security_main","token_class":"Symfony\\Component\\Security\\Core\\Authentication\\Token\\UsernamePasswordToken"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.599135+00:00] security.DEBUG: User was reloaded from a user provider. {"provider":"Symfony\\Bridge\\Doctrine\\Security\\User\\EntityUserProvider","username":"admin"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":null}
partdb_simon  | [2026-07-21T20:58:53.599158+00:00] security.DEBUG: Skipping the "Symfony\Component\Security\Http\Authenticator\RememberMeAuthenticator" authenticator as it did not support the request. {"authenticator":"Symfony\\Component\\Security\\Http\\Authenticator\\RememberMeAuthenticator"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":{"authenticated":true,"roles":["ROLE_USER"],"user_identifier":"admin"}}
partdb_simon  | [2026-07-21T20:58:53.604140+00:00] request.CRITICAL: Uncaught PHP Exception TypeError: "Jbtronics\TFAWebauthn\Services\TFAWebauthnRegistrationHelper::checkRegistrationResponse(): Return value must be of type Webauthn\PublicKeyCredentialSource, Webauthn\CredentialRecord returned" at TFAWebauthnRegistrationHelper.php line 139 {"exception":"[object] (TypeError(code: 0): Jbtronics\\TFAWebauthn\\Services\\TFAWebauthnRegistrationHelper::checkRegistrationResponse(): Return value must be of type Webauthn\\PublicKeyCredentialSource, Webauthn\\CredentialRecord returned at /var/www/html/vendor/jbtronics/2fa-webauthn/src/Services/TFAWebauthnRegistrationHelper.php:139)
partdb_simon  | [stacktrace]
partdb_simon  | #0 /var/www/html/src/Controller/WebauthnKeyRegistrationController.php(75): Jbtronics\\TFAWebauthn\\Services\\TFAWebauthnRegistrationHelper->checkRegistrationResponse()
partdb_simon  | #1 /var/www/html/vendor/symfony/http-kernel/HttpKernel.php(183): App\\Controller\\WebauthnKeyRegistrationController->register()
partdb_simon  | #2 /var/www/html/vendor/symfony/http-kernel/HttpKernel.php(76): Symfony\\Component\\HttpKernel\\HttpKernel->handleRaw()
partdb_simon  | #3 /var/www/html/vendor/symfony/http-kernel/Kernel.php(193): Symfony\\Component\\HttpKernel\\HttpKernel->handle()
partdb_simon  | #4 /var/www/html/vendor/symfony/runtime/Runner/Symfony/HttpKernelRunner.php(34): Symfony\\Component\\HttpKernel\\Kernel->handle()
partdb_simon  | #5 /var/www/html/vendor/autoload_runtime.php(32): Symfony\\Component\\Runtime\\Runner\\Symfony\\HttpKernelRunner->run()
partdb_simon  | #6 /var/www/html/public/index.php(5): require_once('...')
partdb_simon  | #7 {main}
partdb_simon  | "} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":{"authenticated":true,"roles":["ROLE_USER"],"user_identifier":"admin"}}
partdb_simon  | [2026-07-21T20:58:53.605937+00:00] security.DEBUG: Stored the security token in the session. {"key":"_security_main"} {"url":"/de/webauthn/register","ip":"192.168.1.13","http_method":"POST","server":"partdb-simon.miracuru.ch","referrer":"https://partdb-simon.miracuru.ch/de/webauthn/register","token":{"authenticated":true,"roles":["ROLE_USER"],"user_identifier":"admin"}}
partdb_simon  | 172.19.0.1 - - [21/Jul/2026:20:58:53 +0000] "POST /de/webauthn/register HTTP/1.1" 500 4462 "https://partdb-simon.miracuru.ch/de/webauthn/register" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/150.0.0.0 Safari/537.36"
partdb_simon  | - -  21/Jul/2026:20:58:53 +0000 "POST /index.php" 500

Additional context
None.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions