Good Morning!
Hope everyone had a great weekend.
Gentlemen, I am having a bit of an issue getting post sieve script working and if mailcow can get you a SSL cert without even trying, I’m sure I’m doing something wrong. Can you help me please? Thanks…
We are using mailcow for our legacy payroll program to send out payslips to our employees and ofcourse it’s using old TLS / SSL versions that no one will support because you’re obviously a crazyman to even ask, and so…
Payroll smtp 587 tls —> mailcow —> employees (How it’s working)
Payroll smtp 587 tls —> mailcow —> (copyto: Sent folder) —> employees (How I’s like it to work)
I’ve ask Deepseek to make mailcow script for Sieve, and this is what I have…
`require [“fileinto”, “envelope”, “mailbox”, “regex”, “imap4flags”, “copy”, “variables”];
Rule 1: Exact match for e-slips outgoing messages via your SMTP
if allof (
address :is “from” “e-slips@px.ctv.ag”,
anyof (
Mailcow-compatible header matches
header :contains “Received” “from mail.px.ctv.ag [31.220.98.134]”,
header :contains “X-Mailcow-SMTP” “yes”,
header :contains “Received” “ESMTPSA id”,
header :contains “Message-ID” “SMTPIN_ADDED”
)
) {
Mailcow uses “Sent” as default Sent folder
fileinto :copy “Sent”;
# Mailcow-specific flagging
addflag "\\Seen";
addflag "\\Flagged";
stop;
}
Rule 2: Catch other CTV domain messages sent via SMTP
if allof (
address :domain “from” “px.ctv.ag”,
not address :is “from” “e-slips@px.ctv.ag”,
anyof (
header :contains “Received” “ESMTPS id”,
header :contains “X-Mailcow-Auth” “yes”,
header :matches “DKIM-Signature” “s=dkim”
)
) {
fileinto :copy “Sent”;
}
Rule 3: Debugging - log matches to a folder (disable after testing)
if address :is “from” “e-slips@px.ctv.ag” {
fileinto “INBOX.Sieve-Logs”;`
