Horde broken - says error connecting to IMAP

Community support for Plesk, CPanel, WebMin and others with insight from two of the founders of Plesk. Ask for help here! No question is too simple or complicated. :-)
dcottle
Forum User
Forum User
Posts: 9
Joined: Thu Jul 17, 2008 8:19 pm

Horde broken - says error connecting to IMAP

Unread post by dcottle »

Any idea's as IMAP is working, my iPhone and iPad can read their emails.

When I log into webmail after inputting user /password I get kicked back to the login page with:

Error connecting to IMAP server: [] .

What is interesting is the last successful login time does increase with each attempt. So horde is now broken as it can't connect to a running IMAP server when nothings been changed!

No idea what is wrong as no config files have been touched.
biggles
Forum Regular
Forum Regular
Posts: 806
Joined: Tue Jul 15, 2008 2:38 pm
Location: Sweden
Contact:

Re: Horde broken - says error connecting to IMAP

Unread post by biggles »

My Horde died when I upgraded to php 5.3 (Plesk 8.6). Have you checked apache log? Is php working?
aus-city
Forum Regular
Forum Regular
Posts: 685
Joined: Thu Oct 26, 2006 11:56 pm

Re: Horde broken - says error connecting to IMAP

Unread post by aus-city »

It's been working with php 5.3 for months. It's now just suddenly stopped.

Also I ran https://webmail.domain name.com/imp/test.php and it says it's okay. I then test the user, password and server and it's all error free except the SSL test as the certificate is self signed, but passes the next ssl check without certificate test.

IMP Version

IMP: H3 (4.3.9)
Other Horde Applications

dimp: No
DIMP provides an alternate display view using JavaScript.
gollem: No
Gollem provides access to local VFS filesystems to attach files.
ingo: Yes (Version: H3 (1.2.5))
mimp: Yes (Version: H3 (1.1.3))
nag: No
Nag allows tasks to be directly created from e-mail data.
turba: Yes (Version: H3 (2.3.5))
PHP Version

PHP Version: 5.3.6
PHP Major Version: 5.3
PHP Minor Version: 6
PHP Version Classification: release
This version of PHP has not been fully tested with this version of Horde.
PHP Module Capabilities

Internationalized Domain Names Support: No
IMP requires the idn module (installed via PECL) in order to handle Internationalized Domain Names.
IMAP Support: Yes
OpenSSL Support: Yes
Tidy support: No
If the tidy PHP extension is available, IMP can use it to sanitize the output of HTML messages before displaying to the user, and to clean outgoing HTML messages created in the HTML composition mode. See imp/docs/INSTALL for more information.
Miscellaneous PHP Settings

file_uploads enabled: Yes
Required IMP Configuration Files

config/conf.php: Yes
config/mime_drivers.php: Yes
config/prefs.php: Yes
config/servers.php: Yes
PEAR

