PDA

View Full Version : [POSTFIX] No 250-AUTH


boast
29th February 2008, 22:46
SMTP not working

ehlo localhost
250-mail.virtualdomain.com
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-AUTH PLAIN LOGIN
250-AUTH=PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN

my main.cf

alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
append_dot_mydomain = no
biff = no
broken_sasl_auth_clients = yes
config_directory = /etc/postfix
inet_protocols = all
mailbox_command = procmail -a "$EXTENSION"
mailbox_size_limit = 0
mydestination = mailserver.LanDomain, localhost
mydomain = mailserver.LanDomain
myhostname = mailserver.VirtualDomain.com
mynetworks = 127.0.0.0/8, 10.0.0.0/8
myorigin = /etc/mailname
proxy_read_maps = $local_recipient_maps $mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_canonical_maps $recipient_canonical_maps $relocated_maps $transport_maps $mynetworks $virtual_mailbox_limit_maps
recipient_delimiter = +
smtp_host_lookup = native
smtp_sasl_mechanism_filter = plain, login
smtp_tls_note_starttls_offer = yes
smtp_tls_session_cache_database = btree:${queue_directory}/smtp_scache
smtp_use_tls = yes
smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
smtpd_recipient_restrictions = permit_mynetworks permit_sasl_authenticated reject_unauth_destination permit_inet_interfaces reject_unknown_reverse_client_hostname
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_path = smtpd
smtpd_sasl_security_options = noanonymous
smtpd_tls_CAfile = /etc/postfix/ssl/cacert.pem
smtpd_tls_auth_only = no
smtpd_tls_cert_file = /etc/postfix/smtpd.cert
smtpd_tls_key_file = /etc/postfix/smtpd.key
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_session_cache_database = btree:${queue_directory}/smtpd_scache
smtpd_tls_session_cache_timeout = 3600s
smtpd_use_tls = yes
tls_random_source = dev:/dev/urandom
transport_maps = proxy:mysql:/etc/postfix/mysql-virtual_transports.cf
virtual_alias_domains =
virtual_alias_maps = proxy:mysql:/etc/postfix/mysql-virtual_forwardings.cf, mysql:/etc/postfix/mysql-virtual_email2email.cf
virtual_gid_maps = static:5000
virtual_mailbox_base = /home/vmail
virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql-virtual_domains.cf
virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql-virtual_mailboxes.cf
virtual_uid_maps = static:5000

master.cf

smtp inet n - - - - smtpd
#submission inet n - - - - smtpd
-o smtpd_enforce_tls=no
-o smtpd_sasl_auth_enable=yes
-o smtpd_client_restrictions=permit_sasl_authenticate d,reject
smtps inet n - - - - smtpd
-o smtpd_tls_wrappermode=yes
-o smtpd_sasl_auth_enable=yes
-o smtpd_client_restrictions=permit_sasl_authenticate d,reject
#628 inet n - - - - qmqpd
pickup fifo n - - 60 1 pickup
cleanup unix n - - - 0 cleanup
qmgr fifo n - n 300 1 qmgr
#qmgr fifo n - - 300 1 oqmgr
tlsmgr unix - - - 1000? 1 tlsmgr
rewrite unix - - - - - trivial-rewrite
bounce unix - - - - 0 bounce
defer unix - - - - 0 bounce
trace unix - - - - 0 bounce
verify unix - - - - 1 verify
flush unix n - - 1000? 0 flush
proxymap unix - - n - - proxymap
smtp unix - - - - - smtp
# When relaying mail as backup MX, disable fallback_relay to avoid MX loops
relay unix - - - - - smtp
-o fallback_relay=
# -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
showq unix n - - - - showq
error unix - - - - - error
discard unix - - - - - discard
local unix - n n - - local
virtual unix - n n - - virtual
lmtp unix - - - - - lmtp
anvil unix - - - - 1 anvil
scache unix - - - - 1 scache


my /etc/default/saslauthd
# Settings for saslauthd daemon
START=yes

MECHANISMS="pam"

MECH_OPTIONS=""

THREADS=5

OPTIONS="-c -m /var
/spool/postfix/var/run/saslauthd"

my /etc/hosts
127.0.0.1 localhost localhost.local
10.0.0.3 mailserver mailserver.LocalDomain virtualdomain.com
sasl smtpd.conf
pwcheck_method: saslauthd
mech_list: plain login
allow_plaintext: true
auxprop_plugin: mysql
sql_hostnames: 127.0.0.1
sql_user: mail_admin
sql_passwd: 15982
sql_database: mail
sql_select: select password from users where email = '%u'



any ideas? I tried doing the guide over again, but still no luck.

thanks for any help

topdog
1st March 2008, 10:42
This config could be an open relay as in your smtpd_restrictions you do not have reject_unauth_destination.

Try adding that as the last option in smtpd_restrictions.

boast
1st March 2008, 20:17
thanks for that.

I was able to get AUTH to show up by editing master.cf, and changing "-o smtpd_enforce_tls=yes" to "-o smtpd_enforce_tls=no"

I was hoping that would fix my issues, but no.


Mar 1 13:03:14 mail postfix/smtpd[17833]: connect from gv-out-0910.google.com[216.239.58.191]
Mar 1 13:03:14 mail postfix/smtpd[17834]: connect from gv-out-0910.google.com[216.239.58.189]
Mar 1 13:03:14 mail postfix/smtpd[17833]: lost connection after CONNECT from gv-out-0910.google.com[216.239.58.191]
Mar 1 13:03:14 mail postfix/smtpd[17833]: disconnect from gv-out-0910.google.com[216.239.58.191]
Mar 1 13:03:15 mail postfix/smtpd[17834]: NOQUEUE: reject: RCPT from gv-out-0910.google.com[216.239.58.189]: 554 5.7.1 <gv-out-0910.google.com[216.239.58.189]>: Client host rejected: Access denied; from=<myemail@gmail.com> to=<user@server.com> proto=ESMTP helo=<gv-out-0910.google.com>
Mar 1 13:03:15 mail postfix/smtpd[17834]: disconnect from gv-out-0910.google.com[216.239.58.189]

topdog
1st March 2008, 20:27
What are you actually trying to achieve ?

boast
1st March 2008, 21:14
to learn how to setup a (working) mail server

boast
2nd March 2008, 04:22
trying to send email, out, i get

postfix/smtpd[16675]: warning: SASL authentication failure: Password verification failed

mail from: user@virtualdomain.com
250 2.1.0 Ok
rcpt to:user@virtualdomain.com
554 5.7.1 <localhost[127.0.0.1]>: Client host rejected: Access denied

topdog
2nd March 2008, 09:35
Please post the current postfix config files you are using, main.cf and master.cf

boast
2nd March 2008, 18:05
I've been editing/updating my OP

boast
6th April 2008, 06:56
i can only get it to work by commenting out

# -o smtpd_client_restrictions=permit_sasl_authenticate d,reject

is that safe?

falko
7th April 2008, 18:54
How exactly did you set up Postfix? Did you use one of the tutorials from this site?

boast
8th April 2008, 05:03
yeah.

Virtual Users And Domains With Postfix, Courier And MySQL (Debian Etch)

I guess I never read anything about chroot + mysql problems or something

falko
8th April 2008, 11:38
What's in /etc/postfix/master.cf?