Help configuring sendmail to send only using authorization to smart host

Giorgos Keramidas keramida at ceid.upatras.gr
Tue Sep 22 23:27:08 UTC 2009


On Tue, 22 Sep 2009 12:37:27 -0500, Phusion <phusion2k at gmail.com> wrote:
> I recompiled sendmail and now get the following when running sendmail -d0.1 -bv.
> I now have added the following to sendmail.mc.
>
> FEATURE(masquerade_envelope)
> FEATURE(genericstable, `hash -o /etc/mail/genericstable')
> GENERICS_DOMAIN_FILE(`/etc/mail/generics-domains')
> TRUST_AUTH_MECH(`LOGIN PLAIN')dnl
> define(`confAUTH_MECHANISMS',`LOGIN PLAIN')dnl
> FEATURE(authinfo, `hash -o /etc/mail/auth/authinfo')
> define(`SMART_HOST', `mail.test.com')
> define(`confCW_FILE', `-o /etc/mail/local-host-names')
> dnl DAEMON_OPTIONS(`Name=IPv6, Family=inet6, Modifiers=O')
>
> I created /etc/mail/auth/authinfo and then did the makemaps to create
> the hashd .db file. When trying to email outbound, I still get the
> same error in the logs.
>
> ...relay=mail.test.com. [public_IP_address], dsn=5.6.0, stat=Data format error

More about this later.

> The /etc/mail/auth/authinfo file looks like the following.
>
> ----------------------------------------------------------------------------------------------------
> AuthInfo:mail.test.com "U:username at isp.com" "P:password"
> ----------------------------------------------------------------------------------------------------

This looks ok.

The ``dsn=5.6.0, stat=Data format error'' error code is described (along
with other SMTP error codes) in RFC 1893 as:

       5.X.X   Permanent Failure

       A permanent failure is one which is not likely to be resolved by
       resending the message in the current form.  Some change to the
       message or the destination must be made for successful delivery.

       X.6.X   Message Content or Media Status

       The message content or media status codes report failures
       involving the content of the message.  These codes report
       failures due to translation, transcoding, or otherwise
       unsupported message media.  Message content or media issues are
       under the control of both the sender and the receiver, both of
       whom must support a common set of supported content-types.

       X.6.0   Other or undefined media error

       Something about the content of a message caused it to be
       considered undeliverable and the problem cannot be well expressed
       with any of the other provided detail codes.

A few things to check are:

  * Can you resolve your own IP address correctly?

  * Can you resolve 'mail.test.com' correctly?

  * Can you connect to `mail.test.com' at port 25?

  * Can you connect to port 587 of `mail.test.com'?

  * Is `mail.test.com' the actual ISP mail server name?  If not, please
    tell us its _real_ name, so we can also check if there are DNS or
    other problems.

It may even be useful to show us tcpdump output obtained with:

    tcpdump -n -v -l -X -i em0 'host a.b.c.d && port 25'

Where 'em0' is replaced by your outgoing interface, 'a.b.c.d' is
replaced by the IP address of 'mail.test.com' and you have carefully
edited the log file to _hide_ any occurrence of your password *only*.



More information about the freebsd-questions mailing list