UsernamePassword.php in DRD Agent 4.0.x
Same filename and directory in other branches
Namespace
Drupal\drd_agent\Agent\AuthFile
src/Agent/Auth/UsernamePassword.phpView source
<?php
namespace Drupal\drd_agent\Agent\Auth;
/**
* Implements the UsernamePassword authentication method.
*/
class UsernamePassword extends Base {
/**
* {@inheritdoc}
*/
public function validate(array $settings) : bool {
if ($this->currentUser
->isAuthenticated()) {
return TRUE;
}
return $this->userAuth
->authenticate($settings['username'], $settings['password']);
}
}
Classes
Name | Description |
---|---|
UsernamePassword | Implements the UsernamePassword authentication method. |