Compare commits

..

29 Commits

Author SHA1 Message Date
Florian Aders (EleRas)
c1e083c8b2 Tagging 0.9.24
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-10-04 19:03:45 +02:00
Florian Aders (EleRas)
70a077da48 fixed resourcebars, thx philnate, fixes #787
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-10-04 11:21:38 +02:00
Christoph Burchert (Chb)
c5fb8bee6b Enables to delete customers with already deleted databases (thanks to crazy4chrissi), fixes #872
Signed-off-by: Christoph Burchert (Chb) <derchb@froxlor.org>
2011-09-26 04:12:01 +02:00
Christoph Burchert (Chb)
418990e271 Fixes fix
Signed-off-by: Christoph Burchert (Chb) <derchb@froxlor.org>
2011-09-26 03:47:12 +02:00
Christoph Burchert (Chb)
93ab8964f1 Hide backup FTP password (thanks to monotek), fixes #762
Signed-off-by: Christoph Burchert (Chb) <derchb@froxlor.org>
2011-09-26 03:43:37 +02:00
Florian Aders (EleRas)
fd599da07e Tagging 0.9.24-rc1
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-19 18:32:55 +02:00
Andreas Burchert (scarya)
369df7af62 Fixes wrong location declaration for nginx, fixes #749
Thanks to altmir
2011-09-19 11:21:11 +02:00
Andreas Burchert (scarya)
bb01dd0d93 Fixes a small syntax error. 2011-09-19 11:17:15 +02:00
Andreas Burchert (scarya)
84f00a2519 Fixes malformed priority in ticket archive search, fixes #714
Note: swedish could not be fixed and my swedish is way to bad to do it on my own
Thanks to philnate
2011-09-19 11:11:26 +02:00
Andreas Burchert (scarya)
8e07768996 Fixes 'unknown user' for disabled accounts (traffic overview), fixes #791
Thanks to monotek
2011-09-19 11:07:09 +02:00
Andreas Burchert (scarya)
9b12025c9f Prevents froxlor from creating a vhost (apache only) for relay mail domains, fixes #848
Thanks to sinuxwave
2011-09-19 11:00:50 +02:00
Andreas Burchert (scarya)
14f9344c50 Prevent empty 'ServerName', fixes #870
Thanks to h4cc
2011-09-19 10:56:27 +02:00
Andreas Burchert (scarya)
af430f9946 modernized bash init-scripts, fixes #889
Thanks to arnoldB.
2011-09-19 10:50:23 +02:00
Christoph Burchert (Chb)
992702870c Fixed customer's backup directory (thanks to monotek and arnoldB), fixes #859
Signed-off-by: Christoph Burchert (Chb) <derchb@froxlor.org>
2011-09-15 15:03:55 +02:00
Florian Aders (EleRas)
642cd3da9d Applied patch to fix IPv6 in bind, fixes #799, thx frennkie
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-09 13:57:59 +02:00
Florian Aders (EleRas)
5d2d1ffa1a Improve showing of MySQL - databasesize, refs #834, thx arnoldB
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-09 10:33:33 +02:00
Florian Aders (EleRas)
19bbecb535 Shorten the megabytes, refs #834
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-08 15:05:18 +02:00
Florian Aders (EleRas)
e636e6eb39 Show database-size in database-overview, fixes #834
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-08 14:46:01 +02:00
Florian Aders (EleRas)
86ac4708f0 Adding a favicon, fixes #875
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-08 12:49:17 +02:00
Florian Aders (EleRas)
f49ac9e193 fixing mysql-virtual_sender_permissions.cf regarding postfix-policy in Froxlor, fixes #879
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-08 08:44:08 +02:00
Florian Aders (EleRas)
f0d9db420a fixing mysql-virtual_mailbox_maps.cf regarding postfix-policy in Froxlor, refs #879
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-08 08:40:21 +02:00
Florian Aders (EleRas)
526dbbd68e fixing mysql-virtual_alias_maps.cf and mysql-virtual_mailbox_domains.cf regarding postfix-policy in Froxlor, refs #879
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-08 08:37:07 +02:00
Christoph Burchert (Chb)
9a05a71f6b Fixed typo (thanks to frontline), fixes #880
Signed-off-by: Christoph Burchert (Chb) <derchb@froxlor.org>
2011-09-07 19:29:58 +02:00
Florian Aders (EleRas)
e4f3af5d4b fixed htmleating in ticketsystem, thx philnate, fixes #727
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-06 11:02:47 +02:00
Florian Aders (EleRas)
3a7b7c1300 Improved description of values in admin panel, thx philnate, fixes #743
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-06 08:15:44 +02:00
Florian Aders (EleRas)
cdea6cecfb Fixed version in updater for logrotate, refs #16
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-09-05 19:38:39 +02:00
Christoph Burchert (Chb)
c36a7bf22b Add logrotate support, fixes #16 (thanks to monotek!)
Signed-off-by: Christoph Burchert (Chb) <derchb@froxlor.org>
2011-09-05 14:56:50 +02:00
Christoph Burchert (Chb)
ca2a8c9907 Security fix: unescaped commandline argument (thanks to Bernhard Czech (sinuswave))
Signed-off-by: Christoph Burchert (Chb) <derchb@froxlor.org>
2011-09-05 14:31:03 +02:00
Florian Aders (EleRas)
4914fc640a Tagging 0.9.23
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
2011-08-22 17:26:11 +02:00
100 changed files with 615 additions and 241 deletions

View File

@@ -59,6 +59,7 @@ return array(
'type' => 'string', 'type' => 'string',
'default' => '', 'default' => '',
'save_method' => 'storeSettingHostname', 'save_method' => 'storeSettingHostname',
'plausibility_check_method' => 'checkHostname',
), ),
'system_froxlordirectlyviahostname' => array( 'system_froxlordirectlyviahostname' => array(
'label' => $lng['serversettings']['froxlordirectlyviahostname'], 'label' => $lng['serversettings']['froxlordirectlyviahostname'],
@@ -164,4 +165,4 @@ return array(
), ),
); );
?> ?>

View File

@@ -133,7 +133,7 @@ return array(
'type' => 'option', 'type' => 'option',
'default' => 2, 'default' => 2,
'option_mode' => 'one', 'option_mode' => 'one',
'option_options' => array(1 => $lng['ticket']['unf_high'], 2 => $lng['ticket']['unf_normal'], 3 => $lng['ticket']['unf_low']), 'option_options' => array(1 => $lng['ticket']['high'], 2 => $lng['ticket']['normal'], 3 => $lng['ticket']['low']),
'save_method' => 'storeSettingField', 'save_method' => 'storeSettingField',
), ),
), ),
@@ -141,4 +141,4 @@ return array(
) )
); );
?> ?>

View File

