[imp] Folder Navigator

Max Kalika max@the-triumvirate.net
Thu, 14 Dec 2000 23:16:52 -0800


Quoting "Keith A. Chayer" <kchayer@bbcnet.edu>:

> You mentioned something that intrigues me--corrupted variables causing bogus
> connection attempts.  I am getting what appears to be something similar.  Far
> as I can tell, IMP 2.3 doesn't do it (I'm about the only one that uses it,
> though), but when people use 2.2 (2.2.4-cvs, to be exact), I get all sorts of
> weird failed login attempts in the logs.  People still get logged in without 
> any apparent errors on their end, but I get stuff in my logs like:

That is exactly what I get!  I'm glad it is not just me.

> Is that similar to what you experience?  I haven't tried backing out PHP 
> versions 'cause IMP 2.3 is supposed to require 4.04-cvs (in case it's PHP's 
> fault).  I figured I had a setting wrong, or it would clear itself out over 
> time.  I have a hard time blaming IMP, as I haven't updated it to cause this
> to happen--it started out of the blue.  PHP is a possible culprit I hadn't 
> considered.  I've just been ignoring it (though the logs I get in my mail
> annoy me--I've long since realized it wasn't someone trying to break in to my
> server).

>From all I can tell its something that was changed in 4.0.4.  Try setting the 
imap server (in your 2.2.x) to the actual name of the machine (the A record or 
an /etc/hosts entry) and see if the problems go away.  I'm still trying to 
compose tests and whatnot.  strace nor tcpdump reveiled anything useful.  What 
actually fails is the imap_status() call.  All other imap_*() functions seem to 
work ok.  Here is a simple script you can try: (written by Anil -- taken off 
the php docs page I guess? :-)

-=-=-=-=-=-
<?php

$mbox = imap_open("{cname.domain.com}","login",'password', OF_HALFOPEN);
#$mbox = imap_open("{realname.domain.com}","login",'password', OF_HALFOPEN);
#$mbox = imap_open("{localhost}","login",'password', OF_HALFOPEN);

var_dump($mbox);

$status = imap_status($mbox,"{cname.domain.com}INBOX",SA_ALL);
#$status = imap_status($mbox,"{realname.domain.com}INBOX",SA_ALL);
#$status = imap_status($mbox,"{localhost}INBOX",SA_ALL);

var_dump($status);

if($status) {
  print("Messages:   ". $status->messages   )."<br>\n";
  print("Recent:     ". $status->recent     )."<br>\n";
  print("Unseen:     ". $status->unseen     )."<br>\n";
  print("UIDnext:    ". $status->uidnext    )."<br>\n";
  print("UIDvalidity:". $status->uidvalidity)."<br>\n"; 
} else
  print "imap_status failed:"; 
 
imap_close($mbox);
?>
-=-=-=-=-=-

P.S.  Please join and reply to this message on the dev list 
(dev@lists.horde.org) as this is probably too dry for the normal user. :-)

--mk23