email Listener error- email port enable failed

I added an email port , provided with all the email server information , it is a IMAP type , when trying to enable port it results into Failed to start Emaillistener on Server IMAP:[ISS.0070.9003] Enable failed: Could not log into account.
Username and password are correct, upon testing with telnet servername portnumber from IS server it connects to mailserver and is ok , I am able to send email using SMTP , only when trying to enable email port this error keeps coming.
Anybody who has encountered simillar problem.Could someone assist?
Thanks in advance.

If you are sure username/password is correct, then ensure you use proper IMAP port, and if SSL then check certificates.

Look the error log, enable port logging facilities to get additional data, set -Dmail.debug=true option on the JVM. You need additional logs to understand what is happening.