miniOrange 2FA icon
Security

miniOrange 2FA hooks reference

  • By miniOrange
  • v6.6.1 New
  • Updated

miniOrange 2FA 6.6.1 has 11 actions and 12 filters, read directly from its source code on Nov 17, 2026. The list updates automatically when a new version is released.

How to use these hooks

Actions let you run your own code at a specific moment. Filters let you change a value before the plugin uses it. Put your code in a child theme's functions.php or a code-snippets plugin, never in the plugin's own files, because updates overwrite them.

functions.phpyour child theme
// Run your own code when miniOrange 2FA fires an action
add_action( 'mo2f_enterprise_plan_settings_action', function( $arg1, $post ) {
	// Your code runs here.
}, 10, 2 );

// Change a value miniOrange 2FA is about to use
add_filter( 'mo2f_is_lv_needed', function( $value ) {
	// Change $value here.
	return $value;
}, 10, 1 );

Parts of a name in {braces} are filled in at runtime (for example a post type or field ID). Choose Example on any hook for a ready-to-edit snippet.

All hooks

  • controllers/two-factor-page.php line 18 · used in 19 places
    /**
     * Including the file for frontend.
     */
    apply_filters( 'mo2f_is_lv_needed', false );
  • views/class-mo2f-setup-wizard.php line 556
    /**
     * Via that, you can change the grace period TTL.
     */
    apply_filters( 'mo2f_allow_grace_period_in_seconds', false );
  • handler/class-mo2f-2fa-settings-handler.php line 433 · used in 18 places
    do_action( 'mo2f_enterprise_plan_settings_action', 'save_custom_redirection_urls', $post );
  • controllers/twofa/class-mo-2f-ajax.php line 152 · used in 14 places
    apply_filters( 'mo2f_basic_plan_settings_filter', $twofactor_transactions->check_alluser_limit_exceeded( $mo2f_user->ID ), 'is_user_limit_exceeded', array() );
  • handler/class-mo2f-2fa-settings-handler.php line 197 · used in 11 places
    do_action( 'mo2f_all_inclusive_plan_settings_action', 'mo2f_save_login_form_settings', $_POST );
  • handler/class-mo2f-2fa-settings-handler.php line 189 · used in 7 places
    do_action( 'mo2f_basic_plan_settings_action', 'mo2f_save_custom_registration_form_settings', $_POST );
  • controllers/reports/remembereddevices.php line 11 · used in 3 places
    apply_filters( 'mo2f_enterprise_plan_settings_filter', array(), 'mo2f_get_all_users_rba_details', array() );
  • helper/class-mo2f-common-helper.php line 851 · used in 3 places
    apply_filters( 'mo2f_premium_common_helper', '', 'mo2f_get_backup_method_hidden_form', array( 'redirect_to' => $redirect_to, 'session_id_encrypt' => $session_id_encrypt, 'twofa_method' => $twofa_method, ) );
  • authenticate

    filter
    controllers/class-wpns-ajax.php line 148 · used in 2 places
    apply_filters( 'authenticate', null, $username, $password );
  • wp_login

    action
    handler/class-mo2f-main-handler.php line 725 · used in 2 places
    do_action( 'wp_login', $currentuser->user_login, $currentuser );
  • admin_head

    action
    views/class-mo2f-setup-wizard.php line 136
    do_action( 'admin_head' );
  • views/class-mo2f-setup-wizard.php line 135
    do_action( 'admin_print_scripts' );
  • views/class-mo2f-setup-wizard.php line 134
    do_action( 'admin_print_styles' );
  • controllers/myaccount/myaccount.php line 32
    do_action( 'mo2f_get_license_varification_screen' );
  • handler/twofa/class-miniorange-authentication.php line 203
    do_action( 'mo2f_network_create_db' );
  • helper/class-mo2f-common-helper.php line 386
    apply_filters( 'mo2f_otp_send_cooldown_seconds', 15 );
  • helper/class-mo2f-common-helper.php line 409
    apply_filters( 'mo2f_otp_send_daily_cap', 200 );
  • helper/class-mo2f-common-helper.php line 387
    apply_filters( 'mo2f_otp_send_hourly_cap', 5 );
  • handler/class-mo2f-main-handler.php line 711
    apply_filters( 'mo2f_page_protection_addon_filter', false, 'mo2f_page_protection_update_details', array( 'user_id' => $user_id ) );
  • handler/class-mo2f-2fa-settings-handler.php line 233
    do_action( 'mo2f_page_protection_addon_settings_action', 'mo2f_enable_page_protection', $_POST );
  • mo2f_rld

    action
    handler/class-mo2f-admin-action-handler.php line 184
    do_action( 'mo2f_rld' );
  • views/class-mo2f-setup-wizard.php line 65
    apply_filters( 'mo2f_wizard_default_steps', $wizard_steps );
  • plugin_locale

    filter
    miniorange_2_factor_settings.php line 262
    apply_filters( 'plugin_locale', $locale, 'miniorange-2-factor-authentication' );

Generated from miniOrange 2FA's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.

Can't find the right hook?

We can build the customisation for you. Describe what you need: