View Full Version : Imap login error (UID issue?)
elbarto
10-08-2008, 03:32 PM
Hey guys, I'm having a problem with a fresh install of directadmin.
When I try to login I get the error "internal login failure".
(I'm changing the domain and user's data for privacy. Also I changed the IP address for 255.255.255.255)
elbarto@tarantino:~$ nc mydomain.net 143
1* OK Dovecot DA ready.
1 login myuser@mydomain.net mypasswd
* BYE Internal login failure. Refer to server log for more information.
So, I set up Dovecot for logging and check the log and this is what I get.
dovecot: Oct 08 18:09:44 Info: auth(default): shadow(myuser@mydomain.net,255.255.255.255): unknown user
dovecot: Oct 08 18:09:44 Info: auth(default): passwd(myuser@mydomain.net, 255.255.255.255): unknown user
dovecot: Oct 08 18:09:44 Error: User myuser@mydomain.net is missing UID (set mail_uid)
dovecot: Oct 08 18:09:44 Info: imap-login: Internal login failure (auth failed, 1 attempts): user=<myuser@mydomain.net>, method=PLAIN, rip=255.255.255.255, lip=255.255.255.254
I searched the web for a while and guess the problem could be con my passwd file, here is what I got:
[root@myserver ~]# cat /etc/virtual/mydomain.net/passwd
myuser:$1$fE0bzn7C$66MfTD1nnyuuNup6Dm5yA/
My guess is that UID and GID are missing on that file, but as it was created by DA, I guess there would be some configuration error somewhere.
Can you give me a hand?
Thanks in advance!
elbarto
10-09-2008, 07:04 AM
I did some more testing.
I tried modifying the passwd file and put something like this:
myuser:$1$fE0bzn7C$66MfTD1nnyuuNup6Dm5yA/:500:12::/home/myuser/mydomain.net/Maildir:/bin/false
And it worked. Now I think there's a problem when creating a new e-mail account from DA. Should DA create the record at /etc/virtual/<domain>/passwd with the corresponding UID and GID? If so, which could be the reason for not doing it? Any ideas?
Thanks!
elbarto
10-09-2008, 07:11 AM
Correction, I had to change it again because the MailDir path was wrong. This one seems to work:
myuser:$1$fE0bzn7C$66MfTD1nnyuuNup6Dm5yA/:500:12::/home/user/imap/mydomain.net/myuser/Maildir:/bin/false
nobaloney
10-10-2008, 11:54 AM
Presuming you've modified the file at /etc/passwd ...
If you're storing passwords in /etc/passwd you may have a security issue on your server, especially if you use insecure passwords.
Also ... now that you've exposed the hash for that user's passoword it's no longer a secure password; you should change it.
Jeff
elbarto
10-11-2008, 09:39 AM
1 - What I've posted it's not /etc/passwd, is /etc/virtual/mydomain/passwd. Besides, additional security measures for not allowing common users login are being taken.
2 - "myuser" doesn't actually exist, but anyway the hash belongs to a test user which does not longer exist
Now, back to my problem, do you know why DA is creating users without the UID and GID, which causes that none of them can login via IMAP or POP3?
Maybe it has nothing to do with /etc/virtual/mydomain/passwd, but modifying that file seemed to do the trick.
nobaloney
10-11-2008, 04:44 PM
I have no idea why it's not working on your system; perhaps you should have DirectAdmin Support (http://www.directadmin.com/support.html) take a look at your system.
Jeff
elbarto
10-13-2008, 07:40 PM
Ok, thanks anyway.
I'll try to contact the person who originally installed DA on my system.
pietjepuk
10-15-2008, 10:59 AM
Did you already found out what it is/was ? Ive got the same problem here.
elbarto
10-15-2008, 05:39 PM
Not so far, but if you get any further, it would be great that you share it.
Regards
ardactn
11-17-2008, 06:07 AM
I got the some problem too.
Is there any solution about that?
DirectAdmin Support
11-17-2008, 11:26 PM
Hello,
Just as a followup (since no solution was posted) the reason that services like squirrelmail often cannot connect to imap is because the line:
127.0.0.1 localhostis missing from the /etc/hosts file.
Simply adding that line to the /etc/hosts file can sort that out.
I think I'll just add a check for that in the setup.sh so nobody needs to worry about it anymore (for new installs).
John
Dromok
12-12-2008, 08:20 PM
I have this problem too.
/etc/hosts is correct.
What's problem?
pug123
01-05-2009, 12:05 AM
I have the same problem. How to solve it??
pcwitchdoctor
07-01-2009, 05:38 PM
Same problem here.
Has anyone found a solution to this yet? Seems to be a lot of people with this problem.
nobaloney
07-01-2009, 05:52 PM
Please post the specific problem. Include any error messages.
Post also your main IP#.
Thanks.
Jeff
pcwitchdoctor
07-01-2009, 05:58 PM
Please post the specific problem. Include any error messages.
Post also your main IP#.
Thanks.
Jeff
My exim.conf dovecot.conf directadmin.conf are all posted here: http://www.directadmin.com/forum/showthread.php?t=31601
I emailed you as per you last post but have had no reply.
DirectAdmin Support
07-02-2009, 12:48 AM
http://help.directadmin.com/item.php?id=219
John
pcwitchdoctor
07-02-2009, 06:39 AM
http://help.directadmin.com/item.php?id=219
John
If you look closely, the error in this is not the same as the error we are getting. Plus, as I have said in my other post, I've already tried that anyway.
We are not getting a UID=1.
dovecot=1 is in the config.
If you look at the errors in our logs it says the UID is missing. It does not say the UID is set to 1.
It would appear that when DirectAdmin is creating the virtual email accounts, it is missing the UID information that dovecot is looking for.
nobaloney
07-02-2009, 01:24 PM
If you've emailed me, then I don't see the email. Did you email me at the address shown in my siglines? What was the subject line?
Jeff
pcwitchdoctor
07-02-2009, 03:26 PM
If you've emailed me, then I don't see the email. Did you email me at the address shown in my siglines? What was the subject line?
Jeff
Email sent to email in your siglines from my gmail account with subject: I'm the person with the email login problem.
nobaloney
07-03-2009, 10:06 AM
I've edited your post to remove both your email address and mine. I only asked if you used the address in my siglines (which I can change at any time) and the post. I've found your email; you didn't link back to the post.
I'll reply today and can work during the weekend (but not today; I need to make a trip to the datacenter).
Jeff
Powered by vBulletin™ Version 4.0.4 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.