Skip to content

Uncaught Exception: Invalid characters in the base32 string #747

@Tijmen-Scherp

Description

@Tijmen-Scherp

Describe the bug

Our users were previously using Solid Security's 2fa functionality. When disabling Solid Security and installing the Two-Factor plugin, it seems most user's 2fa settings are automatically recognized by the Two-Factor plugin. Users with email authentication are still receiving email codes and can log in accordingly.

However, some of our users that have 2fa set up with their Authenticator app, report fatal errors when attempting to input their 2fa code:

Uncaught Exception: Invalid characters in the base32 string in /plugins/two-factor/providers/class-two-factor-totp.php:752

Any ideas on what could be causing this, and how to prevent this or fix this without having to manually reset everyone's 2fa settings?

Steps to Reproduce

  1. Set up 2fa using the authenticator method with Solid Security.
  2. Disable Solid Security.
  3. Install Two-Factor.
  4. Attempt to log in with the existing authenticator method attributed to a user.

Screenshots, screen recording, code snippet

No response

Environment information

No response

Please confirm that you have searched existing issues in this repository.

Yes

Please confirm that you have tested with all plugins deactivated except Two-Factor.

Yes

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions