ClearFoundation Tracker - ClearOS
View Issue Details
0001212ClearOSapp-imap - IMAP and POP Serverpublic2013-07-03 13:262013-08-22 16:16
NickH 
user2 
normalminoralways
closedfixed 
6.4.0 
6.4.0 Updates6.4.0 Updates 
0001212: Can no longer sign in to cyradm
Normally if you issue the command "cyradm --user root 127.0.0.1" you get prompted for roots password. This still happens but now you get prompted for an IMAP password as well. No password I know works here
Issue the command "cyradm --user root 127.0.0.1" then enter root's password when prompted. You will then be prompted for an "IMAP Password" which is not normal and will fail with a perl error:

[root@server ~]# cyradm --user root 127.0.0.1
Password:
IMAP Password:
              Login failed: authentication failure at /usr/lib64/perl5/vendor_perl/Cyrus/IMAP/Admin.pm line 120
cyradm: cannot authenticate to server with as root
No tags attached.
Issue History
2013-07-03 13:26NickHNew Issue
2013-07-04 10:13user2Assigned To => user2
2013-07-04 10:13user2Statusnew => confirmed
2013-07-04 10:13user2Note Added: 0000913
2013-07-04 12:15user2Categorycyrus-imapd => app-imap - IMAP and POP Server
2013-07-04 12:15user2Target Version => 6.4.0 Updates
2013-07-04 12:16user2Checkin
2013-07-04 12:16user2Note Added: 0000914
2013-07-04 12:16user2Statusconfirmed => resolved
2013-07-04 12:16user2Fixed in Version => 6.4.0 Updates
2013-07-04 12:16user2Resolutionopen => fixed
2013-08-22 16:16user2Statusresolved => closed

Notes
(0000913)
user2   
2013-07-04 10:13   
Found the problem. The PAM system only allows logins for users in the "imap_plugin" group (i.e. users that have the "IMAP and POP Server" option enabled in the User Manager). When I temporarily disable this requirement, the root login works. To duplicate this:

- Edit /etc/pam.d/imap

- Comment out:
  # account required pam_listfile.so item=group sense=allow file=/etc/clearos/imap.d/authorize onerr=fail

- Try cyradm


Solution: add "root" group to the /etc/clearos/imap.d/authorize:

imap_plugin
root
(0000914)
user2   
2013-07-04 12:16   
Source Code Changelog
---------------------------------------------------
Added root to PAM authorize list to allow cyradm access [tracker 0001212]

File Changes
---------------------------------------------------
Details: http://code.clearfoundation.com/svn/revision.php?repname=ClearOS&rev=6181 [^]
U webconfig/apps/imap/trunk/deploy/upgrade
U webconfig/apps/imap/trunk/packaging/authorize