protocols = imap lmtp
listen = 198.251.81.119, 2605:6400:10:5bf::, 127.0.0.1

service lmtp {
  user = vmail
}

service imap-login {
  inet_listener imap {
    address = *
    port = 143
  }
  inet_listener imaps {
    address = *
    port = 993
     ssl = yes
  }
  user = _dovecot
  group = _dovecot
  executable = /usr/local/libexec/dovecot/imap-login
}

service auth {
  user = _dovecot
  group = _dovecot
  executable = /usr/local/libexec/dovecot/auth
}

service quota-warning {
  executable = script /usr/local/libexec/dovecot/quota-warning.sh
  unix_listener quota-warning {
  mode = 0600
    user = vmail
    group = vmail
  }
}


quota_full_tempfail = yes

ssl = yes
ssl_cert = </etc/ssl/mail.nastycode.com.crt
ssl_key = </etc/ssl/private/mail.nastycode.com.key
#ssl_dh_parameters_length = 2048
ssl_cipher_list = ALL:!LOW:!SSLv2

mail_location = maildir:/var/vmail/%d/%n/Maildir
mail_uid = 1024
mail_gid = 1024

valid_chroot_dirs = /var/vmail

log_path = /var/log/dovecot.err
info_log_path = /var/log/dovecot.info
log_timestamp = "%Y-%m-%d %H:%M:%S "

login_greeting = Dovecot ready.

disable_plaintext_auth = no

auth_verbose = yes
auth_debug = yes
auth_debug_passwords = yes
mail_debug = yes
auth_verbose_passwords=sha1
verbose_ssl=yes


auth_mechanisms = plain

passdb {
  driver = passwd-file
  args = /etc/dovecot/users.txt
}

userdb {
   args = uid=vmail gid=vmail home=/var/vmail/%d/%n
   driver = static
}
