You are here

class UserServiceProvider in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/user/src/UserServiceProvider.php \Drupal\user\UserServiceProvider

Swaps the original 'password' service in order to handle password hashing for user migrations that have passwords hashed to MD5.

Hierarchy

Expanded class hierarchy of UserServiceProvider

See also

\Drupal\migrate\MigratePassword

\Drupal\Core\Password\PhpassHashedPassword

File

core/modules/user/src/UserServiceProvider.php, line 20
Contains \Drupal\user\UserServiceProvider.

Namespace

Drupal\user
View source
class UserServiceProvider implements ServiceModifierInterface {

  /**
   * {@inheritdoc}
   */
  public function alter(ContainerBuilder $container) {
    $container
      ->setDefinition('password_original', $container
      ->getDefinition('password'));
    $container
      ->setDefinition('password', $container
      ->getDefinition('password_migrate'));
  }

}

Members

Namesort descending Modifiers Type Description Overrides
UserServiceProvider::alter public function Modifies existing service definitions. Overrides ServiceModifierInterface::alter