summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 0d060a1)
raw | patch | inline | side by side (parent: 0d060a1)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Fri, 6 Nov 2009 15:52:14 +0000 (15:52 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Fri, 6 Nov 2009 15:52:14 +0000 (15:52 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14780 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/mit-krb5/admin/systems/services/kerberos/class_krb_host_keys.inc | patch | blob | history |
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 350da6ec18cb2433a03792b7c279e1f6adaafe98..dbc30448586743ed9519db5bc3cbdb679a835539 100644 (file)
private $server_list = array();
private $last_list = array(); // The last array created for the smarty template
- private $init_namingAttr = "";
private $namingAttr = "";
private $is_service_key = FALSE;
private $confirm_box = NULL;
trigger_error("Cannot initialize kerberos key service, invalid parent object given (Paramter 2).".
" Should be of class 'plugin' with accessible class member variable 'cn'.");
}else{
- $this->init_namingAttr = $this->namingAttr = $this->object->cn;
+
+ // Check if we've enabled the DNS settings and assemble an according entry
+ $this->namingAttr= $this->getNamingAttr();
$this->init();
}
}
+
+ function getNamingAttr()
+ {
+ // Do we have DNS settings?
+ if (empty($this->object->netConfigDNS->dnsEntry['zoneName'])) {
+
+ // no... use systems cn
+ return $this->object->cn;
+
+ } else {
+
+ // yes... assemble new naming attribute
+ return $this->object->cn.".".preg_replace('/^.*\/(.*)\.$/', '$1', $this->object->netConfigDNS->dnsEntry['zoneName']);
+ }
+
+ }
+
+
/*! \brief Reloads the list of available principals.
*/
/* Update the naming attribute.
*/
- $this->namingAttr = $this->object->cn;
+ $this->namingAttr= $this->getNamingAttr();
/* Create password handle, it has already a working principal parsing
*/
/* Check if naming context has changed,
in this case ask user if he wants to update the keys.
*/
- if($this->object->cn != $this->namingAttr){
+
+ if($this->getNamingAttr() != $this->namingAttr){
/* The confirm dialog was shown. Check if OK was pressed.
*/