sieve_notify_mailto_envelope_from
| Default | [None] |
|---|---|
| Value | string |
| See Also |
Defines the source of the notification sender address for e-mail notifications.
Note: This is pre-release documentation.
Please access https://doc.dovecot.org/latest/ for documentation on released versions.
The Sieve enotify extension (RFC 5435) adds the notify action to the Sieve language.
sieve_notify_mailto_envelope_from| Default | [None] |
|---|---|
| Value | string |
| See Also |
Defines the source of the notification sender address for e-mail notifications.
sieve_notify_mailto_max_headers| Default | 16 |
|---|---|
| Value | unsigned integer |
| See Also | |
| Changes |
|
| Advanced Setting; this should not normally be changed. | |
The maximum number of additional headers a single mailto: notify action
may specify in its URI.
0 means no limit on the number of headers is enforced.
sieve_notify_mailto_max_recipients| Default | 8 |
|---|---|
| Value | unsigned integer |
| See Also | |
| Changes |
|
| Advanced Setting; this should not normally be changed. | |
The maximum number of recipients a single mailto: notify action may
specify, counted across the URI and any to/cc/bcc headers.
0 means no limit on the number of recipients is enforced.
sieve_notify_max_notifications| Default | 10 |
|---|---|
| Value | unsigned integer |
| See Also | |
| Changes |
|
| Advanced Setting; this should not normally be changed. | |
The maximum number of notify actions (RFC 5435) that can be performed
during a single script execution.
0 means notify is prohibited; scripts using the notify command will
fail to compile with "local policy prohibits the use of a notify action".
Note that this is independent of sieve_max_redirects; the
redirect action and the notify mailto method are governed by
separate limits.
The effective per-script limit on notify actions is
min(sieve_notify_max_notifications, sieve_max_actions): when the total
number of actions in a script reaches sieve_max_actions
(default 32), execution aborts with "total number of actions
exceeds policy limit" before this per-class limit is reached. To
allow more than sieve_max_actions notify actions, raise
that setting as well.
require ["enotify", "fileinto", "variables"];
if header :contains "from" "boss@example.org" {
notify :importance "1"
:message "This is probably very important"
"mailto:alm@example.com";
# Don't send any further notifications
stop;
}
if header :contains "to" "sievemailinglist@example.org" {
# :matches is used to get the value of the Subject header
if header :matches "Subject" "*" {
set "subject" "${1}";
}
# :matches is used to get the value of the From header
if header :matches "From" "*" {
set "from" "${1}";
}
notify :importance "3"
:message "[SIEVE] ${from}: ${subject}"
"mailto:alm@example.com";
fileinto "INBOX.sieve";
}require ["enotify", "fileinto", "variables", "envelope"];
if header :matches "from" "*@*.example.org" {
# :matches is used to get the MAIL FROM address
if envelope :all :matches "from" "*" {
set "env_from" " [really: ${1}]";
}
# :matches is used to get the value of the Subject header
if header :matches "Subject" "*" {
set "subject" "${1}";
}
# :matches is used to get the address from the From header
if address :matches :all "from" "*" {
set "from_addr" "${1}";
}
notify :message "${from_addr}${env_from}: ${subject}"
"mailto:alm@example.com";
}