Fast forwarding Milters Re: Calling a SMTP Milter before local_recipient_maps

2020-01-28 Thread Fred Morris
I apologize for my boundless optimism. I think the "it can't be done" mantra is really "it's always been this way". I understand that there is an impedance mismatch between the SMTP and milter protocols in that a milter is allowed to inspect and even reject an address supplied via SMTP RECV, but i

Re: Fast forwarding Milters Re: Calling a SMTP Milter before local_recipient_maps

2020-01-28 Thread Wietse Venema
Fred Morris: > I apologize for my boundless optimism. I think the "it can't be done" > mantra is really "it's always been this way". > > I understand that there is an impedance mismatch between the SMTP and > milter protocols in that a milter is allowed to inspect and even reject > an address supp

Postfix can't find Postgserql's unix socket using "peer" method

2020-01-28 Thread Hamid M.
Hello Using psql I can connect to postgresql's socket with a database user/role that does not have a password set. This is achieved by using "peer" authentication method and maps set in "pg_ident.conf" file: mailserver_map postfix mailserver "pg_hba.conf" file: localmailserverallpee

Re: Postfix can't find Postgserql's unix socket using "peer" method

2020-01-28 Thread Jaroslaw Rafa
Dnia 28.01.2020 o godz. 18:43:48 Hamid M. pisze: > > Issuing following command works and doesn't require password: > sudo -u postfix psql -U mailserver -d mailserver -h /var/run/postgresql > > Additionally, all queries using "postmap -q" succeed with correct results. > > But none of the look ups

Re: Postfix can't find Postgserql's unix socket using "peer" method

2020-01-28 Thread Hamid M.
On Tue, Jan 28, 2020 at 6:52 PM Jaroslaw Rafa wrote: > > > postfix/trivial-rewrite[8119]: warning: connect to pgsql server > > /var/run/postgresql: could not connect to server: No such file or > > directory??Is the server running locally and accepting??connections on > Unix > > domain socket "/va

Re: Postfix can't find Postgserql's unix socket using "peer" method

2020-01-28 Thread Viktor Dukhovni
On Tue, Jan 28, 2020 at 07:53:42PM -0500, Hamid M. wrote: > Thanks for your reply. I moved the socket folder into Postfix's jail > "/var/spool/postfix/postgresql": It would be easier to just turn off chroot in master.cf, but: > ls -ld /var/spool/postfix/postgresql > drwxrwsr-x 2 postgres postgre

Re: Postfix can't find Postgserql's unix socket using "peer" method

2020-01-28 Thread Hamid M.
On Tue, Jan 28, 2020 at 8:11 PM Viktor Dukhovni wrote: > > You also need symbolic link > > /var/spool/postfix/var/spool/postfix -> ../.. > > So that paths under /var/spool/postfix work the same way for > both chrooted and not chrooted processes. > > Nos sure how to go about doing this linking

Re: Postfix can't find Postgserql's unix socket using "peer" method

2020-01-28 Thread Viktor Dukhovni
On Tue, Jan 28, 2020 at 08:27:53PM -0500, Hamid M. wrote: > > You also need symbolic link > > > > /var/spool/postfix/var/spool/postfix -> ../.. > > > > So that paths under /var/spool/postfix work the same way for > > both chrooted and not chrooted processes. > > Not sure how to go about doing

Re: Postfix can't find Postgserql's unix socket using "peer" method

2020-01-28 Thread Hamid M.
On Tue, Jan 28, 2020 at 8:36 PM Viktor Dukhovni wrote: > > Naturally, you'd have to create the intermediate directories: > > # (umask 022; mkdir -p /var/spool/postfix/var/spool) > # ln -s ../.. /var/spool/postfix/var/spool/postfix > Thanks Victor, this helped solve the issue. Just curiou

Fond memories of 1988: OpenSMTPD remote code execution

2020-01-28 Thread Viktor Dukhovni
If some of you have servers running OpenSMTPD, an update is in order: https://www.openwall.com/lists/oss-security/2020/01/28/3 Dare I suggest Postfix, which has multiple layers of defense against bugs of this sort. The fact that recently developed software, reportedly designed with securit