PEAR Search Path (PHP's include_path): */usr/share/psa-horde:/usr/share/psa-horde/lib:/usr/share/psa-pear:.
PEAR: Yes
Recent PEAR: Yes
Auth_SASL: Yes
HTTP_Request: Yes
PHP Mail Server Support Test

Attempting to automatically determine the correct connection parameters for your server:
Trying protocol imap/notls, Port 143:
SUCCESS - INBOX has 362 messages (3 new 1 recent)
Trying protocol imap/ssl, Port 993:
ERROR - The server returned the following error message:
Certificate failure for xx.com: self signed certificate:
/C=USxxxxx
Trying protocol imap/ssl/novalidate-cert, Port 993:
SUCCESS - INBOX has 362 messages (3 new 0 recent)
Trying protocol imap/tls/novalidate-cert, Port 143:
SUCCESS - INBOX has 362 messages (3 new 0 recent)
The following configurations were successful and may be used in your imp/config/servers.php file:
Configuration 1
'server' => 'xx.com'
'protocol' => 'imap/notls'
'port' => '143'
Configuration 2
'server' => 'xx.com'
'protocol' => 'imap/ssl/novalidate-cert'
'port' => '993'
Configuration 3
'server' => 'xx.com'
'protocol' => 'imap/tls/novalidate-cert'
'port' => '143'
The following IMAP server information was discovered from the remote server:
Could not retrieve IMAP information from the remote server.

I have a feeling it was a plesk update that broke horde. I am running centos 5.6 x64.

It also could easily be asl blocking another php function not previously blocked (running asl-testing) so it's asl 3

I do have popen escapecmdshell and another enabled.

Is there anything else added innthe last several asl builds that is disabling something needed?

Weird the horde test.php works fine.
paulie
Forum User
Forum User
Posts: 76
Joined: Tue Apr 20, 2010 2:49 am

Re: Horde broken - says error connecting to IMAP

Unread post by paulie »

Hi,

I'm a little confused as to whether there are 2 issues here or you are also dcottle aus-city?

dcottle's issue sounds like an email in the inbox that is breaking horde, try creating a new mail account and if that works, then you'll know its not horde, its your email account + horde thats broke (chinese characters in emails tend to break horde for us) and you need clean out any suspicious looking emails.

But aus-city's doesn't sound like the same thing, though I'm only basing that on the last couple of lines from test.php (and also I because I suspect for him its definitely several mail accounts are that broken, not just one).

paul.
aus-city
Forum Regular
Forum Regular
Posts: 685
Joined: Thu Oct 26, 2006 11:56 pm

Re: Horde broken - says error connecting to IMAP

Unread post by aus-city »

Hi Paul,

I have got two accounts one from home and the other from work.

It's not corrupted mail, I tried to log into mail accounts that are empty it's the same.

Something's blocking horde and imap.

What's weird, after attempting a log in, simply edit the URL in the browser to just webmail.domain.com I see the full horde menu just mail tab if you click you get thrown back.

Also all the options work, I can look at and change settings.

I really suspect asl is doing this.

Also mobile horde I see welcome screen, I then click mobile mail and get this URL

Code: Select all

https://webmail.domain.com/imp/login.php?imapuser=xx%40domain.com&horde_logout_token=2nArrvDJshQByPeXjvieO1u0QcI&app=imp&logout_reason=message&logout_msg=Error+connecting+to+IMAP+server%3A+%5B%5D+.
aus-city
Forum Regular
Forum Regular
Posts: 685
Joined: Thu Oct 26, 2006 11:56 pm

Re: Horde broken - says error connecting to IMAP

Unread post by aus-city »

Fixed! I knew it was ASL blocking!

You now have to allow fsockopen in php.ini else it can't connect to the IMAP server.

Can Scott update the WIKI as if you want to run horde with ASL you must allow in asl config;

ALLOW_escapeshellcmd="yes"
ALLOW_fsockopen="yes"
ALLOW_popen="yes"


Its now all working again. This must have slipped in a recent update to the asl-testing builds to disable fsockopen.
faris
Long Time Forum Regular
Long Time Forum Regular
Posts: 2321
Joined: Thu Dec 09, 2004 11:19 am

Re: Horde broken - says error connecting to IMAP

Unread post by faris »

Actually there's a better way. There's no need to enable those functions. If you have a search on the forums for a post by Breun about Horde and SMTP, you'll find that you can change the Horde config so that it uses smtp rather than trying to send the email itself.

It didn't occur to me that this was what the problem was until you solved it. Sorry.
--------------------------------
<advert>
If you want to rent a UK-based VPS that comes with friendly advice and support from a fellow ART fan, please get in touch.
</advert>
aus-city
Forum Regular
Forum Regular
Posts: 685
Joined: Thu Oct 26, 2006 11:56 pm

Re: Horde broken - says error connecting to IMAP

Unread post by aus-city »

Hi Faris,

I changed horde to use SMTP. You can now disable popen and escapeshellcmd, and it will send emails.

However you can't log into horde without allowing fsockopen as you get the same error unable to connect to IMAP on the login screen.
faris
Long Time Forum Regular
Long Time Forum Regular
Posts: 2321
Joined: Thu Dec 09, 2004 11:19 am

Re: Horde broken - says error connecting to IMAP

Unread post by faris »

Hmmmmmm......

I'll look into this.
--------------------------------
<advert>
If you want to rent a UK-based VPS that comes with friendly advice and support from a fellow ART fan, please get in touch.
</advert>
Post Reply