Skip to content

Commit

Permalink
Revert "MFA: ignore non html requests (#38492)" (#38529)
Browse files Browse the repository at this point in the history
This reverts commit 7ebca92.
  • Loading branch information
roland-d committed Aug 18, 2022
1 parent 152ebcc commit 19f68b2
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions libraries/src/Application/MultiFactorAuthenticationHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -293,9 +293,14 @@ private function needsMultiFactorAuthenticationRedirection(): bool
return false;
}

// Ignore non HTML Requests
if ($this->input->getCmd('format', 'html') !== 'html') {
return false;
// Allow the statistics plugin to run
if ($isAdmin && $option === 'com_ajax' && $task === '') {
$group = strtolower($this->input->getCmd('group', ''));
$plugin = strtolower($this->input->getCmd('plugin', ''));

if ($group === 'system' && $plugin === 'sendstats') {
return false;
}
}

return true;
Expand Down

0 comments on commit 19f68b2

Please sign in to comment.