LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-02-2010, 08:31 AM   #1
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,052

Rep: Reputation: 70
I have a question about dovecot...


I just finished installing postfix and dovecot. I got postfix to work. Trying to setup dovecot to use PAM. I thought PAM always means that it uses the linux login credentials /etc/passwd auto? I enabled pam, yet I think I need to make a mysql database of the credentials. When I start dovecot, I get the error "Warning: There is no way to login to this server: disable_plaintext_auth=yes, ssl=no, no non-plaintext auth mechanisms."

Is it possible to setup dovecot to use PAM based on the /etc/passwd file or do you HAVE to use mysql or postgresql database to hold the credentials?

Last edited by trist007; 02-02-2010 at 08:59 AM.
 
Old 02-02-2010, 09:53 AM   #2
Dave_Devnull
Member
 
Registered: May 2009
Posts: 142

Rep: Reputation: 24
Does this help?

http://wiki.dovecot.org/PasswordDatabase/PAM
 
Old 02-02-2010, 10:17 AM   #3
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,052

Original Poster
Rep: Reputation: 70
Nice thanks. I can't seem to find /etc/pam.d or /usr/local/etc/pam.d. Isn't PAM the method that I use to login to my linux computer which checks my credentials against /etc/passwd and /etc/shadow? Shouldn't it be in there already by default? I guess I'm just confused as to what PAM actually is. All the sites are a bit ambiguous. So if PAM is not installed into my computer, when I login with my user/pass from /etc/passwd, what system is being used if it's not PAM?

Last edited by trist007; 02-02-2010 at 10:43 AM.
 
Old 02-02-2010, 10:42 AM   #4
Dave_Devnull
Member
 
Registered: May 2009
Posts: 142

Rep: Reputation: 24
Reading this: http://www.installationwiki.org/PAM
Says this:
"Slackware is one of the last PAM-free Linux distributions and in UNIX operating systems like AIX, PAM is an add-on product."

Which may be your issue - I can't speak for Slackware.

Last edited by Dave_Devnull; 02-02-2010 at 10:45 AM.
 
Old 02-02-2010, 11:13 AM   #5
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,052

Original Poster
Rep: Reputation: 70
Thanks a bunch, I'm going to investigate why slackware wouldn't not want to take up PAM and what the advantages/disadvantages of not using PAM are. Thanks a ton.
 
Old 02-02-2010, 01:57 PM   #6
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,052

Original Poster
Rep: Reputation: 70
After some research I see that I would like to use Name Service Switch with dovecot for authentication. My /etc/nsswitch.conf is up and running. In my dovecot.conf, there is this section of code:

Code:
 # System users (NSS, /etc/passwd, or similiar)
  # In many systems nowadays this uses Name Service Switch, which is
  # configured in /etc/nsswitch.conf. <doc/wiki/AuthDatabase.Passwd.txt>
  passdb passwd {
    # [blocking=yes] - See userdb passwd for explanation
    args =
  }
I removed the comments before 'passdb password {' and the '}'. However, when I start up dovecot, I get this error.

Code:
Warning: There is no way to login to this server: disable_plaintext_auth=yes, ssl=no, no non-plaintext auth mechanisms.
Warning: There is no way to login to this server: disable_plaintext_auth=yes, ssl=no, no non-plaintext auth mechanisms.
So I uncommented the line
disable_plaintext_auth=no

Now dovecot runs without errors. However, when I netcat into port 110, I get this:

Code:
+OK Dovecot ready.
user john
+OK
pass candy
-ERR [IN-USE] Temporary authentication failure.
This username and password are the ones in my /etc/passwd file is used by nss.
Can anybody point me in the right direction.

Last edited by trist007; 02-02-2010 at 02:10 PM.
 
Old 02-03-2010, 01:33 AM   #7
Dave_Devnull
Member
 
Registered: May 2009
Posts: 142

Rep: Reputation: 24
Beyond my knowledge I'm afraid - sorry I can't be more help to you.
 
Old 02-03-2010, 08:27 AM   #8
trist007
Senior Member
 
Registered: May 2008
Distribution: Slackware
Posts: 1,052

Original Poster
Rep: Reputation: 70
I was able to fix it by creating a file /etc/passwd.dovecot and populated it with users and passwrds. Here's an example of one user/password:

Code:
john:{PLAIN}scissors21
and added '/etc/passwd.dovecot' to the dovecot.conf
Code:
 passdb passwd-file {
    # File contains a list of usernames, one per line
    args = /etc/passwd.dovecot
    #deny = yes
  }
Now it works great, w00t

Last edited by trist007; 02-03-2010 at 09:11 AM.
 
1 members found this post helpful.
Old 02-03-2010, 08:58 AM   #9
Dave_Devnull
Member
 
Registered: May 2009
Posts: 142

Rep: Reputation: 24
SCORE! Thanks for following up - this will be very helpful to anyone else looking for the answer.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Dovecot maildir question on structure wadesmart Linux - Server 1 01-30-2010 09:13 PM
Postfix - Dovecot userdb question clau_bolson Linux - Software 0 06-23-2009 10:09 AM
Postfix/Dovecot Logging Question tbeehler Linux - Software 6 10-31-2008 01:08 PM
dovecot auth question Gortex Linux - Server 1 06-16-2008 08:08 PM
Dovecot SSL cert question Archer36 Slackware 1 11-26-2006 04:03 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:27 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration