Running:
FreeBSD v12.3-RELEASE
Postfix v3.6.3
I recently installed port 'py-spf-engine' (mail/py-spf-engine) to provide SPF for emails via Postfix.
After installation, the package message provides steps for implementing the config changes via 'pkg-message.in.'
After making the necessary changes and reloading Postfix, I'm seeing this error/warning in '/var/log/maillog' pertaining to "No such file or directory" anytime an incoming email is received....
/var/log/maillog
If I go ahead and touch the file in the appropriate directory, then the error changes in /var/log/maillog...
File location....
I also tried changing the group (pyspf-milter) for the file to 'w' writable, but still seeing the warning.
What am I missing here?? Has anyone installed this port and seen this warning? It doesn't seem to affect functionality of the port that I can see. Should I just ignore it as benign?
Thanks to anyone who provides feedback and clues.
Regards,
--Cf
FreeBSD v12.3-RELEASE
Postfix v3.6.3
I recently installed port 'py-spf-engine' (mail/py-spf-engine) to provide SPF for emails via Postfix.
After installation, the package message provides steps for implementing the config changes via 'pkg-message.in.'
Code:
[
{ type: install
message: <<EOM
#
# Using policyd-spf with Postfix
#
Policyd-spf must be integrated with Postfix to be effective:
1. Add to your postfix master.cf:
policyd-spf unix - n n - 0 spawn
user=nobody argv=%%PREFIX%%/bin/policyd-spf
2. Configure the Postfix policy service in your main.cf so that the
"smtpd_recipient_restrictions" includes a call to the policyd-spf policy
filter. If you already have a "smtpd_recipient_restrictions" line, you can
add the "check_policy_service" command anywhere *after* the line which
reads "reject_unauth_destination" (otherwise you're system can become an
open relay).
smtpd_recipient_restrictions =
...
reject_unauth_destination
check_policy_service unix:private/policyd-spf
...
policyd-spf_time_limit = 3600
3. Please consult the postfix documentation for more information on these and
other settings you may wish to have in the "smtpd_recipient_restrictions"
configuration.
4. Reload postfix.
#
# Automatically starting pyspf-milter at boot time.
#
Add 'pyspf_milter_enable="YES"' to /etc/rc.conf.
#
# Using pyspf-milter with Sendmail
#
Following is an example configuration line to include in your sendmail.mc.
INPUT_MAIL_FILTER(`pyspf-milter', `S=local:/var/run/pyspf-milter/pyspf-milter.sock')dnl
#
# Using pyspf-milter with Postfix
#
Integration of pyspf-milter into Postfix is like any milter (See Postfix's
README_FILES/MILTER_README). But care is required to segregate outbound mail
from inbound mail to be checked. Here is example using milter macros to keep
the mail streams segregated.
%%PREFIX%%/etc/postfix/main.cf:
smtpd_milters = unix:/var/run/pyspf-milter/pyspf-milter.sock
%%PREFIX%%/etc/postfix/master.cf:
smtp inet n - - - - smtpd
...
-o milter_macro_daemon_name=VERIFYING
...
%%PREFIX%%/etc/python-policyd-spf/policyd-spf.conf:
MacroList daemon_name|VERIFYING
EOM
}
]
After making the necessary changes and reloading Postfix, I'm seeing this error/warning in '/var/log/maillog' pertaining to "No such file or directory" anytime an incoming email is received....
/var/log/maillog
Code:
Jan 25 05:05:09 ssh1 postfix/smtpd[90462]: connect from mail-1a.dshield.org[66.35.60.131]
Jan 25 05:05:09 ssh1 postfix/smtpd[90462]: warning: connect to Milter service unix:/var/run/pyspf-milter/pyspf-milter.sock: No such file or directory. <<======= !!!!
Jan 25 05:05:10 ssh1 postfix/smtpd[90462]: 28969497DE6: client=mail-1a.dshield.org[66.35.60.131]
Jan 25 05:05:10 ssh1 postfix/cleanup[90465]: 28969497DE6: message-id=<[email]20220125050509.791248303F@dshield.org[/email]>
Jan 25 05:05:10 ssh1 postfix/qmgr[37265]: 28969497DE6: from=<[email]dshield@dshield.org[/email]>, size=2979, nrcpt=1 (queue active)
Jan 25 05:05:10 ssh1 postfix/smtpd[90462]: disconnect from mail-1a.dshield.org[66.35.60.131] ehlo=2 starttls=1 mail=1 rcpt=1 data=1 quit=1 commands=7
Jan 25 05:05:10 ssh1 postfix/local[90466]: 28969497DE6: to=<[email]xxxxxxxxxxx@xxxxxxx.net[/email]>, relay=local, delay=0.25, delays=0.21/0.02/0/0.02, dsn=2.0.0, status=sent (delivered to maildir)
Jan 25 05:05:10 ssh1 postfix/qmgr[37265]: 28969497DE6: removed
If I go ahead and touch the file in the appropriate directory, then the error changes in /var/log/maillog...
Code:
Jan 25 05:17:04 ssh1 postfix/smtpd[90478]: warning: connect to Milter service unix:/var/run/pyspf-milter/pyspf-milter.sock: Socket operation on non-socket.
File location....
Code:
[xxxxxxxx@ssh1:~ ] $ ls -l /var/run/pyspf-milter
total 0K
-rw-r--r-- 1 root pyspf-milter 0 Jan 24 11:14 pyspf-milter.sock
[xxxxxxxx@ssh1:~ ] $
I also tried changing the group (pyspf-milter) for the file to 'w' writable, but still seeing the warning.
What am I missing here?? Has anyone installed this port and seen this warning? It doesn't seem to affect functionality of the port that I can see. Should I just ignore it as benign?
Thanks to anyone who provides feedback and clues.
Regards,
--Cf