Skip to content

Commit aa027c6

Browse files
author
Till Brehm
committed
Merge branch '5635-confidential-issue' of git.ispconfig.org:ispconfig-confidential/ispconfig3 into 5635-confidential-issue
2 parents c65fdb2 + 58e3ea6 commit aa027c6

File tree

641 files changed

+4355
-2252
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

641 files changed

+4355
-2252
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
.DS_Store
22
/nbproject/private/
33
.phplint-cache
4+
*.swp

install/dist/lib/fedora.lib.php

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,12 @@ function configure_postfix($options = '')
6363
//* mysql-virtual_forwardings.cf
6464
$this->process_postfix_config('mysql-virtual_forwardings.cf');
6565

66+
//* mysql-virtual_alias_domains.cf
67+
$this->process_postfix_config('mysql-virtual_alias_domains.cf');
68+
69+
//* mysql-virtual_alias_maps.cf
70+
$this->process_postfix_config('mysql-virtual_alias_maps.cf');
71+
6672
//* mysql-virtual_mailboxes.cf
6773
$this->process_postfix_config('mysql-virtual_mailboxes.cf');
6874

@@ -102,6 +108,9 @@ function configure_postfix($options = '')
102108
//* mysql-virtual_uids.cf
103109
$this->process_postfix_config('mysql-virtual_uids.cf');
104110

111+
//* mysql-virtual_alias_domains.cf
112+
$this->process_postfix_config('mysql-verify_recipients.cf');
113+
105114
//* postfix-dkim
106115
$filename='tag_as_originating.re';
107116
$full_file_name=$config_dir.'/'.$filename;
@@ -115,12 +124,6 @@ function configure_postfix($options = '')
115124
$content = rfsel($conf['ispconfig_install_dir'].'/server/conf-custom/install/postfix-'.$filename.'.master', 'tpl/postfix-'.$filename.'.master');
116125
wf($full_file_name, $content);
117126

118-
//* Changing mode and group of the new created config files.
119-
caselog('chmod o= '.$config_dir.'/mysql-virtual_*.cf* &> /dev/null',
120-
__FILE__, __LINE__, 'chmod on mysql-virtual_*.cf*', 'chmod on mysql-virtual_*.cf* failed');
121-
caselog('chgrp '.$cf['group'].' '.$config_dir.'/mysql-virtual_*.cf* &> /dev/null',
122-
__FILE__, __LINE__, 'chgrp on mysql-virtual_*.cf*', 'chgrp on mysql-virtual_*.cf* failed');
123-
124127
//* Creating virtual mail user and group
125128
$command = 'groupadd -g '.$cf['vmail_groupid'].' '.$cf['vmail_groupname'];
126129
if(!is_group($cf['vmail_groupname'])) caselog($command.' &> /dev/null', __FILE__, __LINE__, "EXECUTED: $command", "Failed to execute the command $command");
@@ -150,9 +153,16 @@ function configure_postfix($options = '')
150153
}
151154

152155
$reject_sender_login_mismatch = '';
156+
$reject_authenticated_sender_login_mismatch = '';
153157
if(isset($server_ini_array['mail']['reject_sender_login_mismatch']) && ($server_ini_array['mail']['reject_sender_login_mismatch'] == 'y')) {
154-
$reject_sender_login_mismatch = ', reject_authenticated_sender_login_mismatch';
158+
$reject_sender_login_mismatch = ', reject_sender_login_mismatch';
159+
$reject_authenticated_sender_login_mismatch = 'reject_authenticated_sender_login_mismatch, ';
155160
}
161+
162+
# placeholder includes comment char
163+
$stress_adaptive_placeholder = '#{stress_adaptive} ';
164+
$stress_adaptive = (isset($server_ini_array['mail']['stress_adaptive']) && ($server_ini_array['mail']['stress_adaptive'] == 'y')) ? '' : $stress_adaptive_placeholder;
165+
156166
unset($server_ini_array);
157167

158168
$postconf_placeholders = array('{config_dir}' => $config_dir,
@@ -162,6 +172,8 @@ function configure_postfix($options = '')
162172
'{rbl_list}' => $rbl_list,
163173
'{greylisting}' => $greylisting,
164174
'{reject_slm}' => $reject_sender_login_mismatch,
175+
'{reject_aslm}' => $reject_authenticated_sender_login_mismatch,
176+
$stress_adaptive_placeholder => $stress_adaptive,
165177
);
166178

167179
$postconf_tpl = rfsel($conf['ispconfig_install_dir'].'/server/conf-custom/install/fedora_postfix.conf.master', 'tpl/fedora_postfix.conf.master');

install/dist/lib/gentoo.lib.php

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,16 @@ public function configure_postfix($options = '')
102102
}
103103

104104
$reject_sender_login_mismatch = '';
105+
$reject_authenticated_sender_login_mismatch = '';
105106
if(isset($server_ini_array['mail']['reject_sender_login_mismatch']) && ($server_ini_array['mail']['reject_sender_login_mismatch'] == 'y')) {
106-
$reject_sender_login_mismatch = ', reject_authenticated_sender_login_mismatch';
107+
$reject_sender_login_mismatch = ', reject_sender_login_mismatch';
108+
$reject_authenticated_sender_login_mismatch = 'reject_authenticated_sender_login_mismatch, ';
107109
}
110+
111+
# placeholder includes comment char
112+
$stress_adaptive_placeholder = '#{stress_adaptive} ';
113+
$stress_adaptive = (isset($server_ini_array['mail']['stress_adaptive']) && ($server_ini_array['mail']['stress_adaptive'] == 'y')) ? '' : $stress_adaptive_placeholder;
114+
108115
unset($server_ini_array);
109116

110117
$postconf_placeholders = array('{config_dir}' => $config_dir,
@@ -114,6 +121,8 @@ public function configure_postfix($options = '')
114121
'{rbl_list}' => $rbl_list,
115122
'{greylisting}' => $greylisting,
116123
'{reject_slm}' => $reject_sender_login_mismatch,
124+
'{reject_aslm}' => $reject_authenticated_sender_login_mismatch,
125+
$stress_adaptive_placeholder => $stress_adaptive,
117126
);
118127

119128
$postconf_tpl = rfsel($conf['ispconfig_install_dir'].'/server/conf-custom/install/gentoo_postfix.conf.master', 'tpl/gentoo_postfix.conf.master');
@@ -338,6 +347,11 @@ public function configure_dovecot()
338347
replaceLine($config_dir.'/'.$configfile, 'protocols = imap pop3', 'protocols = imap pop3 lmtp', 1, 0);
339348
}
340349

350+
//* Get the dovecot version
351+
exec('dovecot --version', $tmp);
352+
$dovecot_version = $tmp[0];
353+
unset($tmp);
354+
341355
//* dovecot-sql.conf
342356
$configfile = $config_dir.'/dovecot-sql.conf';
343357
$content = $this->get_template_file('debian_dovecot-sql.conf', true, true);

install/dist/lib/opensuse.lib.php

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,12 @@ function configure_postfix($options = '')
6363
//* mysql-virtual_forwardings.cf
6464
$this->process_postfix_config('mysql-virtual_forwardings.cf');
6565

66+
//* mysql-virtual_alias_domains.cf
67+
$this->process_postfix_config('mysql-virtual_alias_domains.cf');
68+
69+
//* mysql-virtual_alias_maps.cf
70+
$this->process_postfix_config('mysql-virtual_alias_maps.cf');
71+
6672
//* mysql-virtual_mailboxes.cf
6773
$this->process_postfix_config('mysql-virtual_mailboxes.cf');
6874

@@ -99,6 +105,9 @@ function configure_postfix($options = '')
99105
//* mysql-virtual_uids.cf
100106
$this->process_postfix_config('mysql-virtual_uids.cf');
101107

108+
//* mysql-virtual_alias_domains.cf
109+
$this->process_postfix_config('mysql-verify_recipients.cf');
110+
102111
//* postfix-dkim
103112
$filename='tag_as_originating.re';
104113
$full_file_name=$config_dir.'/'.$filename;
@@ -112,12 +121,6 @@ function configure_postfix($options = '')
112121
$content = rfsel($conf['ispconfig_install_dir'].'/server/conf-custom/install/postfix-'.$filename.'.master', 'tpl/postfix-'.$filename.'.master');
113122
wf($full_file_name, $content);
114123

115-
//* Changing mode and group of the new created config files.
116-
caselog('chmod o= '.$config_dir.'/mysql-virtual_*.cf* &> /dev/null',
117-
__FILE__, __LINE__, 'chmod on mysql-virtual_*.cf*', 'chmod on mysql-virtual_*.cf* failed');
118-
caselog('chgrp '.$cf['group'].' '.$config_dir.'/mysql-virtual_*.cf* &> /dev/null',
119-
__FILE__, __LINE__, 'chgrp on mysql-virtual_*.cf*', 'chgrp on mysql-virtual_*.cf* failed');
120-
121124
if(!is_dir($cf['vmail_mailbox_base'])) mkdir($cf['vmail_mailbox_base']);
122125

123126
//* Creating virtual mail user and group
@@ -161,9 +164,16 @@ function configure_postfix($options = '')
161164
}
162165

163166
$reject_sender_login_mismatch = '';
167+
$reject_authenticated_sender_login_mismatch = '';
164168
if(isset($server_ini_array['mail']['reject_sender_login_mismatch']) && ($server_ini_array['mail']['reject_sender_login_mismatch'] == 'y')) {
165-
$reject_sender_login_mismatch = ', reject_authenticated_sender_login_mismatch';
169+
$reject_sender_login_mismatch = ', reject_sender_login_mismatch';
170+
$reject_authenticated_sender_login_mismatch = 'reject_authenticated_sender_login_mismatch, ';
166171
}
172+
173+
# placeholder includes comment char
174+
$stress_adaptive_placeholder = '#{stress_adaptive} ';
175+
$stress_adaptive = (isset($server_ini_array['mail']['stress_adaptive']) && ($server_ini_array['mail']['stress_adaptive'] == 'y')) ? '' : $stress_adaptive_placeholder;
176+
167177
unset($server_ini_array);
168178

169179
$postconf_placeholders = array('{config_dir}' => $config_dir,
@@ -173,6 +183,8 @@ function configure_postfix($options = '')
173183
'{rbl_list}' => $rbl_list,
174184
'{greylisting}' => $greylisting,
175185
'{reject_slm}' => $reject_sender_login_mismatch,
186+
'{reject_aslm}' => $reject_authenticated_sender_login_mismatch,
187+
$stress_adaptive_placeholder => $stress_adaptive,
176188
);
177189

178190
$postconf_tpl = rfsel($conf['ispconfig_install_dir'].'/server/conf-custom/install/opensuse_postfix.conf.master', 'tpl/opensuse_postfix.conf.master');

0 commit comments

Comments
 (0)