Mailing List Archive

Virtual Users
Hi list,

I set up exim a few days ago and in general everything
works fine. But now I have a concern, which a couldn't
solve with the help of the documentation.
I have virtual users with no login on the system, for
which I want to have individual mbox files all in one
directory. So that e.g. mail to john@some.domain and
john@another.domain will be directed to separated files.

This could be handled with files called {$local_part}-{$domain}
but the '.' in the domain annoys me. Is there a way to
extract the '.' from the domain?
Or can exim look for the appropriate mbox file for each
address in a special file like an alias file but only getting the
name of the mbox not for redirecting the mail?

Regards,

Philipp

--
NEU FÜR ALLE - GMX MediaCenter - für Fotos, Musik, Dateien...
Fotoalbum, File Sharing, MMS, Multimedia-Gruß, GMX FotoService

Jetzt kostenlos anmelden unter http://www.gmx.net

+++ GMX - die erste Adresse für Mail, Message, More! +++
Re: Virtual Users [ In reply to ]
> Hi list,
>
> I set up exim a few days ago and in general everything
> works fine. But now I have a concern, which a couldn't
> solve with the help of the documentation.
> I have virtual users with no login on the system, for
> which I want to have individual mbox files all in one
> directory. So that e.g. mail to john@some.domain and
> john@another.domain will be directed to separated files.
>
> This could be handled with files called {$local_part}-{$domain}
> but the '.' in the domain annoys me. Is there a way to
> extract the '.' from the domain?
> Or can exim look for the appropriate mbox file for each
> address in a special file like an alias file but only getting the
> name of the mbox not for redirecting the mail?
>
> Regards,
>
> Philipp

I just found the answer in the FAQ.
I use a transport with the following destination:
"file = /path/to/mboxes/${lookup{$local_part@$domain}lsearch{/etc/vmboxes}}"

Where /etc/vmboxes looks as follows:
<full email address>: <name of mbox file>

And so, every mailbox file can be specified individually
for each email address.

Tanks to the FAQ,

--
NEU FÜR ALLE - GMX MediaCenter - für Fotos, Musik, Dateien...
Fotoalbum, File Sharing, MMS, Multimedia-Gruß, GMX FotoService

Jetzt kostenlos anmelden unter http://www.gmx.net

+++ GMX - die erste Adresse für Mail, Message, More! +++
Re: Virtual Users [ In reply to ]
> This could be handled with files called {$local_part}-{$domain}
> but the '.' in the domain annoys me. Is there a way to
> extract the '.' from the domain?


The following director/transport requires the mailboxdir to exist
to deliver a mail to that maildir.
This way, you don't have to create a separate file. If the mailbox
exist, fine; if not, skip to the next director. If you need an alias
for one of the addresses, you just create a symlink.

cs_pop3_user_transport:
# user@domain.ext --> /var/qmail/popboxes/domain-ext/user/Maildir
driver = appendfile
directory = /var/qmail/popboxes/${lc:${extract{1}{.}{$domain}} \
-${extract{2}{.}{$domain}}}/${lc:$local_part}/Maildir
maildir_format
user = pop
envelope_to_add
create_directory = false
prefix=""
suffix=""

cs_pop3_user_director:
driver = smartuser
transport = cs_pop3_user_transport
require_files = pop : /var/qmail/popboxes/${lc:${extract{1}{.}{$domain}} \
-${extract{2}{.}{$domain}}/$local_part}


(directory= + require_files= was broken to 2 lines [\])

G.
Re: Virtual Users [ In reply to ]
Hi!

> I am hoping I am missing something here, but is there a commonly-used
> database-based exim management system that controls virtual users and their
> domains? I keep finding Postfix solutions, but have no desire to change to
> that MTA system.

http://exim4u.org

--
pi@FreeBSD.org +49 171 3101372 2 years to go !

--
## List details at https://lists.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/
Re: Virtual Users [ In reply to ]
On Fri, 30 Nov 2018 at 12:07, Jay Gairson via Exim-users <
exim-users@exim.org> wrote:

> Greetings:
>
> Hopefully my question isn't too anachronistic.
>
> I am in the process of rebuilding my exim configuration after making minor
> updates over the last decade. While there is a degree of if it's not broke
> don't fix it in my system still, I have decided to start clean.
>
> To manage my virtual users (and the domains they are associated with), I
> have used a variety of solutions over the years -- flat files, SMAD, VEXIM,
> etc. It appears most of these solutions, except flat files, are
> increasingly outdated or nonfunctional.
>
> I am hoping I am missing something here, but is there a commonly-used
> database-based exim management system that controls virtual users and their
> domains? I keep finding Postfix solutions, but have no desire to change to
> that MTA system.
>
> Thank you,
>
> Jay
>

