You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When building WildDuck Mail Server we decided to not use Sieve and instead went with custom filtering system that is applied to incoming emails and is easy to integrate with a web UI. Basically these are If-This-Then-That rules (example). Such filters cover 90% of use cases required by users.
We did not see any value in actual Sieve mostly because it's a separate programming language (so there might be some security issues if a user is able to come up with a complex enough script). Also most users are not able to write it anyway, so usually it ends up being disguised by the UI into simpler forms.
Sieve has a great upside: it's a standard. So it really helps users switching from an email server to another without having to learn a new filtering DSL and convert all of their filters.
Reacted by Scott Leggett, helmut72, Bernd Stolle, Alexander Adam, Marc Hörsken, Patrycja, Max Mazurov, Felix Krohn, Jonas Heinrich and Jan Koppe
Implement ManageSieve in Maddy so users can use their email clients to upload the filter configs to the server
this could be either be implemented natively in Go or call existing (but old) Python libraries . The protocol looks simple enough so re-implementing in Go might even be easier so we could reuse the STARTTLS support in Maddy.
Add a Sieve parser to Maddy to process the uploaded scripts and generate the scripts out of the sieve configs. Here we could use the C library libsieve as re-implementing in Go might be more work.
Once we get support for several important extensions into it and find a way to re-use Pigeonhole tests suite - it should be ready for integration into maddy. Though we will need a several rounds of refactoring to make IMAPFilter interface flexible enough.
Activity
[-]SIEVE filters support[/-][+]Sieve filters support[/+]foxcpp commentedon Apr 28, 2019
Having ManageSieve protocol too would be nice: https://tools.ietf.org/html/rfc5804
Also, found Sieve lang parser for golang: https://github.com/qingshan/sieve. I wonder if it works...
emersion commentedon May 11, 2019
Yes.
helmut72 commentedon May 21, 2020
Sieve support would be cool. Can't imagine any Imap service without Sieve.
andris9 commentedon May 21, 2020
When building WildDuck Mail Server we decided to not use Sieve and instead went with custom filtering system that is applied to incoming emails and is easy to integrate with a web UI. Basically these are If-This-Then-That rules (example). Such filters cover 90% of use cases required by users.
We did not see any value in actual Sieve mostly because it's a separate programming language (so there might be some security issues if a user is able to come up with a complex enough script). Also most users are not able to write it anyway, so usually it ends up being disguised by the UI into simpler forms.
emersion commentedon May 21, 2020
Sieve has a great upside: it's a standard. So it really helps users switching from an email server to another without having to learn a new filtering DSL and convert all of their filters.
emersion commentedon May 21, 2020
Additionally, Sieve is not Turing-complete (no loops, no functions), so I wouldn't be too worried about complex scripts.
foxcpp commentedon Feb 1, 2022
@angelnu idea for a solution
Implement ManageSieve in Maddy so users can use their email clients to upload the filter configs to the server
this could be either be implemented natively in Go or call existing (but old) Python libraries . The protocol looks simple enough so re-implementing in Go might even be easier so we could reuse the STARTTLS support in Maddy.
Add a Sieve parser to Maddy to process the uploaded scripts and generate the scripts out of the sieve configs. Here we could use the C library libsieve as re-implementing in Go might be more work.
foxcpp commentedon Feb 16, 2022
I implemented a simple interpreter for the base Sieve specification here: https://github.com/foxcpp/go-sieve.
foxcpp commentedon Feb 16, 2022
Once we get support for several important extensions into it and find a way to re-use Pigeonhole tests suite - it should be ready for integration into maddy. Though we will need a several rounds of refactoring to make IMAPFilter interface flexible enough.
hasufell commentedon Dec 6, 2025
Is there any way to set a bounty for this or otherwise contribute financially?