SpecialRemoveCredentials.php 642 B

123456789101112131415161718192021222324252627
  1. <?php
  2. use MediaWiki\Auth\AuthManager;
  3. /**
  4. * Special change to remove credentials (such as a two-factor token).
  5. */
  6. class SpecialRemoveCredentials extends SpecialChangeCredentials {
  7. protected static $allowedActions = [ AuthManager::ACTION_REMOVE ];
  8. protected static $messagePrefix = 'removecredentials';
  9. protected static $loadUserData = false;
  10. public function __construct() {
  11. parent::__construct( 'RemoveCredentials' );
  12. }
  13. protected function getDefaultAction( $subPage ) {
  14. return AuthManager::ACTION_REMOVE;
  15. }
  16. protected function getRequestBlacklist() {
  17. return $this->getConfig()->get( 'RemoveCredentialsBlacklist' );
  18. }
  19. }