Hi,
I haven't had that error before and since im quite new to OpenACS, my knowledge is limited.
From what i can gather, you are using SSL and you installed it with SSL. Unfortunately im not exactly sure how SSL works in terms of certificates and i think its a certificate checking problem you are having as opposed to an error in the webmail system.
One possible avenue is to speak to Vlad Seryakov, the ns_imap author. His contact details are provided in the ns_imap module. I have emailed him and pointed him to this discussion aswell.
Sorry i couldnt help further.
Ayman