Two-factor Authentication (TFA) – Moderately critical – Access bypass – SA-CONTRIB-2024-003

Drupal Security Advisory

Access bypass
Affected versions: 

This module enables you to allow and/or require users to use a second authentication method in addition to password authentication.

In some cases, the module allows users to log in with an authentication plugin that an administrator has disabled.

This vulnerability is mitigated by the fact that an attacker must obtain a valid first-factor login credential, that an administrator must enable and then disable an authentication plugin, and that an attacker must obtain the valid second factor credential for the disabled plugin.


Install the latest 8.x-1.2 version:

  • If you use the Two-factor Authentication (TFA) for Drupal 8, 9, or 10 upgrade to TFA 8.x-1.5

After installing this update disabled plugins will no longer be offered or accepted as a second factor option.

If an account is configured with only disabled plugins login will be prohibited and the the configured TFA “Help text” displayed instead of a second factor prompt.

To allow access for a locked out user site owners may consider enabling the plugin (admin/config/people/tfa) or may use their existing procedures for granting access to accounts where the user has forgotten/lost their second factor tokens.

Accounts with both enabled and disabled plugins will prompt the account owner with one of the remaining enabled plugins.

Reported By: 
Fixed By: 
Coordinated By: