1

I've set up a simple email server with exim that I use for various tasks, such as sending myself reminders. Is there a file that has a similar functionality to /etc/aliases but only for one user instead of system wide (just like a contact list)? I looked at ~/.foreward, but that only seems to work for mail coming in, forewarding it.

2 Answers 2

1

There is not an easy solution such as the aliases file as far as I know. But exim is very flexible. If your users submit email through authentication (port 587 using TLS ought to be the default) you have a way of making sure which user is submitting email. You can then write rules to select the outgoing email address and rewrite it into something else based on which user submits email, you can even compare the outgoing address against a list of addresses in a file, say in the user's $HOME.

How to write these rules I leave as an exercise to the reader (or the next one writing an answer), there are many ways to go about it.

But take a look in /etc/exim4/update-exim4.conf.conf especially the transport and rewrite sections.

0

A few options:

  • Use procmail for delivery. procmail has a lot of power not only to deliver mail based on delivered-to address, but Subject, Sender, content, and pretty well anything in the headers and/or body.
  • Look at the capabilities available with suffixes and/or prefixes. You might need one of the other options if your mail user agent can't sort the mail for you.
  • Look at the current aliases router. You could modify a copy to use an aliases or .aliases file in the home directory. Also look at the settings for virtual servers. (You basically are looking at a personal virtual domain, although the specification might be a little different.
  • Look at what your mail user agent can do for you. Thundebird has some pretty powerful capabilities. (Although these solutions would depend on the MUA running to be effective.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .