1 (edited by Karlin 2023-01-03 06:02:20)

Topic: Spider Email Archiver: Ignore email adresses when creating mailboxes

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): Spider v1.1.0
- Deployed with iRedMail Easy or the downloadable installer? Downloadable.
- Linux/BSD distribution name and version: Debian 11
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): Spider
- Web server (Apache or Nginx): Spider
- Manage mail accounts with iRedAdmin-Pro? No
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

Spider Email Archiver is marketed as free for up to 10 mailboxes. We have less than 10, so I am trying it out and liking what I see.

I also have used over 40 different aliases, though. One of the biggest benefits I find for running my own email server (Now Zimbra, soon iRedMail) is being able to create aliases with little hesitation as needs arise.

However, it looks like Spider is counting each alias as a Mailbox, quickly finding over 10 and now saying "Exceeded Max Mailboxes" in its Admin interface.

I found the user interface to stop archiving, Dashboard -> Email Domains -> (link under mailboxes) and stopped the ones I don't want. (Devoted to marketing email and log messages.) But it still says "Exceeded Max Mailboxes."

Is there a way to have Spider ignore certain email addresses, and not create mailboxes for them? I found nothing in the documentation about that so far.

----

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

2

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

Also, I now have unwanted Spider archive mailboxes created for aliases -- one which was only used for 3 emails ever, and since deleted.

Is there a way to delete mailboxes like that?

3

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

To resolve this unwanted-mailboxes issue, I am am looking at Spider's config files, storage directory structure, and SQLite files. I am trying to find ways to:

* Delete unwanted mailboxes that have already been created.
* Prevent unwanted mailboxes from being created in the future.

Where would I find what is needed to get that result?

4

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

I found my answer: the SQLite file /opt/spider/db/settings.db has the mailboxes. I got a SQLite version compatible with what Spider uses, and can delete the unwanted mailboxes in that database.

During that research, I have come to really appreciate how this product was designed. I plan to buy mailbox licenses even if I don't need them.

Now, the unwanted-mailboxes problem is worse than I thought at first.

Because, it is not just my aliases that count as mailboxes. Spammers can send email to username@mydomain.com with the From header spoofed to say spammername@mydomain.com and Spider will pick that up as another mailbox.

Unless this is in any way related to the Postfix setup step I skipped?

spiderd(dot)io/docs/mta-setup-postfix.html

OPTIONAL BUT HIGHLY RECOMMENDED: Update smtpd_recipient_restrictions to add a check_recipient_access rule to always prepend X-Envelope-To: header with the final delivery address...

5

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

Hi Karlin,

You must add the "X-Envelope-To" header to solve your issue.

Spider collects recipient addresses from X-Envelope-To:, if no such header, it collects recipients in To/Cc/Bcc which obviously may contains original alias / forwarding addresses.

6

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

By the way, we don't recommend to modify data in SQLite databases directly, it may cause data integrity issue and hard to troubleshoot.

7

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

Thank you for the advice. I have configured my current email server to add the "X-Envelope-To" header. I can see messages now include it. However, messages received for aliases are using the alias address for the "X-Envelope-To" field. Apparently I would need some way to look up that address and have the add-x-envelope-to.pcre use the delivery mailbox address instead.

Also, when using "spider-import imap", what options are there for either setting "X-Envelope-To" or ignoring certain addresses?

8

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

Karlin wrote:

Apparently I would need some way to look up that address and have the add-x-envelope-to.pcre use the delivery mailbox address instead.

So close! I found the lookup command, but so far not the way to have its result included in the PCRE rule. If there was some way to do a thing like this:

/(.*)/ prepend X-Envelope-To: (?{ `/opt/zimbra/postfix/sbin/postalias -q $1 proxy:ldap:/opt/zimbra/conf/ldap-vam.cf` })

But the result just includes the the text of the command into the X-Envelope-To header.

9

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

Are you running Zimbra or iRedMail?
Zimbra runs Postfix as MTA too, so the document for Postfix works for Zimbra too.

10

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

Karlin wrote:

Also, when using "spider-import imap", what options are there for either setting "X-Envelope-To" or ignoring certain addresses?

There's no such option yet.

11

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

I am now at this stage as well where I have 12 mailboxes, 6 of them are actual aliases of mailboxes.

Have also stopped archiving on the 6 alias mailboxes in Spider however the 'Exceed Max Mailbox' error still persists.

My queue is also stuck at 8012 which I assume will not continue to process until the mailbox restriction is rectified.

I'm hopeful there is a safe workaround to this (without having to delete entries in SQL databases). Also hopeful that this great product will be enhanced to include all alias from a mailbox as one license as well as having the GUI option (or scripted option) to delete archived mailboxes altogether.

12

Re: Spider Email Archiver: Ignore email adresses when creating mailboxes

Hi @plantagenet82,

Please contact us to work out a solution: https://www.iredmail.org/contact.html