Mautic 2FA Installation Instructions

MAUTIC 2FA Plugin

Add Extra Security to Your Mautic Login

The 2FA Plugin (LenonLeiteMautic2FABundle) enables two-factor authentication (2FA) for your AMS (Automated Marketing System) login, adding an extra layer of security. Once enabled, users will be required to enter a time-based one-time password (TOTP) from an authenticator app such as Google Authenticator, Authy, or similar, in addition to their regular login credentials.

Supported Versions

This plugin is supported for Mautic 5.0 and up, running on PHP 8.1 or higher.

Features & Benefits

Enhanced login security – Protects your Mautic instance with time-based authentication codes.

QR Code setup – Easily scan and configure with your favorite authentication app.

Per-user reset – Admins can reset 2FA for individual users if needed.

Installation Instructions

  1. Upload the Plugin
    • Extract the plugin folder LenonLeiteMautic2FABundle into your plugins directory inside your Mautic installation.
  2. Clear Cache
    • Run the following command:

      php bin/console cache:clear

    • Or manually delete the var/cache folder in your AMS directory.
  3. Install the Plugin
    • Log in to your Mautic instance.
    • Navigate to Settings → Plugins.
    • Click Install/Upgrade Plugins to detect and activate the new plugin.
  4. Enable 2FA
    • Go to Settings → Two Factor Authentication.
    • Configure your desired settings and activate the plugin.

How to Use

  1. Once the plugin is enabled, users will be prompted to scan a QR code during their next login.
  2. Scan the QR code with your authentication app (e.g., Google Authenticator).
  3. Enter the 6-digit code generated by the app and submit.
  4. That’s it – your account is now protected by 2FA!

Resetting 2FA for Users

  1. Go to /s/users in the AMS admin panel.
  2. Select the users you want to reset.
  3. Click Batch Actions → Reset 2FA.


Credits

This plugin was developed by @lenonleite and uses the excellent RobThree/TwoFactorAuth library for QR and code validation.