1

Topic: special monitoring of incoming emails with pre specified response

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.7.1 MARIADB edition
- Deployed with iRedMail Easy or the downloadable installer? Downloadable installer
- Linux/BSD distribution name and version: Ubuntu Server 20.04.6
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL ( MariaDB 10.3.39 )
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? No
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====
Dear Sirs,
first of all this is not an issue but something that I want to implement and seeking for your help.
In my server with the following installed:
Ubuntu Server 20.04.6 with iRedMail 1.7.1
dovecot 2.3.7.2  ,  postfix 3.4.13  ,  MariaDB 10.3.39  ,  roundcube 1.6.8
I want to implement a monitoring of all incoming emails in one of my email account (mailbox), not globally e.g. for account: trade@trade.gr and to check for each new incoming email if the fields: To or Cc or Bcc not contains (not exclusively, I mean it can contains other addresses as well) a particular email e.g. tradegr@gmail.com . In this case, I want to inform the sender of this email, with a predefined text/email, something like: "You forgot to put in the to: or cc: fields our backup address: tradegr@gmail.com please don't forget it next time. Thanks".
What do you think I can do it ?
Maybe to create a iRedAPD script on the plugins directory or to modify an exiting?

Please the iRedMail masters help me !

Thanks.

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: special monitoring of incoming emails with pre specified response

No one can suggest something to help me?

mikekgr wrote:

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.7.1 MARIADB edition
- Deployed with iRedMail Easy or the downloadable installer? Downloadable installer
- Linux/BSD distribution name and version: Ubuntu Server 20.04.6
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL ( MariaDB 10.3.39 )
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? No
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====
Dear Sirs,
first of all this is not an issue but something that I want to implement and seeking for your help.
In my server with the following installed:
Ubuntu Server 20.04.6 with iRedMail 1.7.1
dovecot 2.3.7.2  ,  postfix 3.4.13  ,  MariaDB 10.3.39  ,  roundcube 1.6.8
I want to implement a monitoring of all incoming emails in one of my email account (mailbox), not globally e.g. for account: trade@trade.gr and to check for each new incoming email if the fields: To or Cc or Bcc not contains (not exclusively, I mean it can contains other addresses as well) a particular email e.g. tradegr@gmail.com . In this case, I want to inform the sender of this email, with a predefined text/email, something like: "You forgot to put in the to: or cc: fields our backup address: tradegr@gmail.com please don't forget it next time. Thanks".
What do you think I can do it ?
Maybe to create a iRedAPD script on the plugins directory or to modify an exiting?

Please the iRedMail masters help me !

Thanks.

3 (edited by Cthulhu 2024-09-30 03:29:25)

Re: special monitoring of incoming emails with pre specified response

create a sieve script for that

not testet, could work:

require ["fileinto", "imap4flags", "vacation", "copy"];

if not address :contains "cc" "tradegr@gmail.com" {
    # Autoreply
    vacation :days 1 :subject "Subject" 
        "Hello,\n\nIt seems you forget to add the CC.\n\nWahtever you want to add.\nLast Line";
}

4

Re: special monitoring of incoming emails with pre specified response

Thanks for your reply, great idea ! I will test it and report back here

Cthulhu wrote:

create a sieve script for that

not testet, could work:

require ["fileinto", "imap4flags", "vacation", "copy"];

if not address :contains "cc" "tradegr@gmail.com" {
    # Autoreply
    vacation :days 1 :subject "Subject" 
        "Hello,\n\nIt seems you forget to add the CC.\n\nWahtever you want to add.\nLast Line";
}