Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Craig R. Skinner
On 2013-06-25 Tue 14:38 PM |, Viktor Dukhovni wrote: > > > Jun 25 14:04:08 server1 postfix/pickup[29023]: 51B8367E0: uid=7432 > > from= > > Jun 25 14:04:08 server1 postfix/cleanup[154]: 51B8367E0: > > message-id=<20130625130408.51b836...@server1.example.com> > > Jun 25 14:04:08 server1 postfix/q

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Wietse Venema
Craig R. Skinner: > On 2013-06-25 Tue 13:45 PM |, Wietse Venema wrote: > > > aliases: > > > root: admin-acct > > > deamon: root > > > > That's deamon. > > > > Second, you need admin-acct@localhost, root@localhost here. > > > > So the aliases file needs to have the RHS qual

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Craig R. Skinner
On 2013-06-25 Tue 13:45 PM |, Wietse Venema wrote: > > aliases: > > root: admin-acct > > deamon: root > > That's deamon. > > Second, you need admin-acct@localhost, root@localhost here. > So the aliases file needs to have the RHS qualified with @localhost when the machi

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Craig R. Skinner
On 2013-06-25 Tue 18:27 PM |, Wolfgang Zeikat wrote: > As you may not have noticed, > the alias > deamon is _not_ the same word as > daemon No Wolfgang, I hadn't noticed the minor typo in my email. Thanks, -- Craig Skinner | http://twitter.com/Craig_Skinner | http://linkd.in/yGqkv7

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Craig R. Skinner
On 2013-06-25 Tue 16:16 PM |, Viktor Dukhovni wrote: > > > > aliases: > > root: admin-acct > > deamon: root > > Is this the right aliases(5) file? Yes. > Some systems use /etc/aliases, > others /etc/mail/aliases, ... What does "postconf alias_database" > output? What

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread /dev/rob0
On Mon, Jun 24, 2013 at 10:49:49PM +0100, Craig R. Skinner wrote: > On 2013-06-24 Mon 12:34 PM |, /dev/rob0 wrote: > > On Mon, Jun 24, 2013 at 03:12:24PM +0100, Craig R. Skinner wrote: > > > main.cf: > > > myorigin = $mydomain # example.com > > > mydestination = localhost, localhost.$mydomain > >

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Wietse Venema
Craig R. Skinner: > On 2013-06-25 Tue 10:14 AM |, Wietse Venema wrote: > > > > You need to show: > > > > 1 - One email address ending in localhost or localhost.$mydomain, > > > > aliases: > root: admin-acct > deamon: root That's deamon. Second, you need admin-acct@local

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Wolfgang Zeikat
In an older episode, on 2013-06-25 18:16, Viktor Dukhovni wrote: deamon: root $ uptime | mail -s uptime daemon@localhost As you may not have noticed, the alias deamon is _not_ the same word as daemon

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Viktor Dukhovni
On Tue, Jun 25, 2013 at 03:53:53PM +0100, Craig R. Skinner wrote: > On 2013-06-25 Tue 10:14 AM |, Wietse Venema wrote: > > > > You need to show: > > > > 1 - One email address ending in localhost or localhost.$mydomain, > > > > aliases: > root: admin-acct > deamon: root

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Craig R. Skinner
On 2013-06-25 Tue 10:14 AM |, Wietse Venema wrote: > > You need to show: > > 1 - One email address ending in localhost or localhost.$mydomain, > aliases: root: admin-acct deamon: root ... ... $ uptime | mail -s uptime daemon@localhost > 2 - Logfile evidence that this email

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Viktor Dukhovni
On Tue, Jun 25, 2013 at 02:53:47PM +0100, Craig R. Skinner wrote: > > And hence, it is processed by the local(8) delivery agent, which > > normally handles domains listed in mydestination. > > > > Well, that's the theory - but I don't see that happening when adhering > to the suggestions provide

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Wietse Venema
Craig R. Skinner: > On 2013-06-24 Mon 20:24 PM |, Wietse Venema wrote: > > Craig R. Skinner: > > > The default aliases file does not indicate that;- > > > > > > "The aliases(5) table provides a system-wide mechanism to redirect mail > > > for LOCAL recipients." > > > > > > "Users can control del

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-25 Thread Craig R. Skinner
On 2013-06-24 Mon 20:24 PM |, Wietse Venema wrote: > Craig R. Skinner: > > The default aliases file does not indicate that;- > > > > "The aliases(5) table provides a system-wide mechanism to redirect mail for > > LOCAL recipients." > > > > "Users can control delivery of their own mail by setting

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-24 Thread Wietse Venema
Craig R. Skinner: > The default aliases file does not indicate that;- > > "The aliases(5) table provides a system-wide mechanism to redirect mail for > LOCAL recipients." > > "Users can control delivery of their own mail by setting up .forward files in > their home directory." Actually, it say

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-24 Thread Craig R. Skinner
On 2013-06-24 Mon 12:34 PM |, /dev/rob0 wrote: > On Mon, Jun 24, 2013 at 03:12:24PM +0100, Craig R. Skinner wrote: > > main.cf: > > myorigin = $mydomain # example.com > > mydestination = localhost, localhost.$mydomain > > Here we see that $myorigin (nor $mydomain) is listed in > $mydestination. >

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-24 Thread /dev/rob0
On Mon, Jun 24, 2013 at 12:34:00PM -0500, /dev/rob0 wrote: > On Mon, Jun 24, 2013 at 03:12:24PM +0100, Craig R. Skinner wrote: > > main.cf: > > myorigin = $mydomain # example.com > > mydestination = localhost, localhost.$mydomain > > Here we see that $myorigin (nor $mydomain) is listed in Sorry,

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-24 Thread /dev/rob0
On Mon, Jun 24, 2013 at 03:12:24PM +0100, Craig R. Skinner wrote: > main.cf: > myorigin = $mydomain # example.com > mydestination = localhost, localhost.$mydomain Here we see that $myorigin (nor $mydomain) is listed in $mydestination. > However, aliases seems to be totally ignored. > > When I m

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-24 Thread Craig R. Skinner
On 2013-06-22 Sat 16:26 PM |, Viktor Dukhovni wrote: > > Use virtual(5) for ALL address -> address mappings, with only > addresses that represent final mailboxes listed as account@localhost. > > The aliases(5) file is a Sendmail compatibility feature, whose > features are best remapped onto virtu

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-23 Thread Wietse Venema
Stan Hoeppner: > On 6/22/2013 4:10 PM, Wietse Venema wrote: > > I agree with Viktor's description: > > > > /etc/postfix/main.cf: > > # The domain that users are aliased to: > > mydestination = localhost localhost.$mydomain > > > > # The domain in DNS that you receive mail for: > >

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-23 Thread Stan Hoeppner
On 6/22/2013 4:10 PM, Wietse Venema wrote: > I agree with Viktor's description: > > /etc/postfix/main.cf: > # The domain that users are aliased to: > mydestination = localhost localhost.$mydomain > > # The domain in DNS that you receive mail for: > vitual_alias_maps = example.com

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-22 Thread Wietse Venema
I agree with Viktor's description: /etc/postfix/main.cf: # The domain that users are aliased to: mydestination = localhost localhost.$mydomain # The domain in DNS that you receive mail for: vitual_alias_maps = example.com # The alias mapping from "DNS" domain name to UNIX sys

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-22 Thread Viktor Dukhovni
On Sat, Jun 22, 2013 at 12:13:16PM +0100, Craig R. Skinner wrote: > > >main.cf: > > >myorigin = $mydomain > > >mydestination = localhost.$mydomain Notice the exact form of the above (IIRC that was my suggestion). > > No. If the destination you use in virtual_alias_maps is @localhost, > > then TH

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-22 Thread Stan Hoeppner
On 6/22/2013 6:13 AM, Craig R. Skinner wrote: ... > Stan's idea of a plain canonical domain & rejecting specific Unix > accounts via smtpd_recipient_restrictions check_recipient_access > reject_system_accounts.map works. Everyone whose replied in this thread knows and understands aliasing much bet

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-22 Thread Craig R. Skinner
On 2013-06-21 Fri 22:08 PM |, Jeroen Geilman wrote: > > > >main.cf: > >myorigin = $mydomain > >mydestination = localhost.$mydomain > > No. If the destination you use in virtual_alias_maps is @localhost, > then THAT must be in mydestination. > Postfix is quite literal. > > mydestination = loca

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-21 Thread Jeroen Geilman
On 06/21/2013 09:57 PM, Craig R. Skinner wrote: On 2013-06-19 Wed 21:09 PM |, Viktor Dukhovni wrote: virtual_alias_maps.map: user.n...@example.com user1@localhost status=bounced (mail for localhost.example.com loops back to myself) You MUST include localhost.$mydomain in mydestination:

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-21 Thread Craig R. Skinner
On 2013-06-19 Wed 21:09 PM |, Viktor Dukhovni wrote: > > > > virtual_alias_maps.map: > > user.n...@example.com user1@localhost > > > > status=bounced (mail for localhost.example.com loops back to myself) > > You MUST include localhost.$mydomain in mydestination: > > mydestination = localh

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-21 Thread Craig R. Skinner
On 2013-06-20 Thu 04:52 AM |, Stan Hoeppner wrote: > > >> smtpd_recipient_restrictions > > Note this is an smptd restriction. > >> ... > >> check_recipient_access hash:/etc/postfix/reject-local-system > >> ... > Thus this only applies to mail arriving via smtpd, not pickup, not pipe,

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-20 Thread Stan Hoeppner
On 6/19/2013 1:37 PM, Craig R. Skinner wrote: > On 2013-06-19 Wed 10:55 AM |, Stan Hoeppner wrote: >> >> I'm anything but an expert in this particular area of Postfix, but I >> think the problem is that Craig is trying to use virtual_alias_maps when >> he should probably just be using the local ali

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Viktor Dukhovni
On Wed, Jun 19, 2013 at 07:43:16PM +0100, Craig R. Skinner wrote: > Looks simple enough, but no joy with: > > virtual_alias_maps.map: > user.n...@example.com user1@localhost > > status=bounced (mail for localhost.example.com loops back to myself) You MUST include localhost.$mydomain in mydestin

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Craig R. Skinner
On 2013-06-19 Wed 18:12 PM |, Jeroen Geilman wrote: > >hosts a single mail domain IIUC. He's simply wanting to create alias > >addresses presented to the public for each local UNIX mailbox address. > >Additionally he wants to reject any inbound mail destined for the actual > >local UNIX addresses,

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Craig R. Skinner
On 2013-06-19 Wed 10:55 AM |, Stan Hoeppner wrote: > > I'm anything but an expert in this particular area of Postfix, but I > think the problem is that Craig is trying to use virtual_alias_maps when > he should probably just be using the local aliases file. His Postfix > hosts a single mail domai

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Jeroen Geilman
On 06/19/2013 05:55 PM, Stan Hoeppner wrote: On 6/19/2013 10:16 AM, Wietse Venema wrote: Craig R. Skinner: On 2013-06-19 Wed 06:51 AM |, Stan Hoeppner wrote: On 6/19/2013 6:11 AM, Craig R. Skinner wrote: What happens when you try mydestination = That's something I didn't think of trying.

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Stan Hoeppner
On 6/19/2013 10:16 AM, Wietse Venema wrote: > Craig R. Skinner: >> On 2013-06-19 Wed 06:51 AM |, Stan Hoeppner wrote: >>> On 6/19/2013 6:11 AM, Craig R. Skinner wrote: >>> >>> What happens when you try >>> >>> mydestination = >>> >> >> That's something I didn't think of trying. >> >> Either blank,

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Wietse Venema
Craig R. Skinner: > On 2013-06-19 Wed 06:51 AM |, Stan Hoeppner wrote: > > On 6/19/2013 6:11 AM, Craig R. Skinner wrote: > > > > What happens when you try > > > > mydestination = > > > > That's something I didn't think of trying. > > Either blank, or with localhost: > > status=bounced (User

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Craig R. Skinner
On 2013-06-19 Wed 06:51 AM |, Stan Hoeppner wrote: > On 6/19/2013 6:11 AM, Craig R. Skinner wrote: > > What happens when you try > > mydestination = > That's something I didn't think of trying. Either blank, or with localhost: status=bounced (User unknown in virtual alias table) Which is wi

Re: Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Stan Hoeppner
On 6/19/2013 6:11 AM, Craig R. Skinner wrote: > > I'm setting up Postfix for a domain that hosts Dovecot IMAP mail dirs > for real Unix accounts. Postfix needs to accept mail for users' public > aliases, but not their Unix login, and reject mail for daemon accounts. > e.g: > > > joe.blo...@examp

Local UNIX accounts, aliasing & rejecting mail to non-public UNIX accounts

2013-06-19 Thread Craig R. Skinner
I'm setting up Postfix for a domain that hosts Dovecot IMAP mail dirs for real Unix accounts. Postfix needs to accept mail for users' public aliases, but not their Unix login, and reject mail for daemon accounts. e.g: joe.blo...@example.com --> jb4356 jane.blos...@example.com-->