Code

Updated krb_host_key class.
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 3 Jul 2008 07:12:25 +0000 (07:12 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 3 Jul 2008 07:12:25 +0000 (07:12 +0000)
- Do not display key settings, if we couldn't establish a connection to the si server.

git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11518 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_krb_host_keys.inc

index 46c8150f5005685390f39117757a814f0d448b1a..f2cd36b7d4aac2224f074be4842797c74511b5c3 100644 (file)
@@ -109,6 +109,12 @@ class krb_host_keys extends plugin
       /* Create password handle, it has already a working principal parsing 
        */
       $this->pwd_handle = new passwordMethodMIT($this->config);
+  
+      /* Check class initialation */
+      if(!($this->pwd_handle instanceOf passwordMethodMIT)){
+        trigger_error("Could not initialize kerberos password method 'passwordMethodMIT'.");
+        return;
+      }
       $this->pwd_handle->clear_cache();
 
       /* Get a list of all kerberos servers, defined in ldap
@@ -143,7 +149,7 @@ class krb_host_keys extends plugin
         }
       }
   
-      if(isset($this->server_list) && count($this->server_list)){
+      if(isset($this->server_list) && count($this->server_list) && $this->o_queue->is_connected()){
         $this->kerberos_support = TRUE;
       }
     }