LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices



Reply
 
Search this Thread
Old 01-23-2004, 08:28 PM   #1
ckmehta
LQ Newbie
 
Registered: Aug 2003
Location: Near Phila, PA
Distribution: RedHat 9
Posts: 8

Rep: Reputation: 0
Postfix 2.X SMTP AUTH Success Story


Hi All...given all the help I have found here in general, just wanted to pass this along cuz the documentation was scattered all around.

On my new Fedora Core1 box, to enable successful SMTP AUTH for postfix functionality, here is what I did.

1. I had and/or added the following RPM packages:
cyrus-sasl-2.1.15-6
cyrus-sasl-devel-2.1.15-6
cyrus-sasl-gssapi-2.1.15-6
cyrus-sasl-md5-2.1.15-6
cyrus-sasl-plain-2.1.15-6
postfix-2.0.11-5

2. Added the following lines to the end of my /etc/postfix/main.cf file:
#BEGIN SASL config for SMTP AUTH
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes
#next line looks stupid to keep as a NULL value,
#but is apparently important for sasl to work properly from
#my research. LOADS of stock documentation in /usr/share/doc/postfix/*
#and other websites incorrectly suggest (for this version of
#postfix atleast):smtpd_sasl_local_domain =$myhostname
smtpd_sasl_local_domain =
smtpd_recipient_restrictions =
permit_sasl_authenticated,
permit_mynetworks,
check_relay_domains

#END SASL config for SMTP AUTH

3. Goto /etc/pam.d and created a cyrus file from a copy of my imap file with the following text:
#%PAM-1.0 Sasl for Postfix SMTP AUTH
auth required pam_stack.so service=system-auth
account required pam_stack.so service=system-auth

4. Restarted the Postfix and saslauthd daemons:
/etc/init.d/saslauthd restart
/etc/init.d/postfix restart

5. Review the fairly detailed documentation from the following site to test if your authentication works, specifically Section 12.4:
http://postfix.state-of-mind.de/patr...ilclients.html

FYI: use the perl command below instead of the printf statement to get your base64 encoding
perl -MMIME::Base64 -e 'print encode_base64("username\0username\0password");'

6. Review other documentation of website in #5 for some other config tweaks and how to setup mail clients like Outlook Express to authenticate using SMTP AUTH.

Hope this Helps,

Cyrus (Yes, real name, not the server!!)

P.S. Here is the output from a "postconf -n" to see all non-default settings in my main.cf file incase it matters

alias_database = hash:/etc/postfix/aliases
alias_maps = hash:/etc/postfix/aliases
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
content_filter = smtp-amavis:[127.0.0.1]:10024
daemon_directory = /usr/libexec/postfix
debug_peer_level = 2
inet_interfaces = all
mail_owner = postfix
mailbox_command = /usr/bin/procmail
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
max_use = 10
mydestination = $myhostname, localhost.$mydomain
myhostname = YOURDOMAIN.COM
mynetworks = 192.168.0.0/24, 127.0.0.0/8
mynetworks_style = subnet
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.0.11/README_FILES
sample_directory = /usr/share/doc/postfix-2.0.11/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtpd_recipient_restrictions = permit_sasl_authenticated, permit_mynetworks, check_relay_domains
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_security_options = noanonymous
unknown_local_recipient_reject_code = 450
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
postfix and smtp auth FragInHell Linux - Software 2 10-05-2005 07:23 AM
Postfix SMTP AUTH, Problem using saslauthd + pam k1e0x Debian 0 10-19-2004 06:21 PM
SuSE 9 Postfix SMTP-AUTH Probs... thetimp2003 Linux - Software 1 05-11-2004 03:33 PM
Postfix SMTP Auth Failure pembo13 Linux - Networking 1 02-09-2004 10:08 AM
Postfix SMTP AUTH NetScripter Linux - Software 0 10-23-2002 02:53 AM


All times are GMT -5. The time now is 08:01 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration