1

Topic: Linux users receive emails (but should not)

Hallo

I have re-configured the setup to use fcgi for php. So far no issues with iredmail, only roundcube required some special settings.

I created several users on the server to run the different websites with different users.
I've noticed some of them contain a Maildir folder in /home/username/ but in my opinion there should be no such folder. Mail that bounces back should end up in the postmaster account (which according to aliases db receveices all emails)

is there a setting that does not create maildir folders for users on the system?
or do i need to add every system user into the aliases file too?

thanks a lot

----

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

2

Re: Linux users receive emails (but should not)

What kind of email did they get? I don't think they're bounces.

Some cron jobs will generate output message, and system will send them to owner, that's reasonable.

3

Re: Linux users receive emails (but should not)

Hallo

mainly delivery notices. For ex.:

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

                   The mail system

<veryprivateemail@live.de>: host mx4.hotmail.com[65.55.92.168] said: 550 Requested
    action not taken: mailbox unavailable (in reply to RCPT TO command)

There are also 'user unknown' replies.


I notived the application sends emails with interesting email headers (below an 'abstraction'):

Return-Path: <linuxuser@FQDN>
Delivered-To: me@mydomain.ch
To: me@redirectdomain.ch
Subject: ...
X-PHP-Originating-Script: 1004:classEmail.php
MIME-Version: 1.0
Date: Sat, 11 Jun 2011 14:33:00 +0000
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: IPS PHP Mailer
From: "TFadmin" <admin@myapp.ch>
Content-type: text/plain; charset="UTF-8"

The "From:" is the sender email address configured in the forum application.
The "Return-Path:" is the linux user @ FQDN

My expectation was that email should be returned to the "From:" address if it cannot be delivered.
Is there a setting to achieve this or is the aliases file the best solution for this?


thanks!

4

Re: Linux users receive emails (but should not)

wm wrote:

My expectation was that email should be returned to the "From:" address if it cannot be delivered.
Is there a setting to achieve this or is the aliases file the best solution for this?

MTA (Postfix) picks up address in "Return-Path" for returned mails, not "From".

Seems you sent mails with PHP script, then you should let it write "Return-Path" in email, instead of generated by Postfix.

5

Re: Linux users receive emails (but should not)

Hallo

thanks a lot for the reply.
I've read some postfix for dummies pages on the web. The return path has to be set by the client. In my case the php script you mentioned (by adding additional headers, mainly "-f myemai@dot.com", there is also a -r: "-f myemail@dot.com -r mybouncemail@dot.com" if one is going for sophisticated setups). man sendmail lists it all.

There is also the possibility to set this in php.ini for every script:
sendmail_path

Since I'm the lucky fcgi user I can also put this into the warpper script with the -D option
(see http://www.howtoforge.com/how-to-set-up … u-10.04-p2 for details)

Just if anyone would be interested :-)

The -f option was enough already to fix the return path.


Thanks for the hint!
best regards