From: hickert Date: Thu, 4 Dec 2008 08:00:59 +0000 (+0000) Subject: Updated krb5 password method and host key classes. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=cd632fe8e4f58509a3dfdc9cfe483e84baa6c65e;p=gosa.git Updated krb5 password method and host key classes. -Do not initialize classes if gosaSupportUri is not configured. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@13158 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_krb_host_keys.inc b/gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_krb_host_keys.inc index 21f914eec..350da6ec1 100644 --- a/gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_krb_host_keys.inc +++ b/gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_krb_host_keys.inc @@ -111,6 +111,9 @@ class krbHostKeys extends plugin /* Create password handle, it has already a working principal parsing */ $this->pwd_handle = new passwordMethodMIT($this->config); + if(!$this->pwd_handle->is_available()){ + return; + } /* Check class initialation */ if(!($this->pwd_handle instanceOf passwordMethodMIT)){ diff --git a/gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_password-methods-MIT.inc b/gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_password-methods-MIT.inc index ccf708244..9c9218a68 100644 --- a/gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_password-methods-MIT.inc +++ b/gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_password-methods-MIT.inc @@ -111,7 +111,7 @@ class passwordMethodMIT extends passwordMethod /* No config object given, this may be the case if there is only a is_available() request triggered. */ - if(!is_object($config)){ + if(!is_object($config) || !$this->is_available()){ return; } @@ -337,8 +337,9 @@ class passwordMethodMIT extends passwordMethod */ public function is_available() { + $o = new gosaSupportDaemon(FALSE); - if(count($this->server_list) && $o->connect()){ + if(count($this->server_list) && $o->connect() && $o->is_configured()){ return TRUE; } return(FALSE);