OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Re: smtp, amavis, mysql auth failures sending mail

From: 767 (767gmx.net)
Date: Wed Nov 23 2005 - 04:48:33 CST


Thanks Patrick. Here it is:

saslfinger - postfix Cyrus sasl configuration Wed Nov 23 11:42:31 CET 2005
version: 0.9.9.1
mode: server-side SMTP AUTH

-- basics --
Postfix: 2.2.2
System:
Welcome to SuSE Linux 9.1 (i586) - Kernel \r (\l).

-- smtpd is linked to --
        libsasl2.so.2 => /usr/local/lib/libsasl2.so.2 (0x40040000)

-- active SMTP AUTH and TLS parameters for smtpd --
broken_sasl_auth_clients = yes
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_tls_cert_file = /etc/postfix/postfix.pem
smtpd_tls_key_file = $smtpd_tls_cert_file
smtpd_use_tls = no

-- listing of /usr/lib/sasl2 --
total 216
drwxr-xr-x 2 root root 4096 Nov 7 21:43 .
drwxr-xr-x 44 root root 12288 Nov 8 13:40 ..
-rwxr-xr-x 1 root root 695 Apr 6 2004 libanonymous.la
-rwxr-xr-x 1 root root 16099 Apr 6 2004 libanonymous.so
-rwxr-xr-x 1 root root 16099 Apr 6 2004 libanonymous.so.2
-rwxr-xr-x 1 root root 16099 Apr 6 2004 libanonymous.so.2.0.18
-rwxr-xr-x 1 root root 679 Apr 6 2004 liblogin.la
-rwxr-xr-x 1 root root 16811 Apr 6 2004 liblogin.so
-rwxr-xr-x 1 root root 16811 Apr 6 2004 liblogin.so.2
-rwxr-xr-x 1 root root 16811 Apr 6 2004 liblogin.so.2.0.18
-rwxr-xr-x 1 root root 704 Apr 6 2004 libsasldb.la
-rwxr-xr-x 1 root root 21330 Apr 6 2004 libsasldb.so
-rwxr-xr-x 1 root root 21330 Apr 6 2004 libsasldb.so.2
-rwxr-xr-x 1 root root 21330 Apr 6 2004 libsasldb.so.2.0.18
drwxr-xr-x 2 root root 4096 Nov 17 11:15 sasl2

-- listing of /usr/local/lib/sasl2 --
total 3784
drwxr-xr-x 2 root root 4096 Nov 17 11:15 .
drwxr-xr-x 6 root root 4096 Nov 20 18:16 ..
-rwxr-xr-x 1 root root 717 Nov 17 11:15 libanonymous.la
-rwxr-xr-x 1 root root 50837 Nov 17 11:15 libanonymous.so
-rwxr-xr-x 1 root root 50837 Nov 17 11:15 libanonymous.so.2
-rwxr-xr-x 1 root root 50837 Nov 17 11:15 libanonymous.so.2.0.20
-rwxr-xr-x 1 root root 701 Nov 17 11:15 liblogin.la
-rwxr-xr-x 1 root root 51953 Nov 17 11:15 liblogin.so
-rwxr-xr-x 1 root root 51953 Nov 17 11:15 liblogin.so.2
-rwxr-xr-x 1 root root 51953 Nov 17 11:15 liblogin.so.2.0.20
-rwxr-xr-x 1 root root 701 Nov 17 11:15 libplain.la
-rwxr-xr-x 1 root root 52047 Nov 17 11:15 libplain.so
-rwxr-xr-x 1 root root 52047 Nov 17 11:15 libplain.so.2
-rwxr-xr-x 1 root root 52047 Nov 17 11:15 libplain.so.2.0.20
-rwxr-xr-x 1 root root 734 Nov 17 11:15 libsql.la
-rwxr-xr-x 1 root root 1121574 Nov 17 11:15 libsql.so
-rwxr-xr-x 1 root root 1121574 Nov 17 11:15 libsql.so.2
-rwxr-xr-x 1 root root 1121574 Nov 17 11:15 libsql.so.2.0.20
-r-------- 1 postfix postfix 271 Nov 22 17:58 smtpd.conf

-- content of /usr/local/lib/sasl2/smtpd.conf --
# smtpd.conf
pwcheck_method: auxprop
auxprop_plugin: sql
mech_list: plain login

sql_engine: mysql
sql_hostnames: localhost
sql_user: --- replaced ---
sql_passwd: --- replaced ---
sql_database: mail
sql_select: select clear from postfix_users where email='%u%r' and
smtpaccess='Y'

-- active services in /etc/postfix/master.cf --
# service type private unpriv chroot wakeup maxproc command + args
# (yes) (yes) (yes) (never) (100)
smtp inet n - n - - smtpd -v
pickup fifo n - n 60 1 pickup
cleanup unix n - n - 0 cleanup
qmgr fifo n - n 300 1 qmgr
tlsmgr unix - - n 1000? 1 tlsmgr
rewrite unix - - n - - trivial-rewrite
bounce unix - - n - 0 bounce
defer unix - - n - 0 bounce
trace unix - - n - 0 bounce
verify unix - - n - 1 verify
flush unix n - n 1000? 0 flush
proxymap unix - - n - - proxymap
smtp unix - - n - - smtp
relay unix - - n - - smtp
        -o fallback_relay=
showq unix n - n - - showq
error unix - - n - - error
discard unix - - n - - discard
local unix - n n - - local
virtual unix - n n - - virtual
lmtp unix - - n - - lmtp
anvil unix - - n - 1 anvil
scache unix - - n - 1 scache
maildrop unix - n n - - pipe
  flags=Ru user=vmail argv=/usr/local/bin/maildrop -d ${recipient}
old-cyrus unix - n n - - pipe
  flags=R user=cyrus argv=/cyrus/bin/deliver -e -m ${extension} ${user}
cyrus unix - n n - - pipe
  user=cyrus argv=/cyrus/bin/deliver -e -r ${sender} -m ${extension} ${user}
uucp unix - n n - - pipe
  flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail
($recipient)
ifmail unix - n n - - pipe
  flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp unix - n n - - pipe
  flags=Fq. user=foo argv=/usr/local/sbin/bsmtp -f $sender $nexthop
$recipient

smtp-amavis unix - - n - 2 lmtp
    -o lmtp_data_done_timeout=1200
    -o lmtp_send_xforward_command=yes

127.0.0.1:10025 inet n - n - - smtpd
    -o content_filter=
    -o local_recipient_maps=
    -o relay_recipient_maps=
    -o smtpd_restriction_classes=
    -o smtpd_client_restrictions=
    -o smtpd_helo_restrictions=
    -o smtpd_sender_restrictions=
    -o smtpd_recipient_restrictions=permit_mynetworks,reject
    -o mynetworks=127.0.0.0/8

-- mechanisms on localhost --
250-AUTH LOGIN PLAIN
250-AUTH=LOGIN PLAIN

-- end of saslfinger output --

>* 767 <767gmx.net>:
>
>
>>Hi again,
>>
>>I'm running postfix, courier, sasl, mysql, spamassassin.
>>Recently, I've added clam and amavis to add protection against sober & co.
>>I was following the instructions at
>>http://genco.gen.tc/postfix_virtual.php to install - all seems to work
>>fine, incoming mail gets checked and everthing.
>>But some changes must have changed SMTP-authentication, because it
>>doesn't auth against mysql anymore (I don't see any queries coming in
>>mysql-log).
>>I added -v to smtp in master.cf, which fills the logs, but I can't see
>>any useful info there, example:
>>
>>
>
>Use "saslfinger -s" to create useful configuration output. See my signature
>for saslfinger download.
>
>prick
>
>
>