Skip to content
/ roundup Public

IMAP background filter, washer and reorganizer (based on regular and and logical expressions)

License

Notifications You must be signed in to change notification settings

seanox/roundup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Description

Roundup (in allusion to a broadband herbicide) is an IMAP-based mail filter, washer and (re)organizer that works in the background, e.g. as a cron job. This tool uses IMAP to move rule based mails in a mailbox. The rules for this are a combination of regular and logical expressions.

Why PHP?

For those who use a homepage, server-side PHP is often available for crone job and so the solution can be used remotely instead of locally -- and the IMAP implementation for PHP is good :-)

Features

  • Multiple account support
  • IMAP support (incl. SSL)
  • simple URL based IMAP and mailbox definition
  • Internal dynamic whitelist
    Exclusion of mails from subsequent filters and rules.
  • Filter based on patterns with regular expression
    The patterns can then be combined in logical expressions.
    Supported: AND, OR, NOT, round brackets
  • Processes the header and body of the messages
    Message content, including multi-part, is decoded and simplified for the filters. The decoding only happens in memory.
  • Message attributes such as 'seen / unseen' are retained
  • Continuation of filtering from the last analyzed mail (for each mailbox separately); complete reanalysis when changing application, configuration or filter
  • Logging with detailed error messages
  • Physical separation of application, configuration (with accounts) and filter

Licence Agreement

LIZENZBEDINGUNGEN - Seanox Software Solutions ist ein Open-Source-Projekt, im Folgenden Seanox Software Solutions oder kurz Seanox genannt.

Diese Software unterliegt der Version 2 der Apache License.

Copyright (C) 2024 Seanox Software Solutions

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

System Requirement

  • PHP 7.x or higher + imap extension

Downloads

Seanox Roundup 2.0.1

Installation

The script must be stored on a server and is called by a cron job.

/bin/php -f roundup.php

Alternatively, the script can also be used via CGI.
In this case, please prohibit access to the configuration (ini) and filter file.

Configuration

The application consists of three files (roundup.php, roundup.ini, roundup.filter). At runtime, the session file roundup.data is created later. The files can be renamed. Basis is the file name of the application (roundup.php). All other file names must be based on it.
The program fileroundup.php itself does not need to be configured.

Configuration (roundup.ini)

There are two sections: COMMON and ACCOUNT.
Please open roundup.ini and read the notices and see the examples.

Filter (roundup.filter)

The filters are defined here.
Please open roundup.filter and read the instructions and see the examples.

Filter collection against spam

Collected selection with general rules.

  • A + B: Pupular sender that does not match sender address
  • C: Empty tags in header X-Envelope-From
  • D: Empty tags in the Reply-to () header
  • E: Images with request parameter
A: /^From:.*(google|facebook|ebay|amazon)/im
B: /^From:.*?(google|facebook|ebay|amazon).*<.*@[^>]*\1\.(\w+)>/im
C: /X-Envelope-From:\s*<\s*>/i
D: /Reply-to:\s*<\s*>/i
E: /<img[^>]+\ssrc=[^>]+\?/i
(A && !B) || C || D || E

Changes

2.0.1 20240401

BF: Review: Optimizations and corrections
BF: Build: Optimization of the release info process
BF: Filter: Update of example patterns

Read more

Contact

Issues
Requests
Mail

About

IMAP background filter, washer and reorganizer (based on regular and and logical expressions)

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages