Linux sendmail mail server Authentication and SSL configuration examples

Source: Internet
Author: User
Tags md5 linux

1. SMTP AUTHENTICATION/CYRUS-SASL Configuration

1.1 Install CYLUS-SASL

1.2 Configure CYLUS-SASL to support SMTP authentication

1.2.1 CONFIGURE/ETC/MAIL/SENDMAIL.MC to support SMTP authentication:

Uncomment this:

Trust_auth_mech (' digest-md5 cram-md5 LOGIN PLAIN ') dnl

Define (' confauth_mechanisms ', ' GSSAPI digest-md5 cram-md5 LOGIN PLAIN ') dnl

...

Daemon_options (' port=smtp,addr=0.0.0.0, Name=mta,m=ea ') dnl

1.2.2 New/usr/lib/sasl2sendmail.conf:

[Root@host sasl2]# vi/usr/lib/sasl2/sendmail.conf

Pwcheck_method:saslauthd

1.3 Restart SASL and Check installation

Start SASL with Pam:

[Root@host sbin]# service SASLAUTHD stop

stopping SASLAUTHD: [OK]

[Root@host sbin]# saslauthd-a Shadow Pam

Test Installation:

[Root@host sasl2]# cat/usr/lib/sasl2/sendmail.conf

Pwcheck_method:saslauthd

[Root@host sasl2]# Service SASLAUTHD restart

stopping SASLAUTHD: [OK]

Starting SASLAUTHD: [OK]

[Root@host sasl2]# telnet mail.host.com 25

Trying 10.56.233.59 ...

Connected to Mail.host.com (192.168.1.5).

Escape character is ' ^] '.

host.com ESMTP Sendmail 8.13.8/8.13.8; Wed, Mar 2010 23:12:20 +0800

EHLO localhost

250-host.com Hello host [192.168.1.5], pleased to meet you

250-enhancedstatuscodes

250-pipelining

250-8bitmime

250-size

250-dsn

250-etrn

250-auth LOGIN PLAIN

250-deliverby

Help

Quit

221 2.0.0 host.com Closing connection

Connection closed by foreign host.

[root@host sasl2]# SENDMAIL-D0.1-BV Root | grep SASL

Netunix newdb NIS pipelining SASLv2 SCANF socketmap

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.