@@ -38,7 +38,7 @@ return array(
'type' => 'string', 'type' => 'string',
'string_type' => 'dir', 'string_type' => 'dir',
'default' => '/var/customers/backups/', 'default' => '/var/customers/backups/',
'string_regexp' => '/^/.*/$/', 'string_regexp' => '^/.*/$',
'save_method' => 'storeSettingField', 'save_method' => 'storeSettingField',
), ),
'backup_mysqldump_path' => array( 'backup_mysqldump_path' => array(
@@ -96,7 +96,7 @@ return array(
'label' => $lng['serversettings']['backup_ftp_pass'], 'label' => $lng['serversettings']['backup_ftp_pass'],
'settinggroup' => 'system', 'settinggroup' => 'system',
'varname' => 'backup_ftp_pass', 'varname' => 'backup_ftp_pass',
'type' => 'string', 'type' => 'hiddenstring',
'default' => '', 'default' => '',
'save_method' => 'storeSettingField', 'save_method' => 'storeSettingField',
), ),

View File

@@ -0,0 +1,67 @@
<?php
/**
* This file is part of the Froxlor project.
* Copyright (c) 2003-2009 the SysCP Team (see authors).
* Copyright (c) 2010 the Froxlor Team (see authors).
*
* For the full copyright and license information, please view the COPYING
* file that was distributed with this source code. You can also view the
* COPYING file online at http://files.froxlor.org/misc/COPYING.txt
*
* @copyright (c) the authors
* @author Florian Lippert <flo@syscp.org> (2003-2009)
* @author Froxlor team <team@froxlor.org> (2010-)
* @license GPLv2 http://files.froxlor.org/misc/COPYING.txt
* @package Settings
*
*/
return array(
'groups' => array(
'logrotate' => array(
'title' => $lng['logrotate'],
'fields' => array(
'logrotate_enabled' => array(
'label' => $lng['logrotate_enabled'],
'settinggroup' => 'system',
'varname' => 'logrotate_enabled',
'type' => 'bool',
'default' => false,
'save_method' => 'storeSettingField',
'overview_option' => true
),
'logrotate_binary' => array(
'label' => $lng['logrotate_binary'],
'settinggroup' => 'system',
'varname' => 'logrotate_binary',
'type' => 'string',
'default' => '/usr/sbin/logrotate',
'save_method' => 'storeSettingField',
'overview_option' => false
),
'logrotate_interval' => array(
'label' => $lng['logrotate_interval'],
'settinggroup' => 'system',
'varname' => 'logrotate_interval',
'type' => 'option',
'default' => 'weekly',
'option_mode' => 'one',
'option_options' => array('daily' => 'Daily', 'weekly' => 'Weekly', 'monthly' => 'Monthly'),
'save_method' => 'storeSettingField',
'overview_option' => false
),
'logrotate_keep' => array(
'label' => $lng['logrotate_keep'],
'settinggroup' => 'system',
'varname' => 'logrotate_keep',
'type' => 'string',
'default' => '4',
'save_method' => 'storeSettingField',
'overview_option' => false
),
),
),
),
);
?>

View File

@@ -117,12 +117,21 @@ if($page == 'customers'
/** /**
* percent-values for progressbar * percent-values for progressbar
*/ */
//For Disk usage
if ($row['diskspace'] > 0) { if ($row['diskspace'] > 0) {
$percent = round(($row['diskspace_used']*100)/$row['diskspace'], 2); $disk_percent = round(($row['diskspace_used']*100)/$row['diskspace'], 2);
$doublepercent = round($percent*2, 2); $disk_doublepercent = round($disk_percent*2, 2);
} else { } else {
$percent = 0; $disk_percent = 0;
$doublepercent = 0; $disk_doublepercent = 0;
}
if ($row['traffic'] > 0) {
$traffic_percent = round(($row['traffic_used']*100)/$row['traffic'], 2);
$traffic_doublepercent = round($traffic_percent*2, 2);
} else {
$traffic_percent = 0;
$traffic_doublepercent = 0;
} }
$column_style = ''; $column_style = '';
@@ -219,8 +228,8 @@ if($page == 'customers'
foreach(array_unique(explode(',', $settings['system']['mysql_access_host'])) as $mysql_access_host) foreach(array_unique(explode(',', $settings['system']['mysql_access_host'])) as $mysql_access_host)
{ {
$mysql_access_host = trim($mysql_access_host); $mysql_access_host = trim($mysql_access_host);
$db_root->query('REVOKE ALL PRIVILEGES ON * . * FROM `' . $db_root->escape($row_database['databasename']) . '`@`' . $db_root->escape($mysql_access_host) . '`'); $db_root->query('REVOKE ALL PRIVILEGES ON * . * FROM `' . $db_root->escape($row_database['databasename']) . '`@`' . $db_root->escape($mysql_access_host) . '`',false,true);
$db_root->query('REVOKE ALL PRIVILEGES ON `' . str_replace('_', '\_', $db_root->escape($row_database['databasename'])) . '` . * FROM `' . $db_root->escape($row_database['databasename']) . '`@`' . $db_root->escape($mysql_access_host) . '`'); $db_root->query('REVOKE ALL PRIVILEGES ON `' . str_replace('_', '\_', $db_root->escape($row_database['databasename'])) . '` . * FROM `' . $db_root->escape($row_database['databasename']) . '`@`' . $db_root->escape($mysql_access_host) . '`',false,true);
$db_root->query('DELETE FROM `mysql`.`user` WHERE `User` = "' . $db_root->escape($row_database['databasename']) . '" AND `Host` = "' . $db_root->escape($mysql_access_host) . '"'); $db_root->query('DELETE FROM `mysql`.`user` WHERE `User` = "' . $db_root->escape($row_database['databasename']) . '" AND `Host` = "' . $db_root->escape($mysql_access_host) . '"');
} }

View File

@@ -1054,7 +1054,8 @@ if($page == 'domains'
|| $mod_fcgid_maxrequests != $result['mod_fcgid_maxrequests'] || $mod_fcgid_maxrequests != $result['mod_fcgid_maxrequests']
|| $specialsettings != $result['specialsettings'] || $specialsettings != $result['specialsettings']
|| $aliasdomain != $result['aliasdomain'] || $aliasdomain != $result['aliasdomain']
|| $issubof != $result['ismainbutsubto']) || $issubof != $result['ismainbutsubto']
|| $email_only != $result['email_only'])
{ {
inserttask('1'); inserttask('1');
} }

View File

@@ -170,7 +170,7 @@ if($page == 'tickets'
$newticket->Set('priority', validate($_POST['priority'], 'priority'), true, false); $newticket->Set('priority', validate($_POST['priority'], 'priority'), true, false);
$newticket->Set('category', validate($_POST['category'], 'category'), true, false); $newticket->Set('category', validate($_POST['category'], 'category'), true, false);
$newticket->Set('customer', (int)$_POST['customer'], true, false); $newticket->Set('customer', (int)$_POST['customer'], true, false);
$newticket->Set('message', validate(str_replace("\r\n", "\n", $_POST['message']), 'message', '/^[^\0]*$/'), true, false); $newticket->Set('message', validate(htmlentities(str_replace("\r\n", "\n", $_POST['message'])), 'message', '/^[^\0]*$/'), true, false);
if($newticket->Get('subject') == null) if($newticket->Get('subject') == null)
{ {
@@ -224,9 +224,9 @@ if($page == 'tickets'
$customers.= makeoption(getCorrectFullUserDetails($row_customer) . ' (' . $row_customer['loginname'] . ')', $row_customer['customerid']); $customers.= makeoption(getCorrectFullUserDetails($row_customer) . ' (' . $row_customer['loginname'] . ')', $row_customer['customerid']);
} }
$priorities = makeoption($lng['ticket']['unf_high'], '1', $settings['ticket']['default_priority']); $priorities = makeoption($lng['ticket']['high'], '1', $settings['ticket']['default_priority']);
$priorities.= makeoption($lng['ticket']['unf_normal'], '2', $settings['ticket']['default_priority']); $priorities.= makeoption($lng['ticket']['normal'], '2', $settings['ticket']['default_priority']);
$priorities.= makeoption($lng['ticket']['unf_low'], '3', $settings['ticket']['default_priority']); $priorities.= makeoption($lng['ticket']['low'], '3', $settings['ticket']['default_priority']);
$ticket_new_data = include_once dirname(__FILE__).'/lib/formfields/admin/tickets/formfield.ticket_new.php'; $ticket_new_data = include_once dirname(__FILE__).'/lib/formfields/admin/tickets/formfield.ticket_new.php';
$ticket_new_form = htmlform::genHTMLForm($ticket_new_data); $ticket_new_form = htmlform::genHTMLForm($ticket_new_data);
@@ -251,7 +251,7 @@ if($page == 'tickets'
$replyticket = ticket::getInstanceOf($userinfo, $db, $settings, -1); $replyticket = ticket::getInstanceOf($userinfo, $db, $settings, -1);
$replyticket->Set('subject', validate($_POST['subject'], 'subject'), true, false); $replyticket->Set('subject', validate($_POST['subject'], 'subject'), true, false);
$replyticket->Set('priority', validate($_POST['priority'], 'priority'), true, false); $replyticket->Set('priority', validate($_POST['priority'], 'priority'), true, false);
$replyticket->Set('message', validate(str_replace("\r\n", "\n", $_POST['message']), 'message', '/^[^\0]*$/'), true, false); $replyticket->Set('message', validate(htmlentities(str_replace("\r\n", "\n", $_POST['message'])), 'message', '/^[^\0]*$/'), true, false);
if($replyticket->Get('message') == null) if($replyticket->Get('message') == null)
{ {
@@ -673,6 +673,16 @@ elseif($page == 'archive'
} }
$tickets_count++; $tickets_count++;
switch ($ticket['priority'])
{
case 1: $ticket['display'] = 'high';
break;
case 2: $ticket['display'] = 'normal';
break;
case 3: $ticket['display'] = 'low';
break;
default: $ticket['display'] = 'unknown';
}
$ticket['priority'] = ticket::getPriorityText($lng, $ticket['priority']); $ticket['priority'] = ticket::getPriorityText($lng, $ticket['priority']);
if($ticket['lastreplier'] == '1') if($ticket['lastreplier'] == '1')
@@ -688,9 +698,7 @@ elseif($page == 'archive'
{ {
$ticket['subject'] = substr($ticket['subject'], 0, 17) . '...'; $ticket['subject'] = substr($ticket['subject'], 0, 17) . '...';
} }
$ticket = htmlentities_array($ticket); $ticket = htmlentities_array($ticket);
eval("\$tickets.=\"" . getTemplate("tickets/archived_tickets") . "\";"); eval("\$tickets.=\"" . getTemplate("tickets/archived_tickets") . "\";");
$count++; $count++;
$_cid = $ticket['customerid']; $_cid = $ticket['customerid'];
@@ -733,9 +741,9 @@ elseif($page == 'archive'
} }
} }
$priorities_options = makecheckbox('priority1', $lng['ticket']['unf_high'], '1'); $priorities_options = makecheckbox('priority1', $lng['ticket']['high'], '1');
$priorities_options.= makecheckbox('priority2', $lng['ticket']['unf_normal'], '2'); $priorities_options.= makecheckbox('priority2', $lng['ticket']['normal'], '2');
$priorities_options.= makecheckbox('priority3', $lng['ticket']['unf_low'], '3'); $priorities_options.= makecheckbox('priority3', $lng['ticket']['low'], '3');
$category_options = ''; $category_options = '';
$ccount = 0; $ccount = 0;
$result = $db->query('SELECT * FROM `' . TABLE_PANEL_TICKET_CATS . '` ORDER BY `name` ASC'); $result = $db->query('SELECT * FROM `' . TABLE_PANEL_TICKET_CATS . '` ORDER BY `name` ASC');

View File

@@ -62,17 +62,24 @@ elseif($page == 'mysqls')
$count = 0; $count = 0;
$mysqls = ''; $mysqls = '';
// Begin root-session
$db_root = new db($sql_root[0]['host'], $sql_root[0]['user'], $sql_root[0]['password'], '');
unset($db_root->password);
while($row = $db->fetch_array($result)) while($row = $db->fetch_array($result))
{ {
if($paging->checkDisplay($i)) if($paging->checkDisplay($i))
{ {
$row = htmlentities_array($row); $row = htmlentities_array($row);
$mbdata = $db_root->query_first("SELECT SUM( data_length + index_length) / 1024 / 1024 'MB' FROM information_schema.TABLES WHERE table_schema = '" . $db_root->escape($row['databasename']) . "' GROUP BY table_schema ;");
$row['size'] = number_format($mbdata['MB'], 3, '.', '');
eval("\$mysqls.=\"" . getTemplate("mysql/mysqls_database") . "\";"); eval("\$mysqls.=\"" . getTemplate("mysql/mysqls_database") . "\";");
$count++; $count++;
} }
$i++; $i++;
} }
$db_root->close();
// End root-session
$mysqls_count = $db->num_rows($result); $mysqls_count = $db->num_rows($result);
eval("echo \"" . getTemplate("mysql/mysqls") . "\";"); eval("echo \"" . getTemplate("mysql/mysqls") . "\";");

View File

@@ -227,9 +227,9 @@ elseif($page == 'tickets')
$categories = makeoption($lng['ticket']['no_cat'], '0'); $categories = makeoption($lng['ticket']['no_cat'], '0');
} }
$priorities = makeoption($lng['ticket']['unf_high'], '1', $settings['ticket']['default_priority']); $priorities = makeoption($lng['ticket']['high'], '1', $settings['ticket']['default_priority']);
$priorities.= makeoption($lng['ticket']['unf_normal'], '2', $settings['ticket']['default_priority']); $priorities.= makeoption($lng['ticket']['normal'], '2', $settings['ticket']['default_priority']);
$priorities.= makeoption($lng['ticket']['unf_low'], '3', $settings['ticket']['default_priority']); $priorities.= makeoption($lng['ticket']['low'], '3', $settings['ticket']['default_priority']);
$ticketsopen = 0; $ticketsopen = 0;
$opentickets = $db->query_first('SELECT COUNT(`id`) as `count` FROM `' . TABLE_PANEL_TICKETS . '` $opentickets = $db->query_first('SELECT COUNT(`id`) as `count` FROM `' . TABLE_PANEL_TICKETS . '`
WHERE `customerid` = "' . $userinfo['customerid'] . '" WHERE `customerid` = "' . $userinfo['customerid'] . '"

BIN
images/favicon.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@@ -468,7 +468,7 @@ INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('syste
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'vmail_homedir', '/var/customers/mail/'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'vmail_homedir', '/var/customers/mail/');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'bindconf_directory', '/etc/bind/'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'bindconf_directory', '/etc/bind/');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'bindreload_command', '/etc/init.d/bind9 reload'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'bindreload_command', '/etc/init.d/bind9 reload');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('panel', 'version', '0.9.23-rc1'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('panel', 'version', '0.9.24');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'hostname', 'SERVERNAME'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'hostname', 'SERVERNAME');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('login', 'maxloginattempts', '3'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('login', 'maxloginattempts', '3');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('login', 'deactivatetime', '900'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('login', 'deactivatetime', '900');
@@ -636,6 +636,10 @@ INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('syste
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'diskquota_repquota_path', '/usr/sbin/repquota'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'diskquota_repquota_path', '/usr/sbin/repquota');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'diskquota_quotatool_path', '/usr/bin/quotatool'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'diskquota_quotatool_path', '/usr/bin/quotatool');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'diskquota_customer_partition', '/dev/root'); INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'diskquota_customer_partition', '/dev/root');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'logrotate_enabled', '0');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'logrotate_binary', '/usr/sbin/logrotate');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'logrotate_interval', 'weekly');
INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES ('system', 'logrotate_keep', '4');
# -------------------------------------------------------- # --------------------------------------------------------

View File

@@ -1670,3 +1670,42 @@ if(isFroxlorVersion('0.9.22'))
updateToVersion('0.9.23-rc1'); updateToVersion('0.9.23-rc1');
} }
if(isFroxlorVersion('0.9.23-rc1'))
{
showUpdateStep("Updating from 0.9.23-rc1 to 0.9.23");
lastStepStatus(0);
updateToVersion('0.9.23');
}
if(isFroxlorVersion('0.9.23'))
{
showUpdateStep("Updating from 0.9.23 to 0.9.24-svn1");
lastStepStatus(0);
/* add new settings for logrotate - support */
$db->query("INSERT INTO `" . TABLE_PANEL_SETTINGS . "` (`settinggroup`, `varname`, `value`) VALUES ('system', 'logrotate_enabled', '0');");
$db->query("INSERT INTO `" . TABLE_PANEL_SETTINGS . "` (`settinggroup`, `varname`, `value`) VALUES ('system', 'logrotate_binary', '/usr/sbin/logrotate');");
$db->query("INSERT INTO `" . TABLE_PANEL_SETTINGS . "` (`settinggroup`, `varname`, `value`) VALUES ('system', 'logrotate_interval', 'weekly');");
$db->query("INSERT INTO `" . TABLE_PANEL_SETTINGS . "` (`settinggroup`, `varname`, `value`) VALUES ('system', 'logrotate_keep', '4');");
updateToVersion('0.9.24-svn1');
}
if(isFroxlorVersion('0.9.24-svn1'))
{
showUpdateStep("Updating from 0.9.24-svn1 to 0.9.24-rc1");
lastStepStatus(0);
updateToVersion('0.9.24-rc1');
}
if(isFroxlorVersion('0.9.24-rc1'))
{
showUpdateStep("Updating from 0.9.24-rc1 to 0.9.24");
lastStepStatus(0);
updateToVersion('0.9.24');
}

View File

