Joomla CMS  4.2.2
Documentation des API du CMS Joomla en version 4.2.2
Référence de la classe Mfa

Fonctions membres publiques statiques

static getMfaMethods ()
 
static canAddEditMethod (?User $user=null)
 
static canDeleteMethod (?User $user=null)
 

Attributs protégés statiques

static $allMFAs = null
 
static $isAdmin = null
 

Description détaillée

Helper functions for captive MFA handling

Depuis
4.2.0

Documentation des fonctions membres

◆ canAddEditMethod()

static canAddEditMethod ( ?User  $user = null)
static

Is the current user allowed to add/edit MFA methods for $user?

This is only allowed if I am adding / editing methods for myself.

If the target user is a member of any group disallowed to use MFA this will return false.

Paramètres
User | null$userThe user you want to know if we're allowed to edit
Renvoie
boolean
Exceptions
Exception
Depuis
4.2.0

Références $user, class, Factory\getApplication(), Factory\getContainer(), et ComponentHelper\getParams().

◆ canDeleteMethod()

static canDeleteMethod ( ?User  $user = null)
static

Is the current user allowed to delete MFA methods / disable MFA for $user?

This is allowed if:

  • The user being queried is the same as the logged-in user
  • The logged-in user is a Super User AND the queried user is NOT a Super User.

Note that Super Users can be edited by their own user only for security reasons. If a Super User gets locked out they must use the Backup Codes to regain access. If that's not possible, they will need to delete their records from the #__user_mfa table.

Paramètres
User | null$userThe user being queried.
Renvoie
boolean
Exceptions
Exception
Depuis
4.2.0

Références $user, class, Factory\getApplication(), et Factory\getContainer().

◆ getMfaMethods()

static getMfaMethods ( )
static

Get a list of all of the MFA Methods

Renvoie
MethodDescriptor[]
Depuis
4.2.0

Références $method, $temp, Factory\getApplication(), et PluginHelper\importPlugin().

Documentation des champs

◆ $allMFAs

$allMFAs = null
staticprotected

◆ $isAdmin

$isAdmin = null
staticprotected

La documentation de cette classe a été générée à partir du fichier suivant :