index 7d4cc10a6e31cb875f9212fb22c1408e2f2febab..7768f2563998017301e02eb4e41fc2663ae54574 100644 (file)
<?php
-class servkolab extends plugin {
+class servkolab extends goService {
/* CLI vars */
var $cli_summary = "Manage server basic objects";
var $cli_description = "Some longer text\nfor help";
var $cli_parameters = array("eins"=>"Eins ist toll", "zwei"=>"Zwei ist noch besser");
- var $postfix_mydomain = "\$domain";//<<<<<<<<<<<<<
- var $postfix_mydestination = "\$domain";//<<<<<<<<<<<<<
- var $postfix_mynetworks = "127.0.0.1/8";//ok
- var $postfix_enable_virus_scan = "TRUE";//ok
+ var $postfix_mydomain = "";
+ var $cyrus_admins = "";
+ var $postfix_mydestination = "";
+ var $postfix_mynetworks = "127.0.0.1/8";
+ var $postfix_enable_virus_scan = "TRUE";
var $postfix_relayhost = "";
var $postfix_mxrelayenabled = true;
- var $postfix_allow_unauthenticated = "false";
- var $cyrus_quotawarn = "80";//ok
- var $kolabFreeBusyFuture = "1";// ok
- var $cyrus_admins = "TRUE";//<<<<<<<<<<<<<<<<
- var $cyrus_imap = "TRUE";//ok
- var $cyrus_pop3 = "TRUE";//ok
- var $cyrus_imaps = "TRUE";//ok
- var $cyrus_pop3s = "TRUE";//ok
- var $cyrus_sieve = "TRUE";//ok
- var $apache_allow_unauthenticated_fb = "TRUE";//<<<<<<<<<<<<
- var $proftpd_ftp = "TRUE";//pk
- var $apache_http = "TRUE";//ok
+ var $postfix_allow_unauthenticated = "FALSE";
+ var $cyrus_quotawarn = "80";
+ var $kolabFreeBusyFuture = "1";
+ var $k = "kolab";
+ var $cyrus_imap = "TRUE";
+ var $cyrus_pop3 = "FALSE";
+ var $cyrus_imaps = "TRUE";
+ var $cyrus_pop3s = "TRUE";
+ var $cyrus_sieve = "TRUE";
+ var $apache_allow_unauthenticated_fb = "TRUE";
+ var $proftpd_ftp = "FALSE";
+ var $apache_http = "TRUE";
var $kolabHost = array();
- var $added = false;
- var $remove = false;
- var $attributes = array("postfix_mydomain", "postfix_mydestination",
- "postfix_mynetworks", "postfix_enable_virus_scan","postfix_relayhost","postfix_allow_unauthenticated",
- "cyrus_admins", "cyrus_imap","kolabFreeBusyFuture",
- "cyrus_pop3", "cyrus_imaps", "cyrus_pop3s", "cyrus_sieve",
- "apache_allow_unauthenticated_fb", "proftpd_ftp",
- "apache_http", "cyrus_quotawarn", "kolabHost");
-
+ var $orig_cn = "";
+ var $view_logged = FALSE;
+
+ var $attributes = array("postfix_mydomain", "postfix_mydestination", "proftpd_ftp", "k",
+ "postfix_mynetworks", "postfix_enable_virus_scan", "postfix_relayhost", "apache_http",
+ "postfix_allow_unauthenticated", "cyrus_admins", "cyrus_imap","kolabFreeBusyFuture",
+ "cyrus_pop3", "cyrus_imaps", "cyrus_pop3s", "cyrus_sieve", "apache_allow_unauthenticated_fb",
+ "cyrus_quotawarn");
var $objectclasses = array("top", "kolab");
- function servkolab($config, $dn = NULL)
- {
-
+ /* Serverservice vars */
+ var $conflicts = array("goImapServer","goMailServer");
+ var $DisplayName = "Kolab mail service";
+ var $StatusFlag = "";
+ function servkolab(&$config, $dn = NULL, $parent= NULL)
+ {
/* Setting the hostname and tell this Plugin that we are the kolab extension*/
- $this->hostname= preg_replace('/^cn=([^,]+),.*$/', '\1', $dn);
- $this->dn = "k=kolab,".$config->current['BASE'];
-
+ $this->hostname = preg_replace('/^cn=([^,]+),.*$/', '\1', $dn);
+ $this->dn = "k=kolab,".$config->current['BASE'];
+
/* Load variables, if given*/
plugin::plugin($config, $this->dn);
$this->$val = $this->attrs["$name"][0];
}
}
-
+
+ /* Toggle relayhost */
+ $this->postfix_mxrelayenabled = preg_match('/^\[/', $this->postfix_relayhost);
+ $this->postfix_relayhost = preg_replace("/[\[\]]/","",$this->postfix_relayhost);
+
/* Is this Server a member of the Kolab extension or not ?*/
- if(in_array($this->hostname,$this->attrs['kolabHost'])) {
- $this->is_account=true;
- } else {
- $this->is_account=false; }
+ if(isset($this->attrs['kolabHost'])) {
+ $this->kolabHost= $this->attrs['kolabHost'];
+ unset($this->kolabHost['count']);
}
+ $this->is_account = false;
+ $this->initially_was_account = false;
+ foreach($this->kolabHost as $host){
+ if($this->hostname == $host){
+ $this->is_account = true;
+ $this->initially_was_account = true;
+ }
+ }
+ }
function execute()
{
+ /* Call parent execute */
+ plugin::execute();
- /* Fill templating stuff */
- $smarty = get_smarty();
- $display = "";
+ if($this->is_account && !$this->view_logged){
+ $this->view_logged = TRUE;
+ new log("view","server/".get_class($this),$this->dn);
+ }
- /* Lets get all Host that are member of the Kolab extension, but don't catch count */
- if(is_array($this->attrs['kolabHost']))
- {
- unset($this->attrs['kolabHost']['count']);
- $this->kolabHost = $this->attrs['kolabHost'];
- }
- else
- {
- $this->attrs['kolabHost']=array();
- $this->kolabHost = $this->attrs['kolabHost'];
- }
+ /***************
+ Variable initialisation
+ ***************/
- /* Tell the script the dn, we are using */
- $this->kolabdn = "k=kolab,".$this->config->current['BASE'];
-
- /* The Ldap link is needed to ask ldap some questions */
- $ldap = $this->config->get_ldap_link();
-
- /* Do we need to flip is_account state? */
- if (isset($_POST['modify_state'])) {
- $this->is_account = !$this->is_account;
-
-
- /*if we flip to true, we'll have to create a new account, so lets do that*/
- if($this->is_account==true)
- {
- /* Only add the given Hostname to the existing hosts*/
- $this->kolabHost[]=$this->hostname;
- $this->attrs['kolabHost'][]=$this->hostname;
- }
- else
- {
- /* First we have to find the Host we want to delete, take the index and delete em*/
- foreach($this->kolabHost as $key=>$host)
- {
- /* Delete only if the Host is the in the array*/
- if($host == $this->hostname)
- {
- unset($this->kolabHost[$key]);
- unset($this->attrs['kolabHost'][$key]);
- }
- }
- /* We deletet an Entry so we must reorder the index of the array */
- $tmp = $this->kolabHost;
- $this->kolabHost=array();
- $this->attrs['kolabHost']=array();
-
- /* reorder reorder ...*/
- foreach($tmp as $host){
- $this->kolabHost[]=$host;
- $this->attrs['kolabHost'][]=$host;
- }
- /* Tell Save that we want to delete someone*/
- $this->remove = true;
- }
+ $smarty = get_smarty();
+ $display = "";
+ $ldap = $this->config->get_ldap_link();
- }
- /* Check Relayhost and if we have MX lookup enabled*/
- if((isset($_POST['NewHost'])) || (isset($_POST['DelHost'])))
- {
- $this->postfix_mxrelayenabled = $_POST['RelayMxSupport'] ;
- }
- if($this->postfix_relayhost[0]=="[")
- {
- $this->postfix_mxrelayenabled=false;
- $this->postfix_relayhost = str_replace("[","",$this->postfix_relayhost);
- $this->postfix_relayhost = str_replace("]","",$this->postfix_relayhost);
- }
- if($this->postfix_mxrelayenabled) {
+
+ /* Assemble free/busy string */
+ $edit = sprintf('<input name="kolabFreeBusyFuture" value="%s" type="text" maxlength="3" size="4">',
+ $this->kolabFreeBusyFuture);
+ $fbfuture = sprintf(_("Include data from %s days in the past when creating free/busy lists"), $edit);
+
+ /* Assemble quota string */
+ $edit = sprintf('<input name="cyrus_quotawarn" value="%s" type="text" maxlength="3" size="4">',
+ $this->cyrus_quotawarn);
+ $quotastr = sprintf(_("Warn users when using more than %s%% of their mail quota"), $edit);
+
+ /***************
+ Assign informations to smarty
+ ***************/
+
+ /* Set relayhost and if we have MX lookup enabled*/
+ if($this->postfix_mxrelayenabled) {
$smarty->assign("RelayMxSupportCheck"," checked ");
- } else {
- $smarty->assign("RelayMxSupportCheck","");
- }
- /* Show tab dialog headers */
- if ($this->is_account) {
- /* call Add Acoount to add account */
- $display = $this->show_header(_("Remove Kolab extension"), _("This server has kolab features enabled. You can disable them by clicking below."));
} else {
- /* call remove Account */
- $display = $this->show_header(_("Add Kolab service"), _("This server has kolab features disabled. You can enable them by clicking below."));
- return ($display);
+ $smarty->assign("RelayMxSupportCheck","");
+ }
+
+ /* Set acls */
+ $tmp = $this->plInfo();
+ foreach($tmp['plProvidedAcls'] as $name => $translation){
+ $smarty->assign($name."ACL",$this->getacl($name));
}
/* Initialize all attributes, that were submitted */
foreach($this->attributes as $val)
{
- /* If theres a button pressed, we need to check all attributes */
- if ((isset($_POST['NewHost'])) || (isset($_POST['DelHost'])))
- {
- /* Set var to value or to zero */
- if (isset($_POST[$val]))
- {
-
- $this->$val = $_POST[$val];
- } else {
- $this->$val = 0;
- }
- }
/* Tell smarty which variables we are useing */
$smarty->assign($val, $this->$val);
- if (($this->$val != "FALSE") && (!empty($this->$val)))
+ if (($this->$val != "FALSE") && !empty($this->$val)){
$smarty->assign($val."Check", "checked");
- else
+ } else {
$smarty->assign($val."Check", "");
+ }
}
+ $smarty->assign("fbfuture", $fbfuture);
+ $smarty->assign("quotastr", $quotastr);
+
/* Load Template */
$display.=$smarty->fetch(get_template_path('servkolab.tpl', TRUE));
return ($display);
function remove_from_parent()
{
+
+ /* Remove status flag, it is not a memeber of
+ this->attributes, so ensure that it is deleted too */
+ if(!empty($this->StatusFlag)){
+ $this->attrs[$this->StatusFlag] = array();
+ }
+
+
+ /* Only walk through following code, if this host
+ was a member of the kolab hosts, else skip this */
+ if(!$this->initially_was_account){
+ return;
+ }
+
+ /* !!! Don't use "cn" in this function
+ hostname -> the initial name of the host
+ cn -> is the new name of the host, in case that it was renamed.
+ */
+
+ $ldap = $this->config->get_ldap_link();
+ $this->dn = "k=kolab,".$this->config->current['BASE'];
+
+ /* We can't simply remove the whole entry, it is possible that there are
+ some other hosts assigned to this object.
+ So, first of all check if we are the last host entry within the host
+ : Remove k=kolab entry
+ if we aren't alone, only remove host name from hosts entry and save */
+ /* Are we alone? Remove complete entry... */
+
+ /* Check if we are definitly in kolabHosts */
+ if(!in_array_ics($this->hostname,$this->kolabHost)) {
+ return;
+ }
+
+ /* Integration check, not translated because they can't pop up at all, only for debug */
+ if(count($this->kolabHost) == 0){
+ print_red("Server - Kolab tab : This is not possible, we can't remove an account which doesn't exists.");
+ return;
+ }
+ if(!isset($this->hostname) || (empty($this->hostname))){
+ print_red("The required attribute hostname seams to empty.");
+ }
+
+ /* Our hostname is in kolabHosts and there is a only one entry
+ = we are the last host entry, delete k=kolab entry */
+ if (count($this->kolabHost) == 1){
+
+ /* Remove complete entry */
+ $ldap->rmdir ($this->dn);
+ show_ldap_error($ldap->get_error(), sprintf(_("Removing host entry from system server/kolab with dn '%s' failed."),$this->dn));
+ } else {
+
+ /* Only modify kolabHost */
+ $hosts= array();
+ foreach ($this->kolabHost as $host){
+ if($host != $this->hostname){
+ $hosts[]= $host;
+ }
+ }
+ $attrs= array('kolabHost' => $hosts);
+ $ldap->cd($this->dn);
+ $this->cleanup();
+ $ldap->modify ($attrs);
+ show_ldap_error($ldap->get_error(), sprintf(_("Removing host entry from system server/kolab with dn '%s' failed."),$this->dn));
+ }
+
+ new log("remove","server/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+
+ /* Optionally execute a command after we're done */
+ $this->handle_post_events("remove");
}
function save_object()
{
- plugin::save_object();
+ if (isset($_POST['kolabtab'])){
+ plugin::save_object();
+
+
+ foreach($this->attributes as $attr){
+ if(($this->acl_is_writeable(preg_replace("/_/","",$attr))) && (isset($_POST[$attr]))){
+ $this->$attr = $_POST[$attr];
+ }
+ }
+
+ /* Save checkboxes */
+ foreach (array( "postfix_enable_virus_scan", "postfix_allow_unauthenticated",
+ "cyrus_imap", "cyrus_pop3", "cyrus_imaps",
+ "cyrus_pop3s", "cyrus_sieve", "apache_allow_unauthenticated_fb",
+ "proftpd_ftp", "apache_http") as $cb){
+
+ if($this->acl_is_writeable(preg_replace("/_/","",$cb))){
+ if (isset($_POST[$cb])){
+ $this->$cb= "TRUE";
+ } else {
+ $this->$cb= "FALSE";
+ }
+ }
+ }
+
+ /* Toggell relay check */
+ if($this->acl_is_writeable("postfixmxrelayenabled")){
+ $this->postfix_mxrelayenabled= isset($_POST['RelayMxSupport']);
+ }
+ }
+
}
function check()
{
- error_reporting(E_ALL);
- $message = array();
+ /* Call common method to give check the hook */
+ $message= plugin::check();
+
if(($this->kolabFreeBusyFuture=="")) {
- $message[] = _("Free/Busy settings -> Future days must be set.");
- }elseif((($this->kolabFreeBusyFuture=="")<0)){
- $message[] = _("Free/Busy settings -> Future days must be a positiv value.");
- }elseif(strcasecmp($this->kolabFreeBusyFuture,(int)$this->kolabFreeBusyFuture)){
- $message[] = _("Free/Busy settings -> Future days must be a value.");
+ $message[] = _("Future days in Free/Busy settings must be set.");
+ }elseif(!is_uid($this->kolabFreeBusyFuture) || $this->kolabFreeBusyFuture < 0){
+ $message[] = _("Future days in Free/Busy settings must be a positive value.");
}
-
+
if(!is_int((int)($this->cyrus_quotawarn))) {
- $message[] = _("Cyrus Quota settings -> The given Quota settings value must be a number.");
+ $message[] = _("The given Quota settings value must be a number.");
}elseif(!(($this->cyrus_quotawarn<=100)&&($this->cyrus_quotawarn>=0))){
- $message[] = _("Cyrus Quota settings -> Please choose a value between 1 and 100 for Quota settings.");
+ $message[] = _("Please choose a value between 1 and 100 for Quota settings.");
}elseif(strcasecmp($this->cyrus_quotawarn,(int)$this->cyrus_quotawarn)){
- $message[] = _("Cyrus Quota settings -> Future days must be a value.");
+ $message[] = _("Future days must be a value.");
}
- if(empty($this->postfix_mynetworks))
- {
- $message[] = _("SMTP privileged networks -> No value is given.");
- }
-
- if(empty($this->postfix_relayhost))
- {
- $message[] = _("SMTP smarthost/relayhost -> No value is given.");
+ if(empty($this->postfix_mynetworks)) {
+ $message[] = _("No SMTP privileged networks set.");
}
+ /*if(empty($this->postfix_relayhost)) {
+ $message[] = _("No SMTP smarthost/relayhost set.");
+ }
+ */
return ($message);
}
function save()
{
/* Set ldap connection */
- $ldap = $this->config->get_ldap_link();
-
- /* Open current dn*/
- $ldap->cd($this->dn);
+ $ldap = $this->config->get_ldap_link();
-
- /* Setup Attributes to save */
- $newattrs = array();
+ /* Open current dn*/
+ $this->dn = "k=kolab,".$this->config->current['BASE'];
- /* Set vars with correct - _ - */
- foreach($this->attributes as $key) {
- $key2 = str_replace("_", "-", $key);
- $newattrs[$key2] = $this->$key;
+ /* Adapt relayhost */
+ $this->postfix_relayhost= preg_replace('/[\[\]]/', '', $this->postfix_relayhost);
+ if ($this->postfix_mxrelayenabled && $this->postfix_relayhost != ""){
+ $this->postfix_relayhost= "[".$this->postfix_relayhost."]";
}
-
-
-
- /* Set bool vars */
- if ($newattrs['postfix-enable-virus-scan'] == 0)
- $newattrs['postfix-enable-virus-scan'] = "FALSE";
- else
- $newattrs['postfix-enable-virus-scan'] = "TRUE";
- if ($newattrs['cyrus-imap'] == 0)
- $newattrs['cyrus-imap'] = "FALSE";
- else
- $newattrs['cyrus-imap'] = "TRUE";
- if ($newattrs['cyrus-imaps'] == 0)
- $newattrs['cyrus-imaps'] = "FALSE";
- else
- $newattrs['cyrus-imaps'] = "TRUE";
- if ($newattrs['cyrus-pop3'] == 0)
- $newattrs['cyrus-pop3'] = "FALSE";
- else
- $newattrs['cyrus-pop3'] = "TRUE";
- if ($newattrs['cyrus-pop3s'] == 0)
- $newattrs['cyrus-pop3s'] = "FALSE";
- else
- $newattrs['cyrus-pop3s'] = "TRUE";
- if ($newattrs['cyrus-sieve'] == 0)
- $newattrs['cyrus-sieve'] = "FALSE";
- else
- $newattrs['cyrus-sieve'] = "TRUE";
- if ($newattrs['proftpd-ftp'] == 0)
- $newattrs['proftpd-ftp'] = "FALSE";
- else
- $newattrs['proftpd-ftp'] = "TRUE";
- if ($newattrs['apache-http'] == 0)
- $newattrs['apache-http'] = "FALSE";
- else
- $newattrs['apache-http'] = "TRUE";
- if ($newattrs['postfix-allow-unauthenticated'] == 0)
- $newattrs['postfix-allow-unauthenticated'] = "FALSE";
- else
- $newattrs['postfix-allow-unauthenticated'] = "TRUE";
- if ($newattrs['apache-allow-unauthenticated-fb'] == 0)
- $newattrs['apache-allow-unauthenticated-fb'] = "FALSE";
- else
- $newattrs['apache-allow-unauthenticated-fb'] = "TRUE";
-
-
- /* Reorder Host array, to get constant increasing index */
- $newattrs['kolabHost'] = array();
-
- /* Check Relayhost and if we have MX lookup enabled*/
- if(isset($_POST['RelayMxSupport']))
- $this->postfix_mxrelayenabled = true ;
- else
- $this->postfix_mxrelayenabled = false;
- if(!$this->postfix_mxrelayenabled)
- {
- $newattrs['postfix-relayhost']="[".$this->postfix_relayhost."]";
- }
- /* If we want to add someone or do only changes on the settings ...*/
- if(!$this->remove)
- {
- /* Get all Host known, that are member of the Kolab extension */
- $this->kolabHost = $this->attrs['kolabHost'];
-
- /* So, the Host is already member of the extension, so get all and do nothing */
- if(in_array($this->hostname,$this->kolabHost))
- {
- $newattrs['kolabHost']=$this->kolabHost;
- }
- /* So this is the first entry */
- elseif(empty($this->kolabHost))
- {
- /* Create an array an add the Host */
- $newattrs['kolabHost']=array();
- $newattrs['kolabHost'][]=$this->hostname;
- }
- /* Theres already an entry, but only in a string, */
- elseif(is_string($this->kolabHost))
- {
- $tmp = $this->kolabHost;
- $newattrs['kolabHost']=array();
- $newattrs['kolabHost'][]=$tmp;
- $newattrs['kolabHost'][]=$this->hostname;
- }
- /* Here we have already some entries */
- elseif(is_array($newattrs['kolabHost']))
- {
- /* Insert the new one*/
- foreach($this->kolabHost as $key=>$val) {
- if (is_int($key)) {
- $newattrs['kolabHost'][] = $val;
- }
+ /* Check if this server was renamed, in this case we have to remove old cn first*/
+ if($this->hostname != $this->cn){
+ $tmp = array();
+ if(in_array_ics($this->hostname,$this->kolabHost)){
+ foreach($this->kolabHost as $host){
+ if($host != $this->hostname){
+ $tmp[] = $host;
}
- $newattrs['kolabHost'][]= $this->hostname;
}
+ $this->kolabHost = $tmp;
}
- else
- {
- /* Here we want to delete an entry*/
- $newattrs['kolabHost']= $this->attrs['kolabHost'];
- }
- /* Save as following object ! */
- $this->kolabdn = "k=kolab,".$this->config->current['BASE'];
+ }
- /* If we already have an object like this one,
- we only need to modify the entry
- */
+ /* Add ourselves to the list of kolabHost's if needed */
+ if (!in_array_ics($this->cn,$this->kolabHost)){
+ $this->kolabHost[]= $this->cn;
+ }
- /* is this an empty extension, no host defined for it, than delet it */
- if(count($newattrs['kolabHost'])==0)
- {
- /* Delete the entry*/
- $ldap->cd ("k=kolab,".$this->config->current['BASE']);
- $ldap->rmdir("k=kolab,".$this->config->current['BASE']);
-
-
- }elseif ($ldap->dn_exists($this->kolabdn)) {
- /* Ok there is already an extension, so we only need to add the changes and the new Host, (if it was a new host)*/
- gosa_log("Modifying");
-
- /* unset all attributes we won't change*/
- unset($newattrs['cyrus-admins']);
- unset($newattrs['postfix-mydomain']);
- unset($newattrs['postfix-mydestination']);
-
- /* Update changes */
- $ldap->cd($this->kolabdn);
- $ldap->modify($newattrs);
+ /* Call parents save to prepare $this->attrs */
+ plugin::save();
+
+ /* Save or modify? */
+ $ldap->cat($this->dn, array('dn'));
+ if (!$ldap->fetch()){
+ $mode= "add";
} else {
+ $mode= "modify";
+ }
+
+ /* Do attribute conversion */
+ foreach ($this->attrs as $key => $value){
+ if (preg_match('/_/', $key)){
+ $old_key= $key;
+ $key= preg_replace('/_/', '-', $key);
+ $this->attrs[$key]= $value;
+ unset($this->attrs[$old_key]);
+ }
+ }
+ /* Add kolab hosts */
+ $this->attrs['kolabHost']= $this->kolabHost;
+
+ /* Perform LDAP action */
+ $ldap->cd($this->dn);
+ $this->cleanup();;
+ $ldap->$mode($this->attrs);
- /* We must create a new Entry */
- $newattrs['k'] = "kolab";
- $newattrs['uid'] = "freebusy";
- $newattrs['postfix-mydomain'] = "gonicus.de";
- $newattrs['postfix-mydestination'] = "\$mydomain";
- $newattrs['userPassword'] = "tester";
- $newattrs['objectClass'] = $this->objectclasses;
-
- /* For better reading / Objectclass was added at last */
- $newattrs = array_reverse ($newattrs);
-
- /* And add the entry*/
- $ldap->cd($this->kolabdn);
- $ldap->add($newattrs);
+ if($mode == "add"){
+ new log("create","server/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+ }else{
+ new log("modify","server/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
}
- /* show any errors */
- show_ldap_error($ldap->get_error());
-
+
+ show_ldap_error($ldap->get_error(), sprintf(_("Saving system server/kolab with dn '%s' failed."),$this->dn));
+
/* Optionally execute a command after we're done */
if ($this->initially_was_account == $this->is_account) {
if ($this->is_modified) {
- $this->handle_post_events("mofify");
+ $this->handle_post_events("modify");
}
} else {
$this->handle_post_events("add");
}
+ }
+
+ function getListEntry()
+ {
+ $fields = goService::getListEntry();
+ $fields['Message'] = _("Kolab mail service");
+ $fields['AllowEdit'] = true;
+ return($fields);
}
+
+ /* Return plugin informations for acl handling */
+ function plInfo()
+ {
+ return (array(
+ "plShortName" => _("Kolab"),
+ "plDescription" => _("Kolab mail service")." ("._("Services").")",
+ "plSelfModify" => FALSE,
+ "plDepends" => array(),
+ "plPriority" => 85,
+ "plSection" => array("administration"),
+ "plCategory" => array("server"),
+
+ "plProvidedAcls"=> array(
+ "postfixmydomain" => _("Postfix mydomain") ,
+ "postfixmydestination" => _("My destination") ,
+ "cyrusadmins" => _("Cyrus admins") ,
+ "proftpdftp" => _("FTP FreeBusy service") ,
+ "postfixmynetworks" => _("SMTP privileged networks") ,
+ "postfixenablevirusscan" => _("Enable virus scan") ,
+ "postfixrelayhost" => _("Relayhost") ,
+ "postfixmxrelayenabled" => _("Enable MX lookup for relayhost"),
+ "apachehttp" => _("HTTP FreeBusy service") ,
+ "apacheallowunauthenticatedfb" => _("Allow unauthenticated free busy"),
+ "postfixallowunauthenticated" => _("Accept Internet Mail") ,
+ "cyrusimap" => _("IMAP service") ,
+ "kolabFreeBusyFuture" => _("kolabFreeBusyFuture") ,
+ "cyruspop3" => _("POP3 service") ,
+ "cyrusimaps" => _("IMAP/SSL service") ,
+ "cyruspop3s" => _("POP3/SSL service") ,
+ "cyrussieve" => _("Sieve service") ,
+ "cyrusquotawarn" => _("Quota settings"))
+ ));
+ }
}
// vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: