Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
ISPConfig 3
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Dirk Dankhoff
ISPConfig 3
Commits
5cc181a9
Commit
5cc181a9
authored
Sep 18, 2015
by
Marius Cramer
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into 'master'
Master See merge request !230
parents
b3ada521
7c980c30
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
14 deletions
+31
-14
install/dist/tpl/gentoo/amavisd-ispconfig.conf.master
install/dist/tpl/gentoo/amavisd-ispconfig.conf.master
+13
-5
install/tpl/amavisd_user_config.master
install/tpl/amavisd_user_config.master
+11
-6
server/plugins-available/mail_plugin_dkim.inc.php
server/plugins-available/mail_plugin_dkim.inc.php
+7
-3
No files found.
install/dist/tpl/gentoo/amavisd-ispconfig.conf.master
View file @
5cc181a9
...
...
@@ -94,16 +94,24 @@ $LOGFILE = "/var/log/amavis.log"; # (defaults to empty, no log)
$log_level = 0; # (defaults to 0)
$inet_socket_port = [10024,10026];
$forward_method = 'smtp:[127.0.0.1]:10025';
$notify_method = 'smtp:[127.0.0.1]:10027';
# *:* = send to IP/HOST:incoming Port + 1
$forward_method = 'smtp:*:*';
$notify_method = 'smtp:*:*';
$interface_policy{'10026'} = 'ORIGINATING';
$policy_bank{'ORIGINATING'} = {
originating => 1,
smtpd_discard_ehlo_keywords => ['8BITMIME'],
forward_method => 'smtp:[127.0.0.1]:10027',
};
@mynetworks = qw(0.0.0.0/8 127.0.0.0/8 10.0.0.0/8 172.16.0.0/12
192.168.0.0/16);
# IP-Addresses for internal networks => load policy MYNETS
# - requires -o smtp_send_xforward_command=yes in postfix master.cf
@mynetworks = qw(0.0.0.0/8 127.0.0.0/8 10.0.0.0/8 172.16.0.0/12 192.168.0.0/16 [::1] [FE80::]/10 [FEC0::]/10);
# Allow SMTP access from IPs in @inet_acl to amvisd SMTP Port
@inet_acl = qw( 127.0.0.1 [::1] 192.168.0.0/16 );
$signed_header_fields{'received'} = 0; # turn off signing of Received
$enable_dkim_verification = 1;
$enable_dkim_signing = 1;
...
...
install/tpl/amavisd_user_config.master
View file @
5cc181a9
...
...
@@ -76,19 +76,24 @@ $LOGFILE = "/var/log/amavis.log"; # (defaults to empty, no log)
$log_level = 0; # (defaults to 0)
$inet_socket_port = [10024,10026];
$forward_method = 'smtp:[127.0.0.1]:10025';
$notify_method = 'smtp:[127.0.0.1]:10027';
# *:* = send to IP/HOST:incoming Port + 1
$forward_method = 'smtp:*:*';
$notify_method = 'smtp:*:*';
$interface_policy{'10026'} = 'ORIGINATING';
$policy_bank{'ORIGINATING'} = {
originating => 1,
smtpd_discard_ehlo_keywords => ['8BITMIME'],
forward_method => 'smtp:[127.0.0.1]:10027',
};
@mynetworks = qw(0.0.0.0/8 127.0.0.0/8 10.0.0.0/8 172.16.0.0/12
192.168.0.0/16);
# DKIM
# IP-Addresses for internal networks => load policy MYNETS
# - requires -o smtp_send_xforward_command=yes in postfix master.cf
@mynetworks = qw(0.0.0.0/8 127.0.0.0/8 10.0.0.0/8 172.16.0.0/12 192.168.0.0/16 [::1] [FE80::]/10 [FEC0::]/10);
# Allow SMTP access from IPs in @inet_acl to amvisd SMTP Port
@inet_acl = qw( 127.0.0.1 [::1] 192.168.0.0/16 );
# DKIM
$enable_dkim_verification = 1;
$enable_dkim_signing = 1; # load DKIM signing code
$signed_header_fields{'received'} = 0; # turn off signing of Received
...
...
server/plugins-available/mail_plugin_dkim.inc.php
View file @
5cc181a9
...
...
@@ -122,8 +122,8 @@ class mail_plugin_dkim {
$mail_config
=
$app
->
getconf
->
get_server_config
(
$conf
[
'server_id'
],
'mail'
);
if
(
isset
(
$mail_config
[
'dkim_path'
])
&&
!
empty
(
$mail_config
[
'dkim_path'
])
&&
isset
(
$data
[
'new'
][
'dkim_private'
])
&&
!
empty
(
$data
[
'new'
][
'dkim_private'
])
&&
//
isset($data['new']['dkim_private']) &&
//
!empty($data['new']['dkim_private']) &&
$mail_config
[
'dkim_path'
]
!=
'/'
)
{
if
(
!
is_dir
(
$mail_config
[
'dkim_path'
]))
{
...
...
@@ -199,6 +199,10 @@ class mail_plugin_dkim {
function
write_dkim_key
(
$key_file
,
$key_value
,
$key_domain
)
{
global
$app
,
$mailconfig
;
$success
=
false
;
if
(
$key_file
==
''
||
$key_value
==
''
||
$key_domain
==
''
)
{
$app
->
log
(
'DKIM internal error for domain '
.
$key_domain
,
LOGLEVEL_ERROR
);
return
$success
;
}
if
(
$app
->
system
->
file_put_contents
(
$key_file
.
'.private'
,
$key_value
)
)
{
$app
->
log
(
'Saved DKIM Private-key to '
.
$key_file
.
'.private'
,
LOGLEVEL_DEBUG
);
$success
=
true
;
...
...
@@ -211,7 +215,7 @@ class mail_plugin_dkim {
$app
->
log
(
'Saved DKIM Public to '
.
$key_domain
.
'.'
,
LOGLEVEL_DEBUG
);
else
$app
->
log
(
'Unable to save DKIM Public to '
.
$key_domain
.
'.'
,
LOGLEVEL_DEBUG
);
}
else
{
$app
->
log
(
'Unable to save DKIM Privte-key to '
.
$key_file
.
'.private'
,
LOGLEVEL_ERROR
);
$app
->
log
(
'Unable to save DKIM Priv
a
te-key to '
.
$key_file
.
'.private'
,
LOGLEVEL_ERROR
);
}
return
$success
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment