예제 #1
0
파일: Drupal.php 프로젝트: hugutux/booked
 /**
  * Called after Validate returns true
  * @see IAuthorization::Login()
  */
 public function Login($username, $loginContext)
 {
     // Synchronize account information from Drupal
     //The only thing Drupal really has is the user's e-mail address. Could syncronize that?
     //MPinnegar - I assume I don't do anything with persist, that's only used by another wrapper?
     // Always call decorated Authentication so proper Booked Scheduler functionality is executed
     return $this->authToDecorate->Login($username, $loginContext);
 }
예제 #2
0
 public function Login($username, $loginContext)
 {
     $user = $this->GetShibbolethUser();
     $registration = $this->GetRegistration();
     // auto-provision new user accounts
     // or update existing user accounts with the attributes passed in from shibboleth
     $registration->Synchronize(new AuthenticatedUser($user->GetUsername(), $user->GetEmailAddress(), $user->GetFirstName(), $user->GetLastName(), null, Configuration::Instance()->GetKey(ConfigKeys::LANGUAGE), Configuration::Instance()->GetDefaultTimezone(), $user->GetPhone(), null, null));
     return $this->authToDecorate->Login($user->GetUsername(), $loginContext);
 }
예제 #3
0
 public function Login($username, $loginContext)
 {
     Log::Debug('WordPress - Login() in with username: %s', $username);
     if ($this->UserExists()) {
         Log::Debug('Running WordPress user synchronization for username: %s', $username);
         $this->Synchronize();
     } else {
         Log::Debug('Skipping WordPress user synchronization, user not loaded');
     }
     return $this->authToDecorate->Login($username, $loginContext);
 }
예제 #4
0
파일: Saml.php 프로젝트: Trideon/gigolo
 public function Login($username, $loginContext)
 {
     $this->username = $username;
     if ($this->username == null) {
         $this->username = $this->user->GetUserName();
     }
     if ($this->SamlUserExists()) {
         $this->Synchronize($this->username);
     }
     return $this->authToDecorate->Login($this->username, $loginContext);
 }
예제 #5
0
 public function Login($username, $loginContext)
 {
     $username = $this->CleanUsername($username);
     Log::Debug('ActiveDirectory - Login() in with username: %s', $username);
     if ($this->LdapUserExists()) {
         Log::Debug('Running ActiveDirectory user synchronization for username: %s, Attributes: %s', $username, $this->user->__toString());
         $this->Synchronize($username);
     } else {
         Log::Debug('Skipping ActiveDirectory user synchronization, user not loaded');
     }
     return $this->authToDecorate->Login($username, $loginContext);
 }
예제 #6
0
파일: Ldap.php 프로젝트: hugutux/booked
 public function Login($username, $loginContext)
 {
     $username = $this->CleanUsername($username);
     if ($this->LdapUserExists()) {
         $this->Synchronize($username);
     }
     $repo = new UserRepository();
     $user = $repo->LoadByUsername($username);
     $user->Deactivate();
     $user->Activate();
     $repo->Update($user);
     return $this->authToDecorate->Login($username, $loginContext);
 }
예제 #7
0
 public function Login($username, $loginContext)
 {
     if ($this->AreCredentialsKnown()) {
         $username = ServiceLocator::GetServer()->GetHeader('AUTH_USER');
         Log::Debug('ActiveDirectory Login trying to load details for authenticated user: %s', $username);
     }
     $username = $this->CleanUsername($username);
     Log::Debug('ActiveDirectory - Login() in with username: %s', $username);
     if ($this->LdapUserExists()) {
         Log::Debug('Running ActiveDirectory user synchronization for username: %s, Attributes: %s', $username, $this->user->__toString());
         $this->Synchronize($username);
     } else {
         Log::Debug('Skipping ActiveDirectory user synchronization, user not loaded');
     }
     return $this->authToDecorate->Login($username, $loginContext);
 }
예제 #8
0
파일: Drupal.php 프로젝트: Trideon/gigolo
 /**
  * Called after Validate returns true
  * @see IAuthorization::Login()
  */
 public function Login($username, $loginContext)
 {
     $account = $this->GetDrupalAccount($username);
     $this->GetRegistration()->Synchronize(new AuthenticatedUser($account->name, $account->mail, '', '', '', $loginContext->GetData()->Language, $account->timezone, null, null, null));
     return $this->authToDecorate->Login($username, $loginContext);
 }