We use exim4u.org system.




--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft."
--
## List details at https://lists.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/
Re: Virtual Users [ In reply to ]
On 2018-11-30 01:00, Jay Gairson wrote:

> To manage my virtual users (and the domains they are associated with),
> I have used a variety of solutions over the years -- flat files, SMAD,
> VEXIM, etc. It appears most of these solutions, except flat files,
> are increasingly outdated or nonfunctional.

This may not be applicable to your situation, but in general, when you
can do something with a flat file you can also do it with cdb.

--
Please don't Cc: me privately on mailing lists and Usenet,
if you also post the followup to the list or newsgroup.
To reply privately _only_ on Usenet and on broken lists
which rewrite From, fetch the TXT record for no-use.mooo.com.

--
## List details at https://lists.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/
Re: Virtual Users [ In reply to ]
Hello,

I missed the initial question, so I don’t know your background. Besides,
I must tell I do not know the solutions you mentioned. So I hope my
answer won’t be beside the point…

Le 30/11/2018 à 17:37, Ian Zimmerman via Exim-users a écrit :
> On 2018-11-30 01:00, Jay Gairson wrote:
>> To manage my virtual users (and the domains they are associated with),
>> I have used a variety of solutions over the years -- flat files, SMAD,
>> VEXIM, etc. It appears most of these solutions, except flat files,
>> are increasingly outdated or nonfunctional.
>
> This may not be applicable to your situation, but in general, when you
> can do something with a flat file you can also do it with cdb.

I wrote an article some time ago, about having virtual users (and real
ones too) using flat files:
http://yalis.fr/cms/index.php/post/2015/06/07/Both-virtual-and-real-users-in-the-same-domain-with-Exim-and-Courier

You might be interested in the newer installment of the same idea, this
time using LDAP (but the principle is still the same):
https://yalis.fr/git/yves/home-server/

Look in particular at Ansible roles:
— slapd
— ldap
— dmz_exim
Also related:
— dovecot (and haproxy for TLS)
— acme_front/back (hence dmz_nginx too, for Let’s Encrypt)
— nftables_front/back

HTH.
Yves.

--
## List details at https://lists.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/
Re: Virtual Users [ In reply to ]
On 2018-11-30, Jay Gairson via Exim-users <exim-users@exim.org> wrote:
> Greetings:
>
> Hopefully my question isn't too anachronistic.
>
> I am in the process of rebuilding my exim configuration after making minor
> updates over the last decade. While there is a degree of if it's not broke
> don't fix it in my system still, I have decided to start clean.
>
> To manage my virtual users (and the domains they are associated with), I
> have used a variety of solutions over the years -- flat files, SMAD, VEXIM,
> etc. It appears most of these solutions, except flat files, are
> increasingly outdated or nonfunctional.
>
> I am hoping I am missing something here, but is there a commonly-used
> database-based exim management system that controls virtual users and their
> domains? I keep finding Postfix solutions, but have no desire to change to
> that MTA system.

Exim speaks database already. no middleware is needed for configuration.

If you need a database message store I've had success with dbmail and
postgresql.

--
When I tried casting out nines I made a hash of it.

--
## List details at https://lists.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/
Re: Virtual Users [ In reply to ]
I've stored my 5000 users - using about 1000 domains in a database for
years - and its worked for years. Exim essentially just reads from the
(I use MySQL) database. Support for MySQL (and others) is there already.
This is extremely scalable.

I then have my custom web pages that allow users to manage their own
entries in the database, buy domains, manage e-mail - etc.
I also have IMAP and POP3 services reading the same data - as well as a
Submission only configured version of Exim.

On 11/30/18 11:00 AM, Jay Gairson via Exim-users wrote:
> Greetings:
>
> Hopefully my question isn't too anachronistic.
>
> I am in the process of rebuilding my exim configuration after making minor
> updates over the last decade. While there is a degree of if it's not broke
> don't fix it in my system still, I have decided to start clean.
>
> To manage my virtual users (and the domains they are associated with), I
> have used a variety of solutions over the years -- flat files, SMAD, VEXIM,
> etc. It appears most of these solutions, except flat files, are
> increasingly outdated or nonfunctional.
>
> I am hoping I am missing something here, but is there a commonly-used
> database-based exim management system that controls virtual users and their
> domains? I keep finding Postfix solutions, but have no desire to change to
> that MTA system.
>
> Thank you,
>
> Jay

--
Mark James ELKINS - Posix Systems - (South) Africa
mje@posix.co.za Tel: +27.128070590 Cell: +27.826010496
For fast, reliable, low cost Internet in ZA: https://ftth.posix.co.za


--
## List details at https://lists.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/