@@ -73,9 +73,9 @@ function parseAndOutputPreconfig(&$has_preconfig, &$return, $current_version)
$description = 'You can define a default support-ticket priority level which is pre-selected for new support-tickets.'; $description = 'You can define a default support-ticket priority level which is pre-selected for new support-tickets.';
$question = '<strong>Which should be the default ticket-priority?:</strong>&nbsp;'; $question = '<strong>Which should be the default ticket-priority?:</strong>&nbsp;';
$question .= '<select name="update_deftic_priority">'; $question .= '<select name="update_deftic_priority">';
$priorities = makeoption($lng['ticket']['unf_high'], '1', '2'); $priorities = makeoption($lng['ticket']['high'], '1', '2');
$priorities.= makeoption($lng['ticket']['unf_normal'], '2', '2'); $priorities.= makeoption($lng['ticket']['normal'], '2', '2');
$priorities.= makeoption($lng['ticket']['unf_low'], '3', '2'); $priorities.= makeoption($lng['ticket']['low'], '3', '2');
$question .= $priorities.'</select>'; $question .= $priorities.'</select>';
eval("\$return.=\"" . getTemplate("update/preconfigitem") . "\";"); eval("\$return.=\"" . getTemplate("update/preconfigitem") . "\";");
} }

View File

@@ -205,8 +205,8 @@ class phpinterface_fpm
if(!is_dir($socketdir) && $createifnotexists) if(!is_dir($socketdir) && $createifnotexists)
{ {
safe_exec('mkdir -p '.$socketdir); safe_exec('mkdir -p '.escapeshellarg($socketdir));
safe_exec('chown -R '.$this->_settings['system']['httpuser'].':'.$this->_settings['system']['httpgroup'].' '.$socketdir); safe_exec('chown -R '.$this->_settings['system']['httpuser'].':'.$this->_settings['system']['httpgroup'].' '.escapeshellarg($socketdir));
} }
return $socket; return $socket;

View File

