コード例 #1
0
ファイル: Guard.php プロジェクト: espinosa/Adldap2
 /**
  * {@inheritdoc}
  */
 public function bindUsingKerberos($kerberosCredentials)
 {
     $key = 'KRB5CCNAME=';
     putenv($key . $kerberosCredentials);
     if ($this->connection->bind(null, null, true) === false) {
         $error = $this->connection->getLastError();
         $message = "Bind to Active Directory failed. AD said: {$error}";
         throw new BindException($message);
     }
 }