Spam sieve
Author: b | 2025-04-24
Create a spam sieve filter in Roundcube Create a sieve filter to redirect messages with 'SPAM' in the subject line to a subfolder named Spam. Prerequisites: Access to a Roundcube webmail installation; Install and configure the managesieve plugin for
Create a spam sieve filter in Roundcube
The solution is very similar to Replacing antispam plugin with IMAPSieve,but instead of automatic learning it is supposed to store a copy of the message moved by user for further manual reviewing.In the example below when any user moves a message into or from Junk folder, a copy of the message is placed into report_ham or report_spam folder of spam@example.com mailbox respectively. When a message located in Junk folder replied to or forwarded, a copy of the message is placed into report_spam_reply folder.Requirementspigeonhole v0.4.14 or laterFoldersCreate report_ham, report_spam and report_spam_reply folders in the spam@example.com mailbox.Dovecot configuration20-imap.conf:protocol imap { mail_plugins = $mail_plugins imap_sieve}90-plugin.conf:plugin { sieve_plugins = sieve_imapsieve sieve_extprograms # From elsewhere to Spam folder or flag changed in Spam folder imapsieve_mailbox1_name = Junk imapsieve_mailbox1_causes = COPY FLAG imapsieve_mailbox1_before = file:/usr/local/etc/dovecot/sieve/report-spam.sieve # From Spam folder to elsewhere imapsieve_mailbox2_name = * imapsieve_mailbox2_from = Junk imapsieve_mailbox2_causes = COPY imapsieve_mailbox2_before = file:/usr/local/etc/dovecot/sieve/report-ham.sieve sieve_pipe_bin_dir = /usr/local/libexec/dovecot sieve_global_extensions = +vnd.dovecot.pipe}Sieve scripts/usr/local/etc/dovecot/sieve/report-spam.sieve:require ["vnd.dovecot.pipe", "copy", "imapsieve", "environment", "imap4flags"];if environment :is "imap.cause" "COPY" { pipe :copy "dovecot-lda" [ "-d", "spam@example.com", "-m", "report_spam" ];}# Catch replied or forwarded spamelsif anyof (allof (hasflag "\\Answered", environment :contains "imap.changedflags" "\\Answered"), allof (hasflag "$Forwarded", environment :contains "imap.changedflags" "$Forwarded")) { pipe :copy "dovecot-lda" [ "-d", "spam@example.com", "-m", "report_spam_reply" ];}/usr/local/etc/dovecot/sieve/report-ham.sieve:require ["vnd.dovecot.pipe", "copy", "imapsieve", "environment", "variables"];if environment :matches "imap.mailbox" "*" { set "mailbox" "${1}";}if string "${mailbox}" [ "Trash", "train_ham", "train_prob", "train_spam" ] { stop;}pipe :copy "dovecot-lda" [ "-d", "spam@example.com", "-m", "report_ham" ];Compile Sieve scripts:# sievec /usr/local/etc/dovecot/sieve/report-spam.sieve# sievec /usr/local/etc/dovecot/sieve/report-ham.sieveNow copies of e-mail messages should be placed in the report_ham. Create a spam sieve filter in Roundcube Create a sieve filter to redirect messages with 'SPAM' in the subject line to a subfolder named Spam. Prerequisites: Access to a Roundcube webmail installation; Install and configure the managesieve plugin for After upgrading to macOS Ventura 13.2, Spam Sieve crashes Apple Mail. To make it work, I have to disable Spam Sieve and delete the folder it was putting spam in. Then reactivate Spam Sieve and create another fold for it to use. It will work for a while. I can quit Mail or restart the Mac and it continues to work, but then for no apparent reason, I have to disable it and redo Move detected spam to Junk folder. To move detected spam to user's Junk folder, you need to enable global sieve script in Dovecot. You can find sample sieve rule file Spam Sieve is a powerhouse spam filter tailored specifically for macOS users. Its seamless integration with popular email clients like Apple Mail and Outlook makes it a go-to choice for Mac enthusiasts. Spam Sieve’s combination of Bayesian filtering and thousands of built-in rules results in exceptionally accurate spam detection. Synthetic material sieve frames, with no detachable pieces. All of this helps prevent food contamination. Efficient cleaning Arenit or Arenit Plus - choose between wooden or synthetic sieve frames The Arenit plansifter is fitted with wooden Nova sieve stacks. These are coated in resin with sturdy metal frame inserts. The sieve covers are glued to the metal frame inserts. The Arenit Plus comes with synthetic NovaTec sieve stacks, which offer a higher level of sanitation. These NovaTec stacks are available in one format of 730 mm x 730 mm. Billions of people come into contact with Bühler technologies to cover their basic needs for food and mobility every day. Our motto is creating “innovations for a better world.” Find out more about our key topics. The Arenit plansifter has a lightweight motor, designed to boost energy efficiency. You can adjust the swing weight to the settings of the sieve hub. The bearing assembly in the swing weight is also very robust and requires little maintenance. Our NovaTens sieve tensioner uses compressed air and rigid clamps to produce an even tension across the whole sieve. Designed for easy use, you need only a brief training course to use it. Key topics Billions of people come into contact with Bühler technologies to cover their basic needs for food and mobility every day. Our motto is creating “innovations for a better world.” Find out more about our key topics. No Results Found Downloads Application possibilities The Bühler process Efficient in every step ofComments
The solution is very similar to Replacing antispam plugin with IMAPSieve,but instead of automatic learning it is supposed to store a copy of the message moved by user for further manual reviewing.In the example below when any user moves a message into or from Junk folder, a copy of the message is placed into report_ham or report_spam folder of spam@example.com mailbox respectively. When a message located in Junk folder replied to or forwarded, a copy of the message is placed into report_spam_reply folder.Requirementspigeonhole v0.4.14 or laterFoldersCreate report_ham, report_spam and report_spam_reply folders in the spam@example.com mailbox.Dovecot configuration20-imap.conf:protocol imap { mail_plugins = $mail_plugins imap_sieve}90-plugin.conf:plugin { sieve_plugins = sieve_imapsieve sieve_extprograms # From elsewhere to Spam folder or flag changed in Spam folder imapsieve_mailbox1_name = Junk imapsieve_mailbox1_causes = COPY FLAG imapsieve_mailbox1_before = file:/usr/local/etc/dovecot/sieve/report-spam.sieve # From Spam folder to elsewhere imapsieve_mailbox2_name = * imapsieve_mailbox2_from = Junk imapsieve_mailbox2_causes = COPY imapsieve_mailbox2_before = file:/usr/local/etc/dovecot/sieve/report-ham.sieve sieve_pipe_bin_dir = /usr/local/libexec/dovecot sieve_global_extensions = +vnd.dovecot.pipe}Sieve scripts/usr/local/etc/dovecot/sieve/report-spam.sieve:require ["vnd.dovecot.pipe", "copy", "imapsieve", "environment", "imap4flags"];if environment :is "imap.cause" "COPY" { pipe :copy "dovecot-lda" [ "-d", "spam@example.com", "-m", "report_spam" ];}# Catch replied or forwarded spamelsif anyof (allof (hasflag "\\Answered", environment :contains "imap.changedflags" "\\Answered"), allof (hasflag "$Forwarded", environment :contains "imap.changedflags" "$Forwarded")) { pipe :copy "dovecot-lda" [ "-d", "spam@example.com", "-m", "report_spam_reply" ];}/usr/local/etc/dovecot/sieve/report-ham.sieve:require ["vnd.dovecot.pipe", "copy", "imapsieve", "environment", "variables"];if environment :matches "imap.mailbox" "*" { set "mailbox" "${1}";}if string "${mailbox}" [ "Trash", "train_ham", "train_prob", "train_spam" ] { stop;}pipe :copy "dovecot-lda" [ "-d", "spam@example.com", "-m", "report_ham" ];Compile Sieve scripts:# sievec /usr/local/etc/dovecot/sieve/report-spam.sieve# sievec /usr/local/etc/dovecot/sieve/report-ham.sieveNow copies of e-mail messages should be placed in the report_ham
2025-03-30Synthetic material sieve frames, with no detachable pieces. All of this helps prevent food contamination. Efficient cleaning Arenit or Arenit Plus - choose between wooden or synthetic sieve frames The Arenit plansifter is fitted with wooden Nova sieve stacks. These are coated in resin with sturdy metal frame inserts. The sieve covers are glued to the metal frame inserts. The Arenit Plus comes with synthetic NovaTec sieve stacks, which offer a higher level of sanitation. These NovaTec stacks are available in one format of 730 mm x 730 mm. Billions of people come into contact with Bühler technologies to cover their basic needs for food and mobility every day. Our motto is creating “innovations for a better world.” Find out more about our key topics. The Arenit plansifter has a lightweight motor, designed to boost energy efficiency. You can adjust the swing weight to the settings of the sieve hub. The bearing assembly in the swing weight is also very robust and requires little maintenance. Our NovaTens sieve tensioner uses compressed air and rigid clamps to produce an even tension across the whole sieve. Designed for easy use, you need only a brief training course to use it. Key topics Billions of people come into contact with Bühler technologies to cover their basic needs for food and mobility every day. Our motto is creating “innovations for a better world.” Find out more about our key topics. No Results Found Downloads Application possibilities The Bühler process Efficient in every step of
2025-04-15This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters Show hidden characters ''' Prime Sieve This module uses the Sieve of Eratosthenes to generate primes in range 1 to N Original algorithm based on definition at: Optimizations included from solution provided at: ''' from math import ceil # Returns list of primes less than upper bound n def getPrimes(n): if n 1: return [] # Determine the number of odd prime candidates sievebound = int(ceil(n-1) / 2) + 1 # We know that for any number n with factors (a,b) # such that n = a * b, MIN(a,b) # With this in mind, we only need to check factors # up to SQRT(n) since any factor greater would have a # corresponding smaller factor pair cross = int(ceil((pow(n, .5)-1) / 2)) # Initialize array of prime candidates # sieve[i] = 2 * i + 1 => 1, 3, 5... sieve = [False] * (sievebound) sieve[0] = True # Test all n from 1...cross => 3..SQRT(n) for i in xrange(1, cross, 1): # By definition, any i with no factors is prime if sieve[i] == False: # We can now set each multiple of i to true # since it can longer be prime # Sieving goes from candidate p^2 to # sievebound with step p # If the nth element has value 2i + 1, # then to get the index of p^2: # p to p^2 = (p^2 - 1)/2 # = (4i^2 + 4i)/2 # = 2i(i + 1) start = 2*i*(i+1) step = 2*i+1 for j in xrange(start, sievebound, step): # Set the index j to true to # mark this number as having # factors and thus not prime sieve[j] = True # Since we ignore all even numbers, add 2 to our list primes = [2] # All candidates with no factors are prime numbers for i in xrange(0, sievebound, 1): if sieve[i] == False: primes.append(2*i + 1) return primes
2025-04-02Key benefits --> Efficient sieve cleaning The partitions in the compartment channels are well sealed. This prevents dust from spreading during sieving and grading and keeps the product pure. CKB0000011005--> --> High sifting throughput in a small space The Arenit has a net sieve surface of up to 84 m², with up to 26 Nova sieve compartments. CKB0000011004--> --> Sturdy and rigid frame A cast metal frame keeps the Arenit stable and robust for 24/7 operation. CKB0000011006--> --> Efficient sieve cleaning The partitions in the compartment channels are well sealed. This prevents dust from spreading during sieving and grading and keeps the product pure. CKB0000011005--> --> High sifting throughput in a small space The Arenit has a net sieve surface of up to 84 m², with up to 26 Nova sieve compartments. CKB0000011004--> --> Sturdy and rigid frame A cast metal frame keeps the Arenit stable and robust for 24/7 operation. CKB0000011006--> Highlight features High throughput Compact design for new plants and retrofits The Arenit plansifter is a key component in the flour production process. It is compact with a small footprint, reducing the amount of space you need for installation. This allows you to easily and quickly integrate the Arenit into new plants. It is also well-suited for retrofitting existing production lines. High sanitation Food safety and preventing food contamination The Arenit’s sifter compartments are insulated to prevent condensed water and damage to the product. The sifter compartments also have a stainless steel lining. The Arenit Plus has high-grade
2025-04-21