@@ -25,7 +25,7 @@ return array(
'fields' => array( 'fields' => array(
'path' => array( 'path' => array(
'label' => $lng['extras']['backup_create'], 'label' => $lng['extras']['backup_create'],
'desc' => $lng['extras']['backup_info'].'<br />'.($settings['system']['backup_bigfile'] == 1 ? $lng['extras']['backup_info_big'] : $lng['extras']['backup_info_sep']).'<br />'.$lng['extras']['backup_count_info'], 'desc' => $lng['extras']['backup_info'].'<br />'.($settings['system']['backup_bigfile'] == 1 ? $lng['extras']['backup_info_big'] : $lng['extras']['backup_info_sep']).'<br />'.($settings['system']['backup_count'] == 1 ? $lng['extras']['backup_count_info'] : ''),
'type' => 'yesno', 'type' => 'yesno',
'yesno_var' => $backup_enabled 'yesno_var' => $backup_enabled
) )

View File

@@ -19,9 +19,9 @@
* chowns either awstats or webalizer folder, * chowns either awstats or webalizer folder,
* either with webserver-user or - if fcgid * either with webserver-user or - if fcgid
* is used - the customers name, #258 * is used - the customers name, #258
* *
* @param array $row array if panel_customers * @param array $row array if panel_customers
* *
* @return void * @return void
*/ */
function makeChownWithNewStats($row) function makeChownWithNewStats($row)
@@ -29,7 +29,7 @@ function makeChownWithNewStats($row)
global $settings; global $settings;
// get correct user // get correct user
if($settings['system']['mod_fcgid'] == 1) if($settings['system']['mod_fcgid'] == '1' && $row['deactivated'] == '0')
{ {
$user = $row['loginname']; $user = $row['loginname'];
$group = $row['loginname']; $group = $row['loginname'];

View File

@@ -0,0 +1,26 @@
<?php
/**
* This file is part of the Froxlor project.
* Copyright (c) 2003-2009 the SysCP Team (see authors).
* Copyright (c) 2010 the Froxlor Team (see authors).
*
* For the full copyright and license information, please view the COPYING
* file that was distributed with this source code. You can also view the
* COPYING file online at http://files.froxlor.org/misc/COPYING.txt
*
* @copyright (c) the authors
* @author Florian Lippert <flo@syscp.org> (2003-2009)
* @author Froxlor team <team@froxlor.org> (2010-)
* @license GPLv2 http://files.froxlor.org/misc/COPYING.txt
* @package Functions
*
*/
function getFormFieldOutputHiddenString($fieldname, $fielddata)
{
$label = $fielddata['label'];
$value = htmlentities($fielddata['value']);
eval("\$returnvalue = \"" . getTemplate("formfields/hiddenstring", true) . "\";");
return $returnvalue;
}

View File

@@ -0,0 +1,115 @@
<?php
/**
* This file is part of the Froxlor project.
* Copyright (c) 2003-2009 the SysCP Team (see authors).
* Copyright (c) 2010 the Froxlor Team (see authors).
*
* For the full copyright and license information, please view the COPYING
* file that was distributed with this source code. You can also view the
* COPYING file online at http://files.froxlor.org/misc/COPYING.txt
*
* @copyright (c) the authors
* @author Florian Lippert <flo@syscp.org> (2003-2009)
* @author Froxlor team <team@froxlor.org> (2010-)
* @license GPLv2 http://files.froxlor.org/misc/COPYING.txt
* @package Functions
*
*/
function validateFormFieldHiddenString($fieldname, $fielddata, $newfieldvalue)
{
if(isset($fielddata['string_delimiter']) && $fielddata['string_delimiter'] != '')
{
$newfieldvalues = explode($fielddata['string_delimiter'], $newfieldvalue);
unset($fielddata['string_delimiter']);
$returnvalue = true;
foreach($newfieldvalues as $single_newfieldvalue)
{
/**
* don't use tabs in value-fields, #81
*/
$single_newfieldvalue = str_replace("\t", " ", $single_newfieldvalue);
$single_returnvalue = validateFormFieldString($fieldname, $fielddata, $single_newfieldvalue);
if($single_returnvalue !== true)
{
$returnvalue = $single_returnvalue;
break;
}
}
}
else
{
$returnvalue = false;
/**
* don't use tabs in value-fields, #81
*/
$newfieldvalue = str_replace("\t", " ", $newfieldvalue);
if(isset($fielddata['string_type']) && $fielddata['string_type'] == 'mail')
{
$returnvalue = (filter_var($newfieldvalue, FILTER_VALIDATE_EMAIL) == $newfieldvalue);
}
elseif(isset($fielddata['string_type']) && $fielddata['string_type'] == 'url')
{
$returnvalue = validateUrl($newfieldvalue);
}
elseif(isset($fielddata['string_type']) && $fielddata['string_type'] == 'dir')
{
// add trailing slash to validate path if needed
// refs #331
if(substr($newfieldvalue, -1) != '/') {
$newfieldvalue.= '/';
}
$returnvalue = ($newfieldvalue == makeCorrectDir($newfieldvalue));
}
elseif(isset($fielddata['string_type']) && $fielddata['string_type'] == 'file')
{
$returnvalue = ($newfieldvalue == makeCorrectFile($newfieldvalue));
}
elseif(isset($fielddata['string_type']) && $fielddata['string_type'] == 'filedir')
{
$returnvalue = (($newfieldvalue == makeCorrectDir($newfieldvalue)) || ($newfieldvalue == makeCorrectFile($newfieldvalue)));
}
elseif(preg_match('/^[^\r\n\t\f\0]*$/D', $newfieldvalue))
{
$returnvalue = true;
}
if(isset($fielddata['string_regexp']) && $fielddata['string_regexp'] != '')
{
if(preg_match($fielddata['string_regexp'], $newfieldvalue))
{
$returnvalue = true;
}
else
{
$returnvalue = false;
}
}
if(isset($fielddata['string_emptyallowed']) && $fielddata['string_emptyallowed'] === true && $newfieldvalue === '')
{
$returnvalue = true;
}
elseif(isset($fielddata['string_emptyallowed']) && $fielddata['string_emptyallowed'] === false && $newfieldvalue === '')
{
$returnvalue = 'stringmustntbeempty';
}
}
if($returnvalue === true)
{
return true;
}
elseif($returnvalue === false)
{
return 'stringformaterror';
}
else
{
return $returnvalue;
}
}

View File

@@ -0,0 +1,27 @@
<?php
/**
* This file is part of the Froxlor project.
* Copyright (c) 2010 the Froxlor Team (see authors).
*
* For the full copyright and license information, please view the COPYING
* file that was distributed with this source code. You can also view the
* COPYING file online at http://files.froxlor.org/misc/COPYING.txt
*
* @copyright (c) the authors
* @author Froxlor team <team@froxlor.org> (2010-)
* @license GPLv2 http://files.froxlor.org/misc/COPYING.txt
* @package Functions
*
*/
function checkHostname($fieldname, $fielddata, $newfieldvalue, $allnewfieldvalues)
{
echo $fieldname . "--" . $fielddata . "--" . $newfieldvalue . "--". $allnewfieldvalues;
if (0 == strlen(trim($fielddata)))
{
return array(FORMFIELDS_PLAUSIBILITY_CHECK_ERROR, 'invalidhostname');
} else {
return array(FORMFIELDS_PLAUSIBILITY_CHECK_OK);
}
}

View File

@@ -73,6 +73,6 @@ define('PACKAGE_ENABLED', 2);
// VERSION INFO // VERSION INFO
$version = '0.9.23-rc1'; $version = '0.9.24';
$dbversion = '2'; $dbversion = '2';
$branding = ''; $branding = '';

View File

@@ -606,12 +606,9 @@ $lng['ticket']['subject'] = 'P&oslash;edm&igrave; t';
$lng['ticket']['status'] = 'Status'; $lng['ticket']['status'] = 'Status';
$lng['ticket']['lastreplier'] = 'Posledn&iacute; odpov&iacute;daj&iacute;c&iacute;'; $lng['ticket']['lastreplier'] = 'Posledn&iacute; odpov&iacute;daj&iacute;c&iacute;';
$lng['ticket']['priority'] = 'Priorita'; $lng['ticket']['priority'] = 'Priorita';
$lng['ticket']['low'] = '<span class="ticket_low">N&iacute;zk&aacute;</span>'; $lng['ticket']['low'] = 'N&iacute;zk&aacute;';
$lng['ticket']['normal'] = '<span class="ticket_normal">Norm&aacute;ln&iacute;</span>'; $lng['ticket']['normal'] = 'Norm&aacute;ln&iacute;';
$lng['ticket']['high'] = '<span class="ticket_high">Vysok&aacute;</span>'; $lng['ticket']['high'] = 'Vysok&aacute;';
$lng['ticket']['unf_low'] = 'N&iacute;zk&aacute;';
$lng['ticket']['unf_normal'] = 'Norm&aacute;ln&iacute;';
$lng['ticket']['unf_high'] = 'Vysok&aacute;';
$lng['ticket']['lastchange'] = 'Posledn&iacute; zm&igrave; na'; $lng['ticket']['lastchange'] = 'Posledn&iacute; zm&igrave; na';
$lng['ticket']['lastchange_from'] = 'Od data (dd.mm.yyyy)'; $lng['ticket']['lastchange_from'] = 'Od data (dd.mm.yyyy)';
$lng['ticket']['lastchange_to'] = 'Do data (dd.mm.yyyy)'; $lng['ticket']['lastchange_to'] = 'Do data (dd.mm.yyyy)';

View File

@@ -601,12 +601,9 @@ $lng['ticket']['subject'] = 'Onderwerp';
$lng['ticket']['status'] = 'Status'; $lng['ticket']['status'] = 'Status';
$lng['ticket']['lastreplier'] = 'Laatste beantwoorder'; $lng['ticket']['lastreplier'] = 'Laatste beantwoorder';
$lng['ticket']['priority'] = 'Prioriteit'; $lng['ticket']['priority'] = 'Prioriteit';
$lng['ticket']['low'] = '<span class="ticket_low">Laag</span>'; $lng['ticket']['low'] = 'Laag';
$lng['ticket']['normal'] = '<span class="ticket_normal">Normaal</span>'; $lng['ticket']['normal'] = 'Normaal';
$lng['ticket']['high'] = '<span class="ticket_high">Hoog</span>'; $lng['ticket']['high'] = 'Hoog';
$lng['ticket']['unf_low'] = 'Laag';
$lng['ticket']['unf_normal'] = 'Normaal';
$lng['ticket']['unf_high'] = 'Hoog';
$lng['ticket']['lastchange'] = 'Laatste wijziging'; $lng['ticket']['lastchange'] = 'Laatste wijziging';
$lng['ticket']['lastchange_from'] = 'Datum vanaf (dd.mm.yyyy)'; $lng['ticket']['lastchange_from'] = 'Datum vanaf (dd.mm.yyyy)';
$lng['ticket']['lastchange_to'] = 'Datum tot (dd.mm.yyyy)'; $lng['ticket']['lastchange_to'] = 'Datum tot (dd.mm.yyyy)';

View File

@@ -153,8 +153,8 @@ $lng['ftp']['account_add'] = 'Create Account';
* MySQL * MySQL
*/ */
$lng['mysql']['databasename'] = 'user/database name'; $lng['mysql']['databasename'] = 'User/Database name';
$lng['mysql']['databasedescription'] = 'database description'; $lng['mysql']['databasedescription'] = 'Database description';
$lng['mysql']['database_create'] = 'Create database'; $lng['mysql']['database_create'] = 'Create database';
/** /**
@@ -611,12 +611,9 @@ $lng['ticket']['subject'] = 'Subject';
$lng['ticket']['status'] = 'Status'; $lng['ticket']['status'] = 'Status';
$lng['ticket']['lastreplier'] = 'Last replier'; $lng['ticket']['lastreplier'] = 'Last replier';
$lng['ticket']['priority'] = 'Priority'; $lng['ticket']['priority'] = 'Priority';
$lng['ticket']['low'] = '<span class="ticket_low">Low</span>'; $lng['ticket']['low'] = 'Low';
$lng['ticket']['normal'] = '<span class="ticket_normal">Normal</span>'; $lng['ticket']['normal'] = 'Normal';
$lng['ticket']['high'] = '<span class="ticket_high">High</span>'; $lng['ticket']['high'] = 'High';
$lng['ticket']['unf_low'] = 'Low';
$lng['ticket']['unf_normal'] = 'Normal';
$lng['ticket']['unf_high'] = 'High';
$lng['ticket']['lastchange'] = 'Last change'; $lng['ticket']['lastchange'] = 'Last change';
$lng['ticket']['lastchange_from'] = 'From date (dd.mm.yyyy)'; $lng['ticket']['lastchange_from'] = 'From date (dd.mm.yyyy)';
$lng['ticket']['lastchange_to'] = 'To date (dd.mm.yyyy)'; $lng['ticket']['lastchange_to'] = 'To date (dd.mm.yyyy)';
@@ -1423,7 +1420,7 @@ $lng['serversettings']['mail_also_with_mxservers'] = 'Create mail-, imap-, pop3-
$lng['aps']['nocontingent'] = 'Your APS contingent is insufficient. You cannot install any package.'; $lng['aps']['nocontingent'] = 'Your APS contingent is insufficient. You cannot install any package.';
$lng['aps']['packageneedsdb'] = 'This package needs a database but your contingent is used up'; $lng['aps']['packageneedsdb'] = 'This package needs a database but your contingent is used up';
$lng['aps']['cannoteditordeleteapsdb'] = 'APS databases cannot be edited or removed here'; $lng['aps']['cannoteditordeleteapsdb'] = 'APS databases cannot be edited or removed here';
$lng['admin']['webserver_Puser'] = 'Webserver user-name'; $lng['admin']['webserver_user'] = 'Webserver user-name';
$lng['admin']['webserver_group'] = 'Webserver group-name'; $lng['admin']['webserver_group'] = 'Webserver group-name';
// ADDED IN FROXLOR 0.9.10 // ADDED IN FROXLOR 0.9.10
@@ -1887,3 +1884,16 @@ $lng['serversettings']['diskquota_customer_partition']['description'] = 'Partiti
$lng['tasks']['diskspace_set_quota'] = 'Set quota on filesystem'; $lng['tasks']['diskspace_set_quota'] = 'Set quota on filesystem';
$lng['error']['session_timeout'] = 'Value too low'; $lng['error']['session_timeout'] = 'Value too low';
$lng['error']['session_timeout_desc'] = 'You should not set the session timeout lower than 1 minute.'; $lng['error']['session_timeout_desc'] = 'You should not set the session timeout lower than 1 minute.';
// ADDED IN FROXLOR 0.9.24-svn1
$lng['logrotate'] = 'Logrotate';
$lng['logrotate_enabled'] = 'Enable logrotate?';
$lng['logrotate_binary'] = 'Path to logrotate binary:';
$lng['logrotate_interval'] = 'Interval?';
$lng['logrotate_keep'] = 'How many logfiles should be kept?';
$lng['admin']['assignedmax'] = 'Assigned / Max';
$lng['admin']['usedmax'] = 'Used / Max';
$lng['admin']['used'] = 'Used';
$lng['mysql']['size'] = 'Database size (MB)';
$lng['error']['invalidhostname'] = 'Hostname can\'t be empty nor can it consist only of whitespaces';

View File

@@ -618,12 +618,9 @@ $lng['ticket']['subject'] = 'Sujet';
$lng['ticket']['status'] = 'Etat'; $lng['ticket']['status'] = 'Etat';
$lng['ticket']['lastreplier'] = 'Derni&egrave;re r&eacute;ponse de'; $lng['ticket']['lastreplier'] = 'Derni&egrave;re r&eacute;ponse de';
$lng['ticket']['priority'] = 'Priorit&eacute;'; $lng['ticket']['priority'] = 'Priorit&eacute;';
$lng['ticket']['low'] = '<span class="ticket_low">Basse</span>'; $lng['ticket']['low'] = 'Basse';
$lng['ticket']['normal'] = '<span class="ticket_normal">Normale</span>'; $lng['ticket']['normal'] = 'Normale';
$lng['ticket']['high'] = '<span class="ticket_high">Haute</span>'; $lng['ticket']['high'] = 'Haute';
$lng['ticket']['unf_low'] = 'Basse';
$lng['ticket']['unf_normal'] = 'Normale';
$lng['ticket']['unf_high'] = 'Haute';
$lng['ticket']['lastchange'] = 'Dernier changement'; $lng['ticket']['lastchange'] = 'Dernier changement';
$lng['ticket']['lastchange_from'] = 'Depuis (jj.mm.aaaa)'; $lng['ticket']['lastchange_from'] = 'Depuis (jj.mm.aaaa)';
$lng['ticket']['lastchange_to'] = 'Jusqu\'au (jj.mm.aaaa)'; $lng['ticket']['lastchange_to'] = 'Jusqu\'au (jj.mm.aaaa)';

View File

@@ -614,12 +614,9 @@ $lng['ticket']['subject'] = 'Betreff';
$lng['ticket']['status'] = 'Status'; $lng['ticket']['status'] = 'Status';
$lng['ticket']['lastreplier'] = 'Letzte Antwort'; $lng['ticket']['lastreplier'] = 'Letzte Antwort';
$lng['ticket']['priority'] = 'Priorit&auml;t'; $lng['ticket']['priority'] = 'Priorit&auml;t';
$lng['ticket']['low'] = '<span class="ticket_low">Niedrig</span>'; $lng['ticket']['low'] = 'Niedrig';
$lng['ticket']['normal'] = '<span class="ticket_normal">Normal</span>'; $lng['ticket']['normal'] = 'Normal';
$lng['ticket']['high'] = '<span class="ticket_high">Hoch</span>'; $lng['ticket']['high'] = 'Hoch';
$lng['ticket']['unf_low'] = 'Niedrig';
$lng['ticket']['unf_normal'] = 'Normal';
$lng['ticket']['unf_high'] = 'Hoch';
$lng['ticket']['lastchange'] = 'Letzte &Auml;nderung'; $lng['ticket']['lastchange'] = 'Letzte &Auml;nderung';
$lng['ticket']['lastchange_from'] = 'Anfangsdatum (tt.mm.jjjj)'; $lng['ticket']['lastchange_from'] = 'Anfangsdatum (tt.mm.jjjj)';
$lng['ticket']['lastchange_to'] = 'Enddatum (tt.mm.jjjj)'; $lng['ticket']['lastchange_to'] = 'Enddatum (tt.mm.jjjj)';
@@ -1618,3 +1615,16 @@ $lng['serversettings']['diskquota_customer_partition']['description'] = 'Partiti
$lng['tasks']['diskspace_set_quota'] = 'Quota auf dem Dateisystem setzen'; $lng['tasks']['diskspace_set_quota'] = 'Quota auf dem Dateisystem setzen';
$lng['error']['session_timeout'] = 'Wert zu niedrig'; $lng['error']['session_timeout'] = 'Wert zu niedrig';
$lng['error']['session_timeout_desc'] = 'Der Wert der Session Timeout sollte nicht unter einer Minute liegen.'; $lng['error']['session_timeout_desc'] = 'Der Wert der Session Timeout sollte nicht unter einer Minute liegen.';
// ADDED IN FROXLOR 0.9.24-svn1
$lng['logrotate'] = 'Logrotate';
$lng['logrotate_enabled'] = 'Logrotate aktivieren?';
$lng['logrotate_binary'] = 'Pfad zum logrotate binary?';
$lng['logrotate_interval'] = 'Intervall?';
$lng['logrotate_keep'] = 'Wie viele Logdateien sollen aufbewahrt werden?';
$lng['admin']['assignedmax'] = 'Zugewiesen / Max.';
$lng['admin']['usedmax'] = 'Benutzt / Max.';
$lng['admin']['used'] = 'Benutzt';
$lng['mysql']['size'] = 'Datenbankgr&ouml;&szlig;e (MB)';
$lng['error']['invalidhostname'] = 'Hostname darf nicht leer sein oder nur aus Leerzeichen bestehen';

View File

@@ -614,12 +614,9 @@ $lng['ticket']['subject'] = 'Soggetto';
$lng['ticket']['status'] = 'Stato'; $lng['ticket']['status'] = 'Stato';
$lng['ticket']['lastreplier'] = 'Ultimo che ha risposto'; $lng['ticket']['lastreplier'] = 'Ultimo che ha risposto';
$lng['ticket']['priority'] = 'Priorit&agrave;'; $lng['ticket']['priority'] = 'Priorit&agrave;';
$lng['ticket']['low'] = '<span class="ticket_low">Bassa</span>'; $lng['ticket']['low'] = 'Bassa';
$lng['ticket']['normal'] = '<span class="ticket_normal">Normale</span>'; $lng['ticket']['normal'] = 'Normale';
$lng['ticket']['high'] = '<span class="ticket_high">Alta</span>'; $lng['ticket']['high'] = 'Alta';
$lng['ticket']['unf_low'] = 'Bassa';
$lng['ticket']['unf_normal'] = 'Normale';
$lng['ticket']['unf_high'] = 'Alta';
$lng['ticket']['lastchange'] = 'Ultima modifica'; $lng['ticket']['lastchange'] = 'Ultima modifica';
$lng['ticket']['lastchange_from'] = 'Dalla data (dd.mm.yyyy)'; $lng['ticket']['lastchange_from'] = 'Dalla data (dd.mm.yyyy)';
$lng['ticket']['lastchange_to'] = 'Alla data (dd.mm.yyyy)'; $lng['ticket']['lastchange_to'] = 'Alla data (dd.mm.yyyy)';

View File

@@ -607,12 +607,9 @@ $lng['ticket']['subject'] = 'Temat';
$lng['ticket']['status'] = 'Status'; $lng['ticket']['status'] = 'Status';
$lng['ticket']['lastreplier'] = 'Ostatnia odpowied&#378'; $lng['ticket']['lastreplier'] = 'Ostatnia odpowied&#378';
$lng['ticket']['priority'] = 'Priorytet'; $lng['ticket']['priority'] = 'Priorytet';
$lng['ticket']['low'] = '<span class="ticket_low">Niski</span>'; $lng['ticket']['low'] = 'Niski';
$lng['ticket']['normal'] = '<span class="ticket_normal">Normalny</span>'; $lng['ticket']['normal'] = 'Normalny';
$lng['ticket']['high'] = '<span class="ticket_high">Wysoki</span>'; $lng['ticket']['high'] = 'Wysoki';
$lng['ticket']['unf_low'] = 'Niski';
$lng['ticket']['unf_normal'] = 'Normalny';
$lng['ticket']['unf_high'] = 'Wysoki';
$lng['ticket']['lastchange'] = 'Ostatnia zmiana'; $lng['ticket']['lastchange'] = 'Ostatnia zmiana';
$lng['ticket']['lastchange_from'] = 'Od daty (dd.mm.yyyy)'; $lng['ticket']['lastchange_from'] = 'Od daty (dd.mm.yyyy)';
$lng['ticket']['lastchange_to'] = 'Do daty (dd.mm.yyyy)'; $lng['ticket']['lastchange_to'] = 'Do daty (dd.mm.yyyy)';

View File

@@ -542,12 +542,9 @@ $lng['ticket']['subject'] = 'Assunto';
$lng['ticket']['status'] = 'Status'; $lng['ticket']['status'] = 'Status';
$lng['ticket']['lastreplier'] = '&Uacute;ltimo que respondeu'; $lng['ticket']['lastreplier'] = '&Uacute;ltimo que respondeu';
$lng['ticket']['priority'] = 'Prioridade'; $lng['ticket']['priority'] = 'Prioridade';
$lng['ticket']['low'] = '<span class="ticket_low">Baixa</span>'; $lng['ticket']['low'] = 'Baixa';
$lng['ticket']['normal'] = '<span class="ticket_normal">Normal</span>'; $lng['ticket']['normal'] = 'Normal';
$lng['ticket']['high'] = '<span class="ticket_high">Alta</span>'; $lng['ticket']['high'] = 'Alta';
$lng['ticket']['unf_low'] = 'Baixa';
$lng['ticket']['unf_normal'] = 'Normal';
$lng['ticket']['unf_high'] = 'Alta';
$lng['ticket']['lastchange_from'] = 'De data (dd.mm.aaaa)'; $lng['ticket']['lastchange_from'] = 'De data (dd.mm.aaaa)';
$lng['ticket']['lastchange_to'] = 'At&eacute; data (dd.mm.aaaa)'; $lng['ticket']['lastchange_to'] = 'At&eacute; data (dd.mm.aaaa)';
$lng['ticket']['category'] = 'Categoria'; $lng['ticket']['category'] = 'Categoria';

View File

@@ -40,39 +40,45 @@ if($settings['system']['backup_enabled'] == '1'){
$ftp_row = mysql_fetch_array($ftp_result); $ftp_row = mysql_fetch_array($ftp_result);
// create backup dir an set rights // create backup dir an set rights
if(!file_exists($row['documentroot'] . $settings['system']['backup_dir'])){ if(!file_exists($settings['system']['backup_dir'] . $row['loginname'])) {
safe_exec('install -d ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . ' -o ' . escapeshellarg($ftp_row['uid']) . ' -g ' . escapeshellarg($ftp_row['gid']) . ' -m ' . '0500'); safe_exec('install -d ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . ' -o ' . escapeshellarg($ftp_row['uid']) . ' -g ' . escapeshellarg($ftp_row['gid']) . ' -m ' . '0500');
} }
// create customers html backup // create customers html backup
safe_exec('tar -C ' . escapeshellarg($row['documentroot']) . ' -c -z -f ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/' . escapeshellarg($row['loginname']) . 'html.tar.gz .'); safe_exec('tar -C ' . escapeshellarg($row['documentroot']) . ' -c -z -f ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/' . escapeshellarg($row['loginname']) . 'html.tar.gz .');
// get customer dbs // get customer dbs
$dbs_result = $db->query("SELECT databasename FROM `" . TABLE_PANEL_DATABASES . "` WHERE `customerid` = '" . $db->escape($row['customerid']) . "';"); $dbs_result = $db->query("SELECT databasename FROM `" . TABLE_PANEL_DATABASES . "` WHERE `customerid` = '" . $db->escape($row['customerid']) . "';");
while($dbs_row = $db->fetch_array($dbs_result)){ while($dbs_row = $db->fetch_array($dbs_result)){
// create customers sql backup // create customers sql backup
safe_exec(escapeshellarg($settings['system']['backup_mysqldump_path']) . ' --opt --force --allow-keywords -u ' . $sql_root[0]['user'] . ' -p' . $sql_root[0]['password'] . ' -h ' . $sql_root[0]['host'] . ' ' . escapeshellarg($dbs_row['databasename']) . ' -r ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/' . escapeshellarg($dbs_row['databasename']) . '.sql' ); safe_exec(escapeshellarg($settings['system']['backup_mysqldump_path']) . ' --opt --force --allow-keywords -u ' . escapeshellarg($sql_root[0]['user']) . ' -p' . escapeshellarg($sql_root[0]['password']) . ' -h ' . $sql_root[0]['host'] . ' ' . escapeshellarg($dbs_row['databasename']) . ' -r ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/' . escapeshellarg($dbs_row['databasename']) . '.sql' );
// compress sql backup // compress sql backup
safe_exec('tar -C ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . ' -c -z -f ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/' . escapeshellarg($dbs_row['databasename']) . '.tar.gz ' . escapeshellarg($dbs_row['databasename']) . '.sql'); safe_exec('tar -C ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . ' -c -z -f ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/' . escapeshellarg($dbs_row['databasename']) . '.tar.gz ' . escapeshellarg($dbs_row['databasename']) . '.sql');
// remove uncompresed sql files // remove uncompresed sql files
safe_exec('rm ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/' . escapeshellarg($dbs_row['databasename']) . '.sql'); safe_exec('rm ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/' . escapeshellarg($dbs_row['databasename']) . '.sql');
} }
// create 1 big file with html & db // create 1 big file with html & db
if($settings['system']['backup_bigfile'] == 1){ if($settings['system']['backup_bigfile'] == 1){
safe_exec('tar -C ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/' . ' --exclude=' . escapeshellarg($row['loginname']) . '.tar.gz -c -z -f ' . $settings['system']['backup_dir'] . $row['loginname'] . '/' . escapeshellarg($row['loginname']) . '.tar.gz .'); safe_exec('tar -C ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/' . ' --exclude=' . escapeshellarg($row['loginname']) . '.tar.gz -c -z -f ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/' . escapeshellarg($row['loginname']) . '.tar.gz .');
// remove separated files // remove separated files
$tmp_files = scandir($settings['system']['backup_dir'] . $row['loginname']); $tmp_files = scandir($settings['system']['backup_dir'] . $row['loginname']);
foreach ($tmp_files as $tmp_file){ foreach ($tmp_files as $tmp_file){
if(preg_match('/.*(html|sql|aps).*\.tar\.gz$/', $tmp_file) && !preg_match('/^' . $row['loginname'] . '\.tar\.gz$/', $tmp_file)){ if(preg_match('/.*(html|sql|aps).*\.tar\.gz$/', $tmp_file) && !preg_match('/^' . $row['loginname'] . '\.tar\.gz$/', $tmp_file)){
safe_exec('rm ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/' . $tmp_file . ''); safe_exec('rm ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/' . escapeshellarg($tmp_file) . '');
} }
} }
} }
else {
//remove big file if separated backups are used
if (file_exists($settings['system']['backup_dir'] . $row['loginname'] . '/' . $row['loginname'] . '.tar.gz')) {
safe_exec('rm ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/' . escapeshellarg($row['loginname']) . '.tar.gz');
}
}
// chown & chmod files to prevent manipulation // chown & chmod files to prevent manipulation
safe_exec('chown ' . escapeshellarg($row['guid']) . ':' . escapeshellarg($row['guid']) . ' ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/*'); safe_exec('chown ' . escapeshellarg($row['guid']) . ':' . escapeshellarg($row['guid']) . ' ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/*');
safe_exec('chmod 0400 ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/*'); safe_exec('chmod 0400 ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/*');
// create ftp backup user // create ftp backup user
$user_result = $db->query("SELECT username, password FROM `" . TABLE_FTP_USERS . "` WHERE `customerid` = '" . $db->escape($row['customerid']) . "' AND `username` = '" . $db->escape($row['loginname']) . "';"); $user_result = $db->query("SELECT username, password FROM `" . TABLE_FTP_USERS . "` WHERE `customerid` = '" . $db->escape($row['customerid']) . "' AND `username` = '" . $db->escape($row['loginname']) . "';");
@@ -111,7 +117,7 @@ if($settings['system']['backup_enabled'] == '1'){
$files = scandir($settings['system']['backup_dir'] . $row['loginname'] . '/'); $files = scandir($settings['system']['backup_dir'] . $row['loginname'] . '/');
foreach ($files as $file){ foreach ($files as $file){
if(preg_match('/.*\.tar\.gz$/', $file)){ if(preg_match('/.*\.tar\.gz$/', $file)){
safe_exec('rm ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '/' . $file . ''); safe_exec('rm ' . escapeshellarg($settings['system']['backup_dir']) . escapeshellarg($row['loginname']) . '/' . escapeshellarg($file) . '');
} }
} }
} }

View File

@@ -279,14 +279,21 @@ class bind
if($domain['iswildcarddomain'] == '1') if($domain['iswildcarddomain'] == '1')
{ {
$zonefile.= '* IN ' . $ip_a_record . "\n"; $zonefile.= '* IN ' . $ip_a_record . "\n";
} }
$subdomains = $this->db->query('SELECT `d`.`domain`, `ip`.`ip` AS `ip` FROM `' . TABLE_PANEL_DOMAINS . '` `d`, `' . TABLE_PANEL_IPSANDPORTS . '` `ip` WHERE `parentdomainid`=\'' . $domain['id'] . '\' AND `d`.`ipandport`=`ip`.`id`'); $subdomains = $this->db->query('SELECT `d`.`domain`, `ip`.`ip` AS `ip` FROM `' . TABLE_PANEL_DOMAINS . '` `d`, `' . TABLE_PANEL_IPSANDPORTS . '` `ip` WHERE `parentdomainid`=\'' . $domain['id'] . '\' AND `d`.`ipandport`=`ip`.`id`');
while($subdomain = $this->db->fetch_array($subdomains)) while($subdomain = $this->db->fetch_array($subdomains))
{ {
$zonefile.= str_replace('.' . $domain['domain'], '', $subdomain['domain']) . ' IN A ' . $subdomain['ip'] . "\n"; if(filter_var($subdomain['ip'], FILTER_VALIDATE_IP, FILTER_FLAG_IPV4))
{
$zonefile.= str_replace('.' . $domain['domain'], '', $subdomain['domain']) . ' IN A ' . $subdomain['ip'] . "\n";
}
else
{
$zonefile.= str_replace('.' . $domain['domain'], '', $subdomain['domain']) . ' IN AAAA ' . $subdomain['ip'] . "\n";
}
} }
return $zonefile; return $zonefile;

View File

@@ -873,7 +873,7 @@ class apache
public function createVirtualHosts() public function createVirtualHosts()
{ {
$result_domains = $this->db->query("SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `d`.`phpsettingid`, `c`.`adminid`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled`, `d`.`mod_fcgid_starter`, `d`.`mod_fcgid_maxrequests` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) " . "LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) " . "WHERE `d`.`aliasdomain` IS NULL ORDER BY `d`.`parentdomainid` DESC, `d`.`iswildcarddomain`, `d`.`domain` ASC"); $result_domains = $this->db->query("SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `d`.`phpsettingid`, `c`.`adminid`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled`, `d`.`mod_fcgid_starter`, `d`.`mod_fcgid_maxrequests` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) " . "LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) " . "WHERE `d`.`aliasdomain` IS NULL AND `d`.`email_only` <> 1 ORDER BY `d`.`parentdomainid` DESC, `d`.`iswildcarddomain`, `d`.`domain` ASC");
while($domain = $this->db->fetch_array($result_domains)) while($domain = $this->db->fetch_array($result_domains))
{ {

View File

@@ -330,11 +330,11 @@ class lighttpd
if($ssl == '0') if($ssl == '0')
{ {
$query2 = "SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) WHERE `d`.`ipandport`='" . $ipandport['id'] . "' AND `d`.`aliasdomain` IS NULL ORDER BY `d`.`parentdomainid` DESC, `d`.`iswildcarddomain`, `d`.`domain` ASC"; $query2 = "SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) WHERE `d`.`ipandport`='" . $ipandport['id'] . "' AND `d`.`aliasdomain` IS NULL AND `d`.`email_only` <> 1 ORDER BY `d`.`parentdomainid` DESC, `d`.`iswildcarddomain`, `d`.`domain` ASC";
} }
else else
{ {
$query2 = "SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) WHERE `d`.`ssl_ipandport`='" . $ipandport['id'] . "' AND `d`.`aliasdomain` IS NULL ORDER BY `d`.`parentdomainid` DESC, `d`.`iswildcarddomain`, `d`.`domain` ASC"; $query2 = "SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) WHERE `d`.`ssl_ipandport`='" . $ipandport['id'] . "' AND `d`.`aliasdomain` IS NULL AND `d`.`email_only` <> 1 ORDER BY `d`.`parentdomainid` DESC, `d`.`iswildcarddomain`, `d`.`domain` ASC";
} }
$included_vhosts = array(); $included_vhosts = array();

View File

@@ -44,7 +44,7 @@ class nginx
/** /**
* indicator whether a customer is deactivated or not * indicator whether a customer is deactivated or not
* if yes, only the webroot will be generated * if yes, only the webroot will be generated
* *
* @var bool * @var bool
*/ */
private $_deactivated = false; private $_deactivated = false;
@@ -286,11 +286,11 @@ class nginx
if($ssl == '0') if($ssl == '0')
{ {
$query2 = "SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) WHERE `d`.`ipandport`='" . $ipandport['id'] . "' AND `d`.`aliasdomain` IS NULL ORDER BY `d`.`iswildcarddomain`, `d`.`domain` ASC"; $query2 = "SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) WHERE `d`.`ipandport`='" . $ipandport['id'] . "' AND `d`.`aliasdomain` IS NULL AND `d`.`email_only` <> 1 ORDER BY `d`.`iswildcarddomain`, `d`.`domain` ASC";
} }
else else
{ {
$query2 = "SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) WHERE `d`.`ssl_ipandport`='" . $ipandport['id'] . "' AND `d`.`aliasdomain` IS NULL ORDER BY `d`.`iswildcarddomain`, `d`.`domain` ASC"; $query2 = "SELECT `d`.*, `pd`.`domain` AS `parentdomain`, `c`.`loginname`, `c`.`guid`, `c`.`email`, `c`.`documentroot` AS `customerroot`, `c`.`deactivated`, `c`.`phpenabled` AS `phpenabled` FROM `" . TABLE_PANEL_DOMAINS . "` `d` LEFT JOIN `" . TABLE_PANEL_CUSTOMERS . "` `c` USING(`customerid`) LEFT JOIN `" . TABLE_PANEL_DOMAINS . "` `pd` ON (`pd`.`id` = `d`.`parentdomainid`) WHERE `d`.`ssl_ipandport`='" . $ipandport['id'] . "' AND `d`.`aliasdomain` IS NULL AND `d`.`email_only` <> 1 ORDER BY `d`.`iswildcarddomain`, `d`.`domain` ASC";
} }
$included_vhosts = array(); $included_vhosts = array();
@@ -422,6 +422,7 @@ class nginx
$vhost_content.= $this->getLogFiles($domain); $vhost_content.= $this->getLogFiles($domain);
$vhost_content.= $this->getWebroot($domain, $ssl_vhost); $vhost_content.= $this->getWebroot($domain, $ssl_vhost);
if ($this->_deactivated == false) { if ($this->_deactivated == false) {
$vhost_content.= $this->create_pathOptions($domain); $vhost_content.= $this->create_pathOptions($domain);
// $vhost_content.= $this->create_htaccess($domain); // $vhost_content.= $this->create_htaccess($domain);

View File

@@ -38,8 +38,8 @@ class nginx_phpfpm extends nginx
$phpconfig = $php->getPhpConfig((int)$domain['phpsettingid']); $phpconfig = $php->getPhpConfig((int)$domain['phpsettingid']);
$php_options_text = "\t".'location ~ \.php$ {'."\n"; $php_options_text = "\t".'location ~ \.php$ {'."\n";
$php_options_text.= "\t\t".'fastcgi_index index.php;'."\n"; // $php_options_text.= "\t\t".'fastcgi_index index.php;'."\n";
$php_options_text.= "\t\t".'include /etc/nginx/fastcgi_params;'."\n"; // $php_options_text.= "\t\t".'include /etc/nginx/fastcgi_params;'."\n";
if ($domain['ssl'] == '1' && $ssl_vhost) { if ($domain['ssl'] == '1' && $ssl_vhost) {
$php_options_text.= "\t\t".'fastcgi_param HTTPS on;'."\n"; $php_options_text.= "\t\t".'fastcgi_param HTTPS on;'."\n";
} }
@@ -50,7 +50,7 @@ class nginx_phpfpm extends nginx
// create starter-file | config-file // create starter-file | config-file
$php->getInterface()->createConfig($phpconfig); $php->getInterface()->createConfig($phpconfig);
// create php.ini // create php.ini
// @TODO make php-fpm support this // @TODO make php-fpm support this
$php->getInterface()->createIniFile($phpconfig); $php->getInterface()->createIniFile($phpconfig);
} }
@@ -70,7 +70,7 @@ class nginx_phpfpm extends nginx
$mypath = makeCorrectDir(dirname(dirname(dirname(__FILE__)))); // /var/www/froxlor, needed for chown $mypath = makeCorrectDir(dirname(dirname(dirname(__FILE__)))); // /var/www/froxlor, needed for chown
$user = $this->settings['phpfpm']['vhost_httpuser']; $user = $this->settings['phpfpm']['vhost_httpuser'];
$group = $this->settings['phpfpm']['vhost_httpgroup']; $group = $this->settings['phpfpm']['vhost_httpgroup'];
$domain = array( $domain = array(
'id' => 'none', 'id' => 'none',
@@ -99,7 +99,7 @@ class nginx_phpfpm extends nginx
// create starter-file | config-file // create starter-file | config-file
$php->getInterface()->createConfig($phpconfig); $php->getInterface()->createConfig($phpconfig);
// create php.ini // create php.ini
// @TODO make php-fpm support this // @TODO make php-fpm support this
$php->getInterface()->createIniFile($phpconfig); $php->getInterface()->createIniFile($phpconfig);
} }

View File

@@ -118,7 +118,7 @@ while($row = $db->fetch_array($result_tasks))
// now get rid of old stuff // now get rid of old stuff
//(but append /* so we don't delete the directory) //(but append /* so we don't delete the directory)
$configdir.='/*'; $configdir.='/*';
safe_exec('rm -rf '. makeCorrectFile($configdir)); safe_exec('rm -rf '. escapeshellarg(makeCorrectFile($configdir)));
} }
} }
@@ -132,7 +132,7 @@ while($row = $db->fetch_array($result_tasks))
// now get rid of old stuff // now get rid of old stuff
//(but append /* so we don't delete the directory) //(but append /* so we don't delete the directory)
$configdir.='/*'; $configdir.='/*';
safe_exec('rm -rf '. makeCorrectFile($configdir)); safe_exec('rm -rf '. escapeshellarg(makeCorrectFile($configdir)));
} }
} }
@@ -264,7 +264,7 @@ while($row = $db->fetch_array($result_tasks))
elseif ($row['type'] == '5') elseif ($row['type'] == '5')
{ {
$cronlog->logAction(CRON_ACTION, LOG_INFO, 'Creating new FTP-home'); $cronlog->logAction(CRON_ACTION, LOG_INFO, 'Creating new FTP-home');
$result_directories = $db->query('SELECT `f`.`homedir`, `f`.`uid`, `f`.`gid`, `c`.`documentroot` AS `customerroot` FROM `' . TABLE_FTP_USERS . '` `f` LEFT JOIN `' . TABLE_PANEL_CUSTOMERS . '` `c` USING (`customerid`) '); $result_directories = $db->query('SELECT `f`.`homedir`, `f`.`uid`, `f`.`gid`, `c`.`documentroot` AS `customerroot` FROM `' . TABLE_FTP_USERS . '` `f` LEFT JOIN `' . TABLE_PANEL_CUSTOMERS . '` `c` USING (`customerid`) WHERE `f`.`username` NOT LIKE \'%_backup\'');
while($directory = $db->fetch_array($result_directories)) while($directory = $db->fetch_array($result_directories))
{ {

View File

@@ -199,6 +199,35 @@ while($row = $db->fetch_array($result))
// make the stuff readable for the customer, #258 // make the stuff readable for the customer, #258
makeChownWithNewStats($row); makeChownWithNewStats($row);
// logrotate
if($settings['system']['logrotate_enabled'] == '1')
{
fwrite($debugHandler, ' logrotate customers logs' . "\n");
$logrotatefile = '/tmp/froxlor_logrotate_tmpfile.conf';
$fh = fopen($logrotatefile, 'w');
$logconf = '# ' . basename($logrotatefile) . "\n" . '# Created ' . date('d.m.Y H:i') . "\n" .
$settings['system']['logfiles_directory'] . $row['loginname'] . '-access.log ' .
$settings['system']['logfiles_directory'] . $row['loginname'] . '-error.log {' . "\n" .
$settings['system']['logrotate_interval'] . "\n" .
'missingok' . "\n" .
'rotate ' . $settings['system']['logrotate_keep'] . "\n" .
'compress' . "\n" .
'delaycompress' . "\n" .
'notifempty' . "\n" .
'create' . "\n" .
'}' . "\n";
fwrite($fh, $logconf);
fclose($fh);
safe_exec(escapeshellcmd($settings['system']['logrotate_binary']) . ' ' . $logrotatefile);
fwrite($debugHandler, ' apache::reload: reloading apache' . "\n");
safe_exec(escapeshellcmd($settings['system']['apachereload_command']));
}
/** /**
* Webalizer/AWStats might run for some time, so we'd better check if our database is still present * Webalizer/AWStats might run for some time, so we'd better check if our database is still present
@@ -379,7 +408,6 @@ while($row = $db->fetch_array($result))
* Total Usage * Total Usage
*/ */
$diskusage = floatval($webspaceusage + $emailusage + $mysqlusage);
if($settings['system']['backup_count'] == 0 && file_exists($settings['system']['backup_dir'] . $row['loginname'])){ if($settings['system']['backup_count'] == 0 && file_exists($settings['system']['backup_dir'] . $row['loginname'])){
$backupsize = exec('du -s ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . ''); $backupsize = exec('du -s ' . escapeshellarg($settings['system']['backup_dir']) . $row['loginname'] . '');
$diskusage = floatval($webspaceusage + $emailusage + $mysqlusage - $backupsize); $diskusage = floatval($webspaceusage + $emailusage + $mysqlusage - $backupsize);
@@ -405,7 +433,7 @@ while($row = $db->fetch_array($result))
$result_quota = $db->query("SELECT homedir FROM `" . TABLE_FTP_USERS . "` WHERE customerid = '" . $row['customerid'] . "'"); $result_quota = $db->query("SELECT homedir FROM `" . TABLE_FTP_USERS . "` WHERE customerid = '" . $row['customerid'] . "'");
// get correct user // get correct user
if($settings['system']['mod_fcgid'] == 1) if($settings['system']['mod_fcgid'] == 1 && $row['deactivated'] == '0')
{ {
$user = $row['loginname']; $user = $row['loginname'];
$group = $row['loginname']; $group = $row['loginname'];

View File

@@ -3,7 +3,7 @@
<td class="field_name">{$ticket['ticket_answers']}</td> <td class="field_name">{$ticket['ticket_answers']}</td>
<td class="field_name">{$ticket['subject']}</td> <td class="field_name">{$ticket['subject']}</td>
<td class="field_name">{$ticket['lastreplier']}</td> <td class="field_name">{$ticket['lastreplier']}</td>
<td class="field_name">{$ticket['priority']}</td> <td class="field_name"><span class="ticket_{$ticket['display']}">{$ticket['priority']}</span></td>
<td class="field_name"> <td class="field_name">
<a href="{$linker->getLink(array('section' => 'tickets', 'page' => 'archive', 'action' => 'view', 'id' => $ticket['id']))}">{$lng['ticket']['show']}</a> <a href="{$linker->getLink(array('section' => 'tickets', 'page' => 'archive', 'action' => 'view', 'id' => $ticket['id']))}">{$lng['ticket']['show']}</a>
</td> </td>

View File

@@ -15,6 +15,7 @@ $header
<tr> <tr>
<td class="field_display_border_left">{$lng['mysql']['databasename']}&nbsp;&nbsp;{$arrowcode['databasename']}</td> <td class="field_display_border_left">{$lng['mysql']['databasename']}&nbsp;&nbsp;{$arrowcode['databasename']}</td>
<td class="field_display">{$lng['mysql']['databasedescription']}&nbsp;&nbsp;{$arrowcode['description']}</td> <td class="field_display">{$lng['mysql']['databasedescription']}&nbsp;&nbsp;{$arrowcode['description']}</td>
<td class="field_display">{$lng['mysql']['size']}</td>
<if 1 < count($sql_root)><td class="field_display">{$lng['mysql']['mysql_server']}</td></if> <if 1 < count($sql_root)><td class="field_display">{$lng['mysql']['mysql_server']}</td></if>
<td class="field_display_search" colspan="2">{$sortcode}</td> <td class="field_display_search" colspan="2">{$sortcode}</td>
</tr> </tr>
@@ -33,4 +34,4 @@ $header
</form> </form>
<br /> <br />
<br /> <br />
$footer $footer

View File

@@ -1,6 +1,7 @@
<tr class="" onmouseover="this.className='RowOverSelected';" onmouseout="this.className='';"> <tr class="" onmouseover="this.className='RowOverSelected';" onmouseout="this.className='';">
<td class="field_name_border_left">{$row['databasename']}</td> <td class="field_name_border_left">{$row['databasename']}</td>
<td class="field_name">{$row['description']}</td> <td class="field_name">{$row['description']}</td>
<td class="field_name">{$row['size']}</td>
<if 1 < count($sql_root)><td class="field_name">{$sql_root[$row['dbserver']]['caption']}</td></if> <if 1 < count($sql_root)><td class="field_name">{$sql_root[$row['dbserver']]['caption']}</td></if>
<if $row['apsdb'] != '1'> <if $row['apsdb'] != '1'>
<td class="field_name"><a href="{$linker->getLink(array('section' => 'mysql', 'page' => 'mysqls', 'action' => 'edit', 'id' => $row['id']))}">{$lng['panel']['edit']}</a></td> <td class="field_name"><a href="{$linker->getLink(array('section' => 'mysql', 'page' => 'mysqls', 'action' => 'edit', 'id' => $row['id']))}">{$lng['panel']['edit']}</a></td>

View File

@@ -0,0 +1,4 @@
<tr>
<td class="main_field_name">{$label}</td>
<td class="main_field_display" nowrap="nowrap"><input type="password" class="text" name="{$fieldname}" value="{$value}" /></td>
</tr>

View File

@@ -9,6 +9,7 @@
<link rel="stylesheet" href="templates/Classic/main.css" type="text/css" /> <link rel="stylesheet" href="templates/Classic/main.css" type="text/css" />
<script type="text/javascript" src="templates/Classic/js/jquery.min.js"></script> <script type="text/javascript" src="templates/Classic/js/jquery.min.js"></script>
<script type="text/javascript" src="templates/Classic/js/froxlor.js"></script> <script type="text/javascript" src="templates/Classic/js/froxlor.js"></script>
<link rel="icon" href="images/favicon.ico" type="image/x-icon" />
<title><if isset($userinfo['loginname']) && $userinfo['loginname'] != ''>{$userinfo['loginname']} - </if>Froxlor</title> <title><if isset($userinfo['loginname']) && $userinfo['loginname'] != ''>{$userinfo['loginname']} - </if>Froxlor</title>
</head> </head>
<body style="margin: 0; padding: 0;"> <body style="margin: 0; padding: 0;">

View File

@@ -19,7 +19,7 @@
<else> <else>
<span> <span>
</if> </if>
<em style="left: {$doublepercent}px;">{$percent}%</em></span> <em style="left: {$disk_doublepercent}px;">{$disk_percent}%</em></span>
</span> </span>
<else> <else>
<span class="progressBar" title="{$lng['customer']['unlimited']}"> <span class="progressBar" title="{$lng['customer']['unlimited']}">
@@ -36,7 +36,7 @@
<else> <else>
<span> <span>
</if> </if>
<em style="left: {$doublepercent}px;">{$percent}%</em></span> <em style="left: {$traffic_doublepercent}px;">{$traffic_percent}%</em></span>
</span> </span>
<else> <else>
<span class="progressBar" title="{$lng['customer']['unlimited']}"> <span class="progressBar" title="{$lng['customer']['unlimited']}">

View File

@@ -16,66 +16,66 @@ $header
<h2>{$lng['admin']['ressourcedetails']}</h2> <h2>{$lng['admin']['ressourcedetails']}</h2>
<table> <table>
<tr> <tr>
<td>{$lng['admin']['customers']}:</td> <td>{$lng['admin']['customers']} ({$lng['admin']['usedmax']}):</td>
<td>{$overview['number_customers']} ({$userinfo['customers']})</td> <td>{$overview['number_customers']} ({$userinfo['customers']})</td>
</tr> </tr>
<tr> <tr>
<td>{$lng['customer']['domains']}:</td> <td>{$lng['customer']['domains']} ({$lng['admin']['usedmax']}):</td>
<td>{$overview['number_domains']} ({$userinfo['domains']})</td> <td>{$overview['number_domains']} ({$userinfo['domains']})</td>
</tr> </tr>
<tr> <tr>
<td>{$lng['customer']['subdomains']}:</td> <td>{$lng['customer']['subdomains']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['subdomains_used']} ({$userinfo['subdomains_used']}/{$userinfo['subdomains']})</td> <td>{$overview['subdomains_used']} ({$userinfo['subdomains_used']}/{$userinfo['subdomains']})</td>
</tr> </tr>
<tr> <tr>
<td>{$lng['customer']['diskspace']}:</td> <td>{$lng['customer']['diskspace']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['diskspace_used']} ({$userinfo['diskspace_used']}/{$userinfo['diskspace']})</td> <td>{$overview['diskspace_used']} ({$userinfo['diskspace_used']}/{$userinfo['diskspace']})</td>
</tr> </tr>
<tr> <tr>
<td>{$lng['customer']['traffic']}:</td> <td>{$lng['customer']['traffic']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['traffic_used']} ({$userinfo['traffic_used']}/{$userinfo['traffic']})</td> <td>{$overview['traffic_used']} ({$userinfo['traffic_used']}/{$userinfo['traffic']})</td>
</tr> </tr>
<tr> <tr>
<td>{$lng['customer']['mysqls']}:</td> <td>{$lng['customer']['mysqls']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['mysqls_used']} ({$userinfo['mysqls_used']}/{$userinfo['mysqls']})</td> <td>{$overview['mysqls_used']} ({$userinfo['mysqls_used']}/{$userinfo['mysqls']})</td>
</tr> </tr>
<tr> <tr>
<td>{$lng['customer']['emails']}:</td> <td>{$lng['customer']['emails']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['emails_used']} ({$userinfo['emails_used']}/{$userinfo['emails']})</td> <td>{$overview['emails_used']} ({$userinfo['emails_used']}/{$userinfo['emails']})</td>
</tr> </tr>
<tr> <tr>
<td>{$lng['customer']['accounts']}:</td> <td>{$lng['customer']['accounts']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['email_accounts_used']} ({$userinfo['email_accounts_used']}/{$userinfo['email_accounts']})</td> <td>{$overview['email_accounts_used']} ({$userinfo['email_accounts_used']}/{$userinfo['email_accounts']})</td>
</tr> </tr>
<tr> <tr>
<td>{$lng['customer']['forwarders']}:</td> <td>{$lng['customer']['forwarders']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['email_forwarders_used']} ({$userinfo['email_forwarders_used']}/{$userinfo['email_forwarders']})</td> <td>{$overview['email_forwarders_used']} ({$userinfo['email_forwarders_used']}/{$userinfo['email_forwarders']})</td>
</tr> </tr>
<if $settings['system']['mail_quota_enabled'] == 1> <if $settings['system']['mail_quota_enabled'] == 1>
<tr> <tr>
<td>{$lng['customer']['email_quota']}:</td> <td>{$lng['customer']['email_quota']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['email_quota_used']} ({$userinfo['email_quota_used']}/{$userinfo['email_quota']})</td> <td>{$overview['email_quota_used']} ({$userinfo['email_quota_used']}/{$userinfo['email_quota']})</td>
</tr> </tr>
</if> </if>
<if $settings['autoresponder']['autoresponder_active'] == 1> <if $settings['autoresponder']['autoresponder_active'] == 1>
<tr> <tr>
<td>{$lng['customer']['autoresponder']}:</td> <td>{$lng['customer']['autoresponder']} ({$lng['admin']['usedmax']}):</td>
<td>{$userinfo['email_autoresponder_used']} ({$userinfo['email_autoresponder']})</td> <td>{$userinfo['email_autoresponder_used']} ({$userinfo['email_autoresponder']})</td>
</tr> </tr>
</if> </if>
<if (int)$settings['aps']['aps_active'] == 1> <if (int)$settings['aps']['aps_active'] == 1>
<tr> <tr>
<td>{$lng['aps']['numberofapspackages']}:</td> <td>{$lng['aps']['numberofapspackages']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['aps_packages_used']} ({$userinfo['aps_packages_used']}/{$userinfo['aps_packages']})</td> <td>{$overview['aps_packages_used']} ({$userinfo['aps_packages_used']}/{$userinfo['aps_packages']})</td>
</tr> </tr>
</if> </if>
<tr> <tr>
<td>{$lng['customer']['ftps']}:</td> <td>{$lng['customer']['ftps']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['ftps_used']} ({$userinfo['ftps_used']}/{$userinfo['ftps']})</td> <td>{$overview['ftps_used']} ({$userinfo['ftps_used']}/{$userinfo['ftps']})</td>
</tr> </tr>
<if $settings['ticket']['enabled'] == 1> <if $settings['ticket']['enabled'] == 1>
<tr> <tr>
<td>{$lng['customer']['tickets']}:</td> <td>{$lng['customer']['tickets']} ({$lng['admin']['used']} ({$lng['admin']['assignedmax']})):</td>
<td>{$overview['tickets_used']} ({$userinfo['tickets_used']}/{$userinfo['tickets']})</td> <td>{$overview['tickets_used']} ({$userinfo['tickets_used']}/{$userinfo['tickets']})</td>
</tr> </tr>
</if> </if>

View File

@@ -3,7 +3,7 @@
<td>{$ticket['ticket_answers']}</td> <td>{$ticket['ticket_answers']}</td>
<td>{$ticket['subject']}</td> <td>{$ticket['subject']}</td>
<td>{$ticket['lastreplier']}</td> <td>{$ticket['lastreplier']}</td>
<td>{$ticket['priority']}</td> <td><span class="ticket_{$ticket['display']}">{$ticket['priority']}</span></td>
<td> <td>
<a href="{$linker->getLink(array('section' => 'tickets', 'page' => 'archive', 'action' => 'view', 'id' => $ticket['id']))}" style="text-decoration:none;"> <a href="{$linker->getLink(array('section' => 'tickets', 'page' => 'archive', 'action' => 'view', 'id' => $ticket['id']))}" style="text-decoration:none;">
<img src="images/Froxlor/icons/ticket_show.png" alt="{$lng['ticket']['show']}"/> <img src="images/Froxlor/icons/ticket_show.png" alt="{$lng['ticket']['show']}"/>

View File

@@ -27,6 +27,7 @@
<tr> <tr>
<th>{$lng['mysql']['databasename']}&nbsp;{$arrowcode['databasename']}</th> <th>{$lng['mysql']['databasename']}&nbsp;{$arrowcode['databasename']}</th>
<th>{$lng['mysql']['databasedescription']}&nbsp;{$arrowcode['description']}</th> <th>{$lng['mysql']['databasedescription']}&nbsp;{$arrowcode['description']}</th>
<th>{$lng['mysql']['size']}</th>
<if 1 < count($sql_root)><th>{$lng['mysql']['mysql_server']}</th></if> <if 1 < count($sql_root)><th>{$lng['mysql']['mysql_server']}</th></if>
<th>{$lng['panel']['options']}</th> <th>{$lng['panel']['options']}</th>
</tr> </tr>

View File

@@ -1,6 +1,7 @@
<tr> <tr>
<td>{$row['databasename']}</td> <td>{$row['databasename']}</td>
<td>{$row['description']}</td> <td>{$row['description']}</td>
<td>{$row['size']}</td>
<if 1 < count($sql_root)><td>{$sql_root[$row['dbserver']]['caption']}</td></if> <if 1 < count($sql_root)><td>{$sql_root[$row['dbserver']]['caption']}</td></if>
<if $row['apsdb'] != '1'> <if $row['apsdb'] != '1'>
<td> <td>

View File

@@ -0,0 +1,4 @@
<tr>
<td>{$label}</td>
<td><input type="password" class="text" name="{$fieldname}" value="{$value}" /></td>
</tr>

View File

@@ -12,6 +12,7 @@
<!--[if lt IE 9]><script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]--> <!--[if lt IE 9]><script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
<script type="text/javascript" src="templates/Froxlor/js/jquery.min.js"></script> <script type="text/javascript" src="templates/Froxlor/js/jquery.min.js"></script>
<script type="text/javascript" src="templates/Froxlor/js/froxlor.js"></script> <script type="text/javascript" src="templates/Froxlor/js/froxlor.js"></script>
<link rel="icon" href="images/favicon.ico" type="image/x-icon" />
<title><if isset($userinfo['loginname']) && $userinfo['loginname'] != ''>{$userinfo['loginname']} - </if>Froxlor Server Management Panel</title> <title><if isset($userinfo['loginname']) && $userinfo['loginname'] != ''>{$userinfo['loginname']} - </if>Froxlor Server Management Panel</title>
</head> </head>
<body> <body>

View File

@@ -1,25 +1,25 @@
#!/bin/bash #!/bin/bash
BIND=127.0.0.1:8888 BIND="127.0.0.1:8888"
USER=www-data USER="www-data"
PHP_FCGI_CHILDREN=15 PHP_FCGI_CHILDREN="15"
PHP_FCGI_MAX_REQUESTS=1000 PHP_FCGI_MAX_REQUESTS="1000"
PHP_CGI=/usr/bin/php-cgi PHP_CGI="/usr/bin/php-cgi"
PHP_CGI_NAME=`basename $PHP_CGI` PHP_CGI_NAME="$(basename ${PHP_CGI})"
PHP_CGI_ARGS="- USER=$USER PATH=/usr/bin PHP_FCGI_CHILDREN=$PHP_FCGI_CHILDREN PHP_FCGI_MAX_REQUESTS=$PHP_FCGI_MAX_REQUESTS $PHP_CGI -b $BIND" PHP_CGI_ARGS="- USER=${USER} PATH=/usr/bin PHP_FCGI_CHILDREN=${PHP_FCGI_CHILDREN} PHP_FCGI_MAX_REQUESTS=${PHP_FCGI_MAX_REQUESTS} ${PHP_CGI} -b ${BIND}"
RETVAL=0 RETVAL="0"
start() { start() {
echo -n "Starting PHP FastCGI: " echo -n "Starting PHP FastCGI: "
start-stop-daemon --quiet --start --background --chuid "$USER" --exec /usr/bin/env -- $PHP_CGI_ARGS start-stop-daemon --quiet --start --background --chuid "$USER" --exec /usr/bin/env -- "$PHP_CGI_ARGS"
RETVAL=$? RETVAL="$?"
echo "$PHP_CGI_NAME." echo "${PHP_CGI_NAME}."
} }
stop() { stop() {
echo -n "Stopping PHP FastCGI: " echo -n "Stopping PHP FastCGI: "
killall -q -w -u $USER $PHP_CGI killall -q -w -u "${USER} ${PHP_CGI}"
RETVAL=$? RETVAL="$?"
echo "$PHP_CGI_NAME." echo "${PHP_CGI_NAME}."
} }
case "$1" in case "$1" in
@@ -38,4 +38,4 @@ case "$1" in
exit 1 exit 1
;; ;;
esac esac
exit $RETVAL exit "$RETVAL"

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,25 +1,25 @@
#!/bin/bash #!/bin/bash
BIND=127.0.0.1:8888 BIND="127.0.0.1:8888"
USER=www-data USER="www-data"
PHP_FCGI_CHILDREN=15 PHP_FCGI_CHILDREN="15"
PHP_FCGI_MAX_REQUESTS=1000 PHP_FCGI_MAX_REQUESTS="1000"
PHP_CGI=/usr/bin/php-cgi PHP_CGI="/usr/bin/php-cgi"
PHP_CGI_NAME=`basename $PHP_CGI` PHP_CGI_NAME="$(basename ${PHP_CGI})"
PHP_CGI_ARGS="- USER=$USER PATH=/usr/bin PHP_FCGI_CHILDREN=$PHP_FCGI_CHILDREN PHP_FCGI_MAX_REQUESTS=$PHP_FCGI_MAX_REQUESTS $PHP_CGI -b $BIND" PHP_CGI_ARGS="- USER=${USER} PATH=/usr/bin PHP_FCGI_CHILDREN=${PHP_FCGI_CHILDREN} PHP_FCGI_MAX_REQUESTS=${PHP_FCGI_MAX_REQUESTS} ${PHP_CGI} -b ${BIND}"
RETVAL=0 RETVAL="0"
start() { start() {
echo -n "Starting PHP FastCGI: " echo -n "Starting PHP FastCGI: "
start-stop-daemon --quiet --start --background --chuid "$USER" --exec /usr/bin/env -- $PHP_CGI_ARGS start-stop-daemon --quiet --start --background --chuid "$USER" --exec /usr/bin/env -- "$PHP_CGI_ARGS"
RETVAL=$? RETVAL="$?"
echo "$PHP_CGI_NAME." echo "${PHP_CGI_NAME}."
} }
stop() { stop() {
echo -n "Stopping PHP FastCGI: " echo -n "Stopping PHP FastCGI: "
killall -q -w -u $USER $PHP_CGI killall -q -w -u "${USER} ${PHP_CGI}"
RETVAL=$? RETVAL="$?"
echo "$PHP_CGI_NAME." echo "${PHP_CGI_NAME}."
} }
case "$1" in case "$1" in
@@ -38,4 +38,4 @@ case "$1" in
exit 1 exit 1
;; ;;
esac esac
exit $RETVAL exit "$RETVAL"

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,25 +1,25 @@
#!/bin/bash #!/bin/bash
BIND=127.0.0.1:8888 BIND="127.0.0.1:8888"
USER=nginx USER="nginx"
PHP_FCGI_CHILDREN=15 PHP_FCGI_CHILDREN="15"
PHP_FCGI_MAX_REQUESTS=1000 PHP_FCGI_MAX_REQUESTS="1000"
PHP_CGI=/usr/bin/php-cgi PHP_CGI="/usr/bin/php-cgi"
PHP_CGI_NAME=`basename $PHP_CGI` PHP_CGI_NAME="$(basename ${PHP_CGI})"
PHP_CGI_ARGS="- USER=$USER PATH=/usr/bin PHP_FCGI_CHILDREN=$PHP_FCGI_CHILDREN PHP_FCGI_MAX_REQUESTS=$PHP_FCGI_MAX_REQUESTS $PHP_CGI -b $BIND" PHP_CGI_ARGS="- USER=${USER} PATH=/usr/bin PHP_FCGI_CHILDREN=${PHP_FCGI_CHILDREN} PHP_FCGI_MAX_REQUESTS=${PHP_FCGI_MAX_REQUESTS} ${PHP_CGI} -b ${BIND}"
RETVAL=0 RETVAL="0"
start() { start() {
echo -n "Starting PHP FastCGI: " echo -n "Starting PHP FastCGI: "
start-stop-daemon --quiet --start --background --chuid "$USER" --exec /usr/bin/env -- $PHP_CGI_ARGS start-stop-daemon --quiet --start --background --chuid "$USER" --exec /usr/bin/env -- "$PHP_CGI_ARGS"
RETVAL=$? RETVAL="$?"
echo "$PHP_CGI_NAME." echo "${PHP_CGI_NAME}."
} }
stop() { stop() {
echo -n "Stopping PHP FastCGI: " echo -n "Stopping PHP FastCGI: "
killall -q -w -u $USER $PHP_CGI killall -q -w -u "${USER} ${PHP_CGI}"
RETVAL=$? RETVAL="$?"
echo "$PHP_CGI_NAME." echo "${PHP_CGI_NAME}."
} }
case "$1" in case "$1" in
@@ -38,4 +38,4 @@ case "$1" in
exit 1 exit 1
;; ;;
esac esac
exit $RETVAL exit "$RETVAL"

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,25 +1,25 @@
#!/bin/bash #!/bin/bash
BIND=127.0.0.1:8888 BIND="127.0.0.1:8888"
USER=www-data USER="www-data"
PHP_FCGI_CHILDREN=15 PHP_FCGI_CHILDREN="15"
PHP_FCGI_MAX_REQUESTS=1000 PHP_FCGI_MAX_REQUESTS="1000"
PHP_CGI=/usr/bin/php-cgi PHP_CGI="/usr/bin/php-cgi"
PHP_CGI_NAME=`basename $PHP_CGI` PHP_CGI_NAME="$(basename ${PHP_CGI})"
PHP_CGI_ARGS="- USER=$USER PATH=/usr/bin PHP_FCGI_CHILDREN=$PHP_FCGI_CHILDREN PHP_FCGI_MAX_REQUESTS=$PHP_FCGI_MAX_REQUESTS $PHP_CGI -b $BIND" PHP_CGI_ARGS="- USER=${USER} PATH=/usr/bin PHP_FCGI_CHILDREN=${PHP_FCGI_CHILDREN} PHP_FCGI_MAX_REQUESTS=${PHP_FCGI_MAX_REQUESTS} ${PHP_CGI} -b ${BIND}"
RETVAL=0 RETVAL="0"
start() { start() {
echo -n "Starting PHP FastCGI: " echo -n "Starting PHP FastCGI: "
start-stop-daemon --quiet --start --background --chuid "$USER" --exec /usr/bin/env -- $PHP_CGI_ARGS start-stop-daemon --quiet --start --background --chuid "$USER" --exec /usr/bin/env -- "$PHP_CGI_ARGS"
RETVAL=$? RETVAL="$?"
echo "$PHP_CGI_NAME." echo "${PHP_CGI_NAME}."
} }
stop() { stop() {
echo -n "Stopping PHP FastCGI: " echo -n "Stopping PHP FastCGI: "
killall -q -w -u $USER $PHP_CGI killall -q -w -u "${USER} ${PHP_CGI}"
RETVAL=$? RETVAL="$?"
echo "$PHP_CGI_NAME." echo "${PHP_CGI_NAME}."
} }
case "$1" in case "$1" in
@@ -38,4 +38,4 @@ case "$1" in
exit 1 exit 1
;; ;;
esac esac
exit $RETVAL exit "$RETVAL"

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) > '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = mail_virtual table = mail_virtual
select_field = destination select_field = destination
where_field = email where_field = email
additional_conditions = and TRIM(destination) <> '' additional_conditions = and TRIM(destination) <> '' and destination in (select destination from mail_users where email ='%s' and postfix = 'Y')
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,5 +4,5 @@ dbname = <SQL_DB>
table = panel_domains table = panel_domains
select_field = domain select_field = domain
where_field = domain where_field = domain
additional_conditions = and isemaildomain = '1' additional_conditions = and isemaildomain = '1' and deactivated = '0'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -4,4 +4,5 @@ dbname = <SQL_DB>
table = mail_users table = mail_users
select_field = maildir select_field = maildir
where_field = email where_field = email
additional_conditions = and postfix = 'Y'
hosts = <SQL_HOST> hosts = <SQL_HOST>

View File

@@ -1,5 +1,5 @@
user = <SQL_UNPRIVILEGED_USER> user = <SQL_UNPRIVILEGED_USER>
password = <SQL_UNPRIVILEGED_PASSWORD> password = <SQL_UNPRIVILEGED_PASSWORD>
dbname = <SQL_DB> dbname = <SQL_DB>
query = select distinct username from mail_users where email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s')); query = select distinct username from mail_users where postfix = 'Y' and email in ((select mail_virtual.email_full from mail_virtual where mail_virtual.email = '%s' union select mail_virtual.destination from mail_virtual where mail_virtual.email = '%s'));
hosts = <SQL_HOST> hosts = <SQL_HOST>