3cho
3cho

Reputation: 547

Problem connecting to a Exchange 2007 server in PHP5 with imap_open

When im trying to connect to an Exchange 2007 server over IMAP in PHP5 I get the following error message.

Kerberos error: No credentials cache found (try running kinit) for smtp.domain01.net  

I was wondering if somebody found a way around this issue?

Related info: http://bugs.php.net/bug.php?id=33500

Upvotes: 4

Views: 5405

Answers (3)

Anton Babushkin
Anton Babushkin

Reputation: 406

Just stumbled upon this question and thought I'd answer this one since no one else has. The following page gives a very direct and accurate answer on how to solve the problem: http://forums.kayako.com/threads/fix-kerberos-error-on-email-parser.29626/

Basically whats happening here (according to http://social.technet.microsoft.com/Forums/en-US/exchangesvradmin/thread/43aef3d6-3e91-4e41-a788-ae073393ad37/) is that Microsoft Exchange 2007 broadcasts malformed Kerberos tokens, which causes the PHP IMAP driver to kill the stream. Some other sources claim that this is a PHP bug either way the solution in summary entails you to re-compile the PHP-IMAP extension with Kerberos disabled. This will force PHP IMAP to use Plain text authentication and will fix your problem.

Hope this helps.

Upvotes: 4

JeremyB
JeremyB

Reputation: 185

I know this is an old one, but after getting this problem a couple of times recently after years of no issues, something else was the cause for us. Turns out the Exchange server just needed the IMAP service restarted!

The consensus on a lot of sites was the same as above answers, but I really didn't want to go down the path of recompiling PHP. for me this issue didn't seem to have anything to do with Kerberos or PHP issues, just a simple authentication problem. Possibly the service needed a restart as it was sending malformed tokens...Hopefully someone else will find this helpful.

Upvotes: 0

shadowhand
shadowhand

Reputation: 3201

Exchange does have the IMAP protocol enabled by default. Even when it does, the Exchange implementation of IMAP may or may not really be IMAP. That said, this Technet thread may apply to your situation.

Upvotes: 0

Related Questions