<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Hello</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Actually im not using PAM at all. So yes its true i could drop that.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
But i see that you have put additional empty double colons in your passwd file which i didn't.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
So maybe this is the issue?</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
I will try.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Thank you</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Aki Tuomi <aki.tuomi@open-xchange.com><br>
<b>Sent:</b> Tuesday, November 19, 2019 10:49 PM<br>
<b>To:</b> Andrej Rehak <andrej.rehak@outlook.com>; dovecot@dovecot.org <dovecot@dovecot.org><br>
<b>Subject:</b> Re: Dovecot can't log in Virtual user - please help</font>
<div> </div>
</div>
<div style="background-color:#FFFFFF">
<p><br>
</p>
<div class="x_moz-cite-prefix">On 19.11.2019 19.21, Andrej Rehak via dovecot wrote:<br>
</div>
<blockquote type="cite"><style type="text/css" style="display:none">
<!--
p
{margin-top:0;
margin-bottom:0}
-->
</style>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Hello</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Im having issues login to dovecot using imap through telnet.</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<p style="margin:0px 0px 1em; font-family:Arial,"Helvetica Neue",Helvetica,sans-serif; font-size:15px; clear:both; color:rgb(36,39,41); text-align:left; background-color:rgb(255,255,255)">
Im running<span> </span><code style="">Linux 4.9.0-11-amd64 #1 SMP Debian 4.9.189-3+deb9u1 (2019-09-20) x86_64 GNU/Linux</code></p>
<p style="margin:0px 0px 1em; font-family:Arial,"Helvetica Neue",Helvetica,sans-serif; font-size:15px; clear:both; color:rgb(36,39,41); text-align:left; background-color:rgb(255,255,255)">
Im totally new to setting up mailservers. I havesetup a postfix for SMTP and it can receive emails. Postfix version is<span> </span><code style="">mail_version = 3.1.12</code></p>
<p style="margin:0px 0px 1em; font-family:Arial,"Helvetica Neue",Helvetica,sans-serif; font-size:15px; clear:both; color:rgb(36,39,41); text-align:left; background-color:rgb(255,255,255)">
I have also installed Dovecot version:<code style="">2.2.27 (c0f36b0)</code><span> </span>My configuration is such that POSTFIX is configured to use DOVECOT SASL through local socket.</p>
<p style="margin:0px 0px 1em; font-family:Arial,"Helvetica Neue",Helvetica,sans-serif; font-size:15px; clear:both; color:rgb(36,39,41); text-align:left; background-color:rgb(255,255,255)">
My system is configured to store emails in<span> </span><code style="">/var/mail/owndomain.org/<username></code>. For each domain i have my own passwd file where dovecot is supposed to lookup usernames and passwords.<span> </span><code style="">/var/mail/owndomain.org/passwd</code>.</p>
<p style="margin:0px 0px 1em; font-family:Arial,"Helvetica Neue",Helvetica,sans-serif; font-size:15px; clear:both; color:rgb(36,39,41); text-align:left; background-color:rgb(255,255,255)">
I have created<span> </span><code style="">virtualuser</code><span> </span>for accessing mails and authenticating users. My dovecot (dovecot -n output) configuration is:</p>
<p style="margin:0px 0px 1em; font-family:Arial,"Helvetica Neue",Helvetica,sans-serif; font-size:15px; clear:both; color:rgb(36,39,41); text-align:left; background-color:rgb(255,255,255)">
-------------------------------------------------------------</p>
<div style="margin:0px 0px 15px; font-family:Arial,"Helvetica Neue",Helvetica,sans-serif; font-size:15px; clear:both; color:rgb(36,39,41); text-align:left; background-color:rgb(255,255,255)">
<span># 2.2.27 (c0f36b0): /etc/dovecot/dovecot.conf<br>
</span>
<div># Pigeonhole version 0.4.16 (fed8554)<br>
</div>
<div># OS: Linux 4.9.0-11-amd64 x86_64 Debian 9.11 <br>
</div>
<div>auth_debug = yes<br>
</div>
<div>auth_mechanisms = plain login<br>
</div>
<div>auth_verbose = yes<br>
</div>
<div>debug_log_path = /var/log/dovecot-debug.log<br>
</div>
<div>disable_plaintext_auth = no<br>
</div>
<div>info_log_path = /var/log/dovecot-info.log<br>
</div>
<div>listen = 192.168.2.2<br>
</div>
<div>log_path = /var/log/dovecot.log<br>
</div>
<div>mail_home = /var/mail/home/%d/%n<br>
</div>
<div>mail_location = mbox:~/mail:INBOX=/var/spool/mail/%d/%n<br>
</div>
<div>mail_privileged_group = virtualmail<br>
</div>
<div>namespace inbox {<br>
</div>
<div> inbox = yes<br>
</div>
<div> location = <br>
</div>
<div> mailbox Drafts {<br>
</div>
<div> special_use = \Drafts<br>
</div>
<div> }<br>
</div>
<div> mailbox Junk {<br>
</div>
<div> special_use = \Junk<br>
</div>
<div> }<br>
</div>
<div> mailbox Sent {<br>
</div>
<div> special_use = \Sent<br>
</div>
<div> }<br>
</div>
<div> mailbox "Sent Messages" {<br>
</div>
<div> special_use = \Sent<br>
</div>
<div> }<br>
</div>
<div> mailbox Trash {<br>
</div>
<div> special_use = \Trash<br>
</div>
<div> }<br>
</div>
<div> prefix = <br>
</div>
<div>}<br>
</div>
<div>passdb {<br>
</div>
<div> driver = pam<br>
</div>
<div>}<br>
</div>
<br>
</div>
</div>
</blockquote>
<p><br>
</p>
<p>Are you using PAM intentionally? You might want to drop this along with userdb with passwd as driver. the passwd-file one is ok. By dropping PAM you probably get quite nice speedup, too.<br>
</p>
<p><br>
</p>
<p>But I tested your configuration locally here and it seems to work. At least with following passwd file:</p>
<p><br>
</p>
<p>$ sudo cat /var/mail/owndomain.org/passwd<br>
username:{PLAIN}password:::::<br>
</p>
<p><br>
</p>
<p>Aki<br>
</p>
</div>
</body>
</html>