Hi,
I installed squirrelmail, courier-imap on debian. As I am integrating squirrelmail with one fo my current appllication, I don't require squirrelmail login, I have my own login scripts. So I bypass squirrelmail login and write the sessions and set cookies which squirrelmail login does. The users are directly taken to the webmail.php page, however on this page I keep getting this error msgs -
ERROR:
ERROR: Could not complete request.
Query: SELECT "INBOX"
Reason Given: Unable to open this mailbox.

I have set the Debug_Login = 2
so my mail.log looks like this -

Nov 28 13:10:32 localhost imaplogin: Connection, ip=[::ffff:127.0.0.1]
Nov 28 13:10:32 localhost authdaemond.plain: received auth request, service=imap, authtype=login
Nov 28 13:10:32 localhost authdaemond.plain: authuserdb: trying this module
Nov 28 13:10:32 localhost authdaemond.plain: userdb: opened /etc/courier/userdb.dat
Nov 28 13:10:32 localhost authdaemond.plain: userdb: looking up 'mohit'
Nov 28 13:10:32 localhost authdaemond.plain: userdb: home=/home/user, uid=1288, gid=100, shell=<unset>, mail=/var/puremail/spool/b1/553/, quota=<unset>, gecos=<unset>, options=<unset>
Nov 28 13:10:32 localhost authdaemond.plain: found systempw in userdbshadow
Nov 28 13:10:32 localhost authdaemond.plain: authuserdb: sysusername=user, sysuserid=1288, sysgroupid=100, homedir=/home/mohit, address=user, fullname=<null>, maildir=/var/puremail/spool/b1/553/, quota=<null>, options=<null>
Nov 28 13:10:32 localhost authdaemond.plain: authuserdb: clearpasswd=<null>, passwd=2MXJxXzUF/4jg
Nov 28 13:10:32 localhost authdaemond.plain: supplied password '..c.' does not match encrypted password '2MXJxXzUF/4jg'
Nov 28 13:10:32 localhost authdaemond.plain: authuserdb: REJECT - try next module
Nov 28 13:10:32 localhost authdaemond.plain: FAIL, all modules rejected
Nov 28 13:10:37 localhost imaplogin: LOGIN FAILED, ip=[::ffff:127.0.0.1]
Nov 28 13:10:37 localhost imaplogin: DISCONNECTED, ip=[::ffff:127.0.0.1], time=5
Nov 28 13:10:38 localhost imaplogin: Connection, ip=[::ffff:127.0.0.1]
Nov 28 13:10:38 localhost authdaemond.plain: received auth request, service=imap, authtype=login
Nov 28 13:10:38 localhost authdaemond.plain: authuserdb: trying this module
Nov 28 13:10:38 localhost authdaemond.plain: userdb: opened /etc/courier/userdb.dat
Nov 28 13:10:38 localhost authdaemond.plain: userdb: looking up 'user'
Nov 28 13:10:38 localhost authdaemond.plain: userdb: home=/home/user, uid=1288, gid=100, shell=<unset>, mail=/var/puremail/spool/b1/553/, quota=<unset>, gecos=<unset>, options=<unset>
Nov 28 13:10:38 localhost authdaemond.plain: found systempw in userdbshadow
Nov 28 13:10:38 localhost authdaemond.plain: authuserdb: sysusername=user, sysuserid=1288, sysgroupid=100, homedir=/home/mohit, address=user, fullname=<null>, maildir=/var/puremail/spool/b1/553/, quota=<null>, options=<null>
Nov 28 13:10:38 localhost authdaemond.plain: authuserdb: clearpasswd=<null>, passwd=2MXJxXzUF/4jg
Nov 28 13:10:38 localhost authdaemond.plain: password matches successfully
Nov 28 13:10:38 localhost authdaemond.plain: authuserdb: ACCEPT, username user
Nov 28 13:10:38 localhost imaplogin: LOGIN, user=mohit, ip=[::ffff:127.0.0.1], protocol=IMAP
Nov 28 13:10:38 localhost imaplogin: DISCONNECTED, user=mohit, ip=[::ffff:127.0.0.1], headers=0, body=0, time=0

I am unable to figure out why imap login in failing. Appreciate any help in this regards
Thanks