Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
One more time: Virtual Mailhosting Howto. SMTP AUTH..
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
noganex
n00b
n00b


Joined: 20 Aug 2003
Posts: 57
Location: Germany

PostPosted: Sat Nov 29, 2003 8:28 pm    Post subject: One more time: Virtual Mailhosting Howto. SMTP AUTH.. Reply with quote

Hi Folks!

Again I've got some problems with the Virtual Mailhosting Howto.. (Maybe the last :))

I dont use any local mail accounts. All virtual...

This is what works atm:
+ Postfix receives mails from remote hosts and the local host.
+ The mails can be accessed via IMAP/POP3 from remote and local hosts.
+ I can send mails to remote hosts via squirrellmail.

The only thing i didnt get working is:
+ Sending mails via Postfix from remote hosts.

I tried to send a mail using Sylpheed. Sylpheed says "Error 535: authentication failed."

Here some logs:

/var/log/auth.log:
Quote:
Nov 29 21:18:31 p15138442 PAM_pwdb[5236]: check pass; user unknown
Nov 29 21:18:31 p15138442 saslauthd[5236]: pam_mysql: error: sqllog set but logtable not set
Nov 29 21:18:31 p15138442 saslauthd[5236]: pam_mysql: error: sqllog set but logmsgcolumn not set
Nov 29 21:18:31 p15138442 saslauthd[5236]: pam_mysql: error: sqllog set but logusercolumn not set
Nov 29 21:18:31 p15138442 saslauthd[5236]: pam_mysql: error: sqllog set but loghostcolumn not set
Nov 29 21:18:31 p15138442 saslauthd[5236]: pam_mysql: error: sqllog set but logtimecolumn not set
Nov 29 21:18:32 p15138442 saslauthd[5236]: DEBUG: auth_pam: pam_authenticate failed: User not known to the underlying authentication module
Nov 29 21:18:32 p15138442 saslauthd[5236]: do_auth : auth failure: [user=mail@l33tcode.org] [service=smtp] [realm=] [mech=pam] [reason=PAM auth error]


/var/log/mail.info:
Quote:
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: connect from p508BF3A9.dip.t-dialin.net[80.139.243.169]
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 220 p15138442.pureserver.info ESMTP Postfix
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: watchdog_pat: 0x809e260
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: < p508BF3A9.dip.t-dialin.net[80.139.243.169]: EHLO anarchy
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250-p15138442.pureserver.info
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250-PIPELINING
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250-SIZE 10240000
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250-VRFY
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250-ETRN
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250-STARTTLS
Nov 29 21:18:30 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250-AUTH LOGIN PLAIN
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250-AUTH=LOGIN PLAIN
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: match_hostname: p508BF3A9.dip.t-dialin.net ~? 127.0.0.0/8
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: match_hostaddr: 80.139.243.169 ~? 127.0.0.0/8
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: match_list_match: p508BF3A9.dip.t-dialin.net: no match
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: match_list_match: 80.139.243.169: no match
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 250 8BITMIME
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: watchdog_pat: 0x809e260
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: < p508BF3A9.dip.t-dialin.net[80.139.243.169]: AUTH LOGIN
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: smtpd_sasl_authenticate: sasl_method LOGIN
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: smtpd_sasl_authenticate: uncoded challenge: Username:
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 334 VXNlcm5hbWU6
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: < p508BF3A9.dip.t-dialin.net[80.139.243.169]: bWFpbEBsMzN0Y29kZS5vcmc=
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: smtpd_sasl_authenticate: decoded response: mail@l33tcode.org
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: smtpd_sasl_authenticate: uncoded challenge: Password:
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 334 UGFzc3dvcmQ6
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: < p508BF3A9.dip.t-dialin.net[80.139.243.169]: Zm9vYmFyb3duYWdl
Nov 29 21:18:31 p15138442 postfix/smtpd[6363]: smtpd_sasl_authenticate: decoded response: ***** // ;)
Nov 29 21:18:32 p15138442 postfix/smtpd[6363]: warning: p508BF3A9.dip.t-dialin.net[80.139.243.169]: SASL LOGIN authentication failed
Nov 29 21:18:32 p15138442 postfix/smtpd[6363]: > p508BF3A9.dip.t-dialin.net[80.139.243.169]: 535 Error: authentication failed
Nov 29 21:18:33 p15138442 postfix/smtpd[6363]: watchdog_pat: 0x809e260


And here some config cr**:

/etc/pam.d/smtp:
Quote:
auth optional pam_mysql.so host=localhost db=mailsql user=mailsql \
passwd=****** table=users usercolumn=email passwdcolumn=clear crypt=0
account required pam_mysql.so host=localhost db=mailsql user=mailsql \
passwd=****** table=users usercolumn=email passwdcolumn=clear crypt=0


/etc/postfix/main.cf:
Quote:
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/lib/postfix
mail_owner = postfix

myhostname = p15138442.pureserver.info
mydomain = pureserver.info

inet_interfaces = all
mydestination =
$myhostname
localhost.$mydomain
$mydomain

local_recipient_maps = $alias_maps $virtual_mailbox_maps unix:passwd.byname
unknown_local_recipient_reject_code = 450

mynetworks = 127.0.0.0/8
relay_domains = $mydestination

alias_maps = mysql:/etc/postfix/mysql-aliases.cf
relocated_maps = mysql:/etc/postfix/mysql-relocated.cf
local_transport = local
alias_database = hash:/etc/mail/aliases

home_mailbox = .maildir/

local_destination_concurrency_limit = 2
default_destination_concurrency_limit = 10

debug_peer_level = 2

debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
xxgdb $daemon_directory/$process_name $process_id & sleep 5


sendmail_path = /usr/sbin/sendmail
newaliases_path = /usr/bin/newaliases
mailq_path = /usr/bin/mailq
setgid_group = postdrop
manpage_directory = /usr/share/man
sample_directory = /etc/postfix/sample
readme_directory = /usr/share/doc/postfix-2.0.11

smtpd_sasl_auth_enable = yes
smtpd_sasl2_auth_enable = yes
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes
smtpd_sasl_local_domain =

smtpd_recipient_restrictions = permit_sasl_authenticated permit_mynetworks reject_unauth_destination

smtpd_use_tls = yes
smtpd_tls_key_file = /etc/postfix/newreq.pem
smtpd_tls_cert_file = /etc/postfix/newcert.pem
smtpd_tls_CAfile = /etc/postfix/cacert.pem
smtpd_tls_loglevel = 3
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom

virtual_transport = virtual
virtual_mailbox_domains = mysql:/etc/postfix/mysql-transport.cf

virtual_minimum_uid = 1000
virtual_gid_maps = static:100
virtual_mailbox_maps = mysql:/etc/postfix/mysql-virtual-maps.cf
virtual_alias_maps = mysql:/etc/postfix/mysql-virtual.cf
virtual_uid_maps = static:1015
virtual_mailbox_base = /


So i spent already 3h searching the forum and google and it still doesnt work.. :(

I would be really happy if somebody helps me..
I can't find the bug.. :(

ciao noganex
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum