Fehler: Authentifizierung vom Client an Dovecot

tim.s
Posts: 1
Joined: 2011-07-06 20:03

Fehler: Authentifizierung vom Client an Dovecot

Post by tim.s »

Hallo an alle,

kurze Info zu meinem Mailserver.
Er dient vorerst nur zur internen Mailverwaltung,später kommt noch ein relayhost dazu.
Verwendet werden folgende Programme: Postfix,Dovecot,Mysql,PHPmyadmin,Postfixadmin,Apache
Ich arbeite mit virtuellen Benutzern,die ich über Postfixadmin erstellt habe.
Auf einem Clientrechner läuft Opera,zum versenden und empfangen von Mails.
Das Versenden der Mails funktioniert,sie liegen dann in den Postfächern der Benutzer.
Nur das Abholen der Mails vom Mailserver scheitert an der Authentifizierung am Mailserver.
Der eingestellte Opera imap-Port ist 143.
Ich weiß im Moment nicht mehr weiter???
Vielleicht sieht von euch jemand den Fehler???


Postfix, main.cf

Code: Select all

#myorigin = /etc/mailname

smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

readme_directory = no

# TLS parameters
smtpd_use_tls = yes
smtpd_tls_cert_file = /etc/ssl/certs/ssl-cert-snakeoil.pem
smtpd_tls_key_file = /etc/ssl/private/ssl-cert-snakeoil.key
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtpd_tls_auth_only = no
smtpd_tls_loglevel = 2
smtpd_tls_received_header = yes
# tls_random_source = dev:/dev/urandom


# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.

myhostname = mailserver.schmidt.de
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
mydestination = mailserver.schmidt.de, localhost.schmidt.de, , localhost
relayhost =
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128  192.168.x.x/24
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
inet_protocols = ipv4

# Virtual mailbox settings
virtual_mailbox_domains = proxy:mysql:$config_directory/mysql_virtual_domains_maps.cf
virtual_mailbox_base = /var/vmail
virtual_mailbox_maps =
    proxy:mysql:$config_directory/mysql_virtual_mailbox_maps.cf,
    proxy:mysql:$config_directory/mysql_virtual_alias_domain_mailbox_maps.cf,
    proxy:mysql:$config_directory/mysql_virtual_alias_domain_catchall_maps.cf
virtual_alias_maps =
    proxy:mysql:$config_directory/mysql_virtual_alias_maps.cf,
    proxy:mysql:$config_directory/mysql_virtual_alias_domain_maps.cf
#virtual_mailbox_limit = proxy:mysql:$config_directory/mysql_virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_maildir_limit_message = Mailbox ist leider voll.
virtual_overquota_bounce = yes
virtual_minimum_uid = 150
virtual_uid_maps = static:150
virtual_gid_maps = static:8
virtual_transport = dovecot
dovecot_destination_recipient_limit = 1
 
# SASL Authentication
smtpd_sasl_auth_enable = yes
smtpd_sasl_exceptions_networks = $mynetworks
# geändert  $myhostname
smtpd_sasl_local_domain =
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth
 
# No open relay!
smtpd_recipient_restrictions =
    permit_mynetworks
    permit_sasl_authenticated
    reject_unauth_destination
 



dovecot.conf

Code: Select all

base_dir = /var/run/dovecot
protocols = imap imaps pop3


# erzwinge AUTH mit STARTTLS,no = passwort wird unverschluesselt uebertragen
disable_plaintext_auth = yes
 
# logging Optionen
log_path = /var/log/dovecot.log
info_log_path = /var/log/dovecot.log
log_timestamp = "%Y-%m-%d %H:%M:%S "
auth_verbose = yes
auth_debug = yes
syslog_facility = mail
 
# SSL/TLS
ssl = yes
ssl_cert_file = /etc/ssl/certs/ssl-cert-snakeoil.pem
ssl_key_file = /etc/ssl/private/ssl-cert-snakeoil.key
verbose_ssl = yes
 
 
# mailbox Einstellungen
mail_location = maildir:/var/vmail/%d/%u
mail_privileged_group = mail
mail_debug = no
 
# gültig ist nur unser vmail-Besitzer
first_valid_uid = 150
last_valid_uid = 150
 
maildir_copy_with_hardlinks = yes
 
# IMAP Optionen
#protocol imap {
#  login_executable = /usr/lib/dovecot/imap-login
#  mail_executable = /usr/lib/dovecot/imap
#  imap_max_line_length = 65536
#  mail_plugin_dir = /usr/lib/dovecot/modules/imap
#}
 
#protocol pop3 {
#  pop3_uidl_format = %08Xu%08Xv
#}
 

# deliver aktivieren
protocol lda {
  postmaster_address = postmaster@schmidt.de
  mail_plugin_dir = /usr/lib/dovecot/modules/lda
  deliver_log_format = msgid=%m: %$
  sendmail_path = /usr/lib/sendmail
  auth_socket_path = /var/run/dovecot/auth-master
}
 
 
# Authentifizierungs-Info aus Datenbank
auth default {
  mechanisms = plain login ntlm
 
  passdb sql {
    args = /etc/dovecot/dovecot-sql.conf
  }
 
  # steigert Performance mit Datenbank
  userdb prefetch {
  }
 
  userdb sql {
    args = /etc/dovecot/dovecot-sql.conf
  }
 
  user = root
 
  socket listen {
     master {
      path = /var/run/dovecot/auth-master
      mode = 0660
      user = postfix
      group = mail
    }
    client {
      path = /var/spool/postfix/private/auth
      mode = 0660
      user = postfix
      group = postfix
    }
  }
}
 



hier die Verbindung zur mysql
dovecot-sql.conf

Code: Select all

driver = mysql
connect = host=localhost dbname=mysql user=postfixadmin password=dblinux
default_pass_scheme = MD5-CRYPT
# Get the mailbox
user_query = SELECT '/var/vmail/%d/%n' as home, 'maildir:/var/vmail/%d/%n' as mail, 150 AS uid, 8 AS gid, CONCAT('*:bytes=', CAST(quota AS CHAR)) AS quota_rule FROM mailbox WHERE username = '%u' AND active = '1'
# Get the password
password_query = SELECT username as user, password, '/var/vmail/%d/%n' as userdb_home, 'maildir:/var/vmail/%d/%n' as userdb_mail, 150 as userdb_uid, 8 as userdb_gid, CONCAT('*:bytes=', CAST(quota AS CHAR)) AS  userdb_quota_rule FROM mailbox WHERE username = '%u' AND active = '1'



dovecot.log

Code: Select all

2011-07-02 16:01:06 dovecot: Warning: Killed with signal 15 (by pid=1508 uid=0 code=kill)
2011-07-02 16:01:06 dovecot: Info: Dovecot v1.2.9 starting up (core dumps disabled)
2011-07-02 16:01:06 auth-worker(default): Info: mysql: Connected to localhost (mysql)
2011-07-02 16:01:13 auth-worker(default): Info: mysql: Connected to localhost (mysql)
2011-07-02 16:01:20 imap-login: Info: Disconnected (auth failed, 1 attempts): user=<xxxx>, method=PLAIN, rip=192.168.x.x, lip=192.168.x.x, TLS: Disconnected
2011-07-02 16:01:20 imap-login: Info: Disconnected (auth failed, 1 attempts): user=<xxxx>, method=PLAIN, rip=192.168.x.x, lip=192.168.x.x, TLS: Disconnected


mfg tim.s
Top