<?xml version="1.0" encoding="UTF-8"?> 
<?xml-stylesheet href="https://dev.horde.org/themes/horde//default/feed-rss.xsl" type="text/xsl"?> 
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"> 
 <channel> 
  <title>Redirection loop when using $conf[server][change_server]</title> 
  <pubDate>Fri, 10 Apr 2026 09:20:57 +0000</pubDate> 
  <link>https://bugs.horde.org/ticket/6978</link> 
  <atom:link rel="self" type="application/rss+xml" title="Redirection loop when using $conf[server][change_server]" href="https://bugs.horde.org/ticket/6978/rss" /> 
  <description>Redirection loop when using $conf[server][change_server]</description> 
 
   
   
  <item> 
   <title>IMP is getting stuck in a redirection loop when loading the </title> 
   <description>IMP is getting stuck in a redirection loop when loading the login page when I use $conf[server][change_server]. Using $conf[server][server_list] = &#039;none&#039; without setting $conf[server][change_server] works fine.



Apaches access log contains this:



217.78.41.153 - - [26/Jun/2008:09:18:57 +0200] &quot;GET /imp/redirect.php?actionID=login&amp;autologin=1&amp;server_key=imap HTTP/1.1&quot; 302 38 &quot;-&quot; &quot;Mozilla/5.0 (Windows; U; Windows NT 6.0; sv-SE; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14&quot;

217.78.41.153 - - [26/Jun/2008:09:18:57 +0200] &quot;GET /imp/redirect.php?actionID=login&amp;autologin=1&amp;server_key=imap HTTP/1.1&quot; 302 38 &quot;-&quot; &quot;Mozilla/5.0 (Windows; U; Windows NT 6.0; sv-SE; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14&quot;

... until browser decides we&#039;re stuck in a loop



Hordes log file doesn&#039;t tell me anything.



Here&#039;s Hordes config directives related to sessions, cookies and auth: (if more is needed, let me know)



$conf[&#039;use_ssl&#039;] = 0;

$conf[&#039;session&#039;][&#039;name&#039;] = &#039;Horde&#039;;

$conf[&#039;session&#039;][&#039;use_only_cookies&#039;] = true; $conf[&#039;session&#039;][&#039;cache_limiter&#039;] = &#039;nocache&#039;; $conf[&#039;session&#039;][&#039;timeout&#039;] = 0; $conf[&#039;cookie&#039;][&#039;domain&#039;] = &#039;horde.binero.net&#039;; $conf[&#039;cookie&#039;][&#039;path&#039;] = &#039;/&#039;; $conf[&#039;auth&#039;][&#039;admins&#039;] = array(&#039;fredrik.poller@binero.se&#039;);

$conf[&#039;auth&#039;][&#039;checkip&#039;] = true;

$conf[&#039;auth&#039;][&#039;checkbrowser&#039;] = true;

$conf[&#039;auth&#039;][&#039;alternate_login&#039;] = false; $conf[&#039;auth&#039;][&#039;redirect_on_logout&#039;] = false; $conf[&#039;auth&#039;][&#039;params&#039;][&#039;app&#039;] = &#039;imp&#039;; $conf[&#039;auth&#039;][&#039;driver&#039;] = &#039;application&#039;;



Here&#039;s IMPs config directives:



$conf[&#039;server&#039;][&#039;change_server&#039;] = true; $conf[&#039;server&#039;][&#039;change_port&#039;] = false; $conf[&#039;server&#039;][&#039;change_protocol&#039;] = false; $conf[&#039;server&#039;][&#039;change_smtphost&#039;] = false; $conf[&#039;server&#039;][&#039;change_smtpport&#039;] = false; $conf[&#039;server&#039;][&#039;server_list&#039;] = &#039;none&#039;; $conf[&#039;server&#039;][&#039;fixed_folders&#039;] = array(); $conf[&#039;server&#039;][&#039;sort_limit&#039;] = 0; $conf[&#039;server&#039;][&#039;cache_folders&#039;] = true; $conf[&#039;server&#039;][&#039;token_lifetime&#039;] = 1800; $conf[&#039;server&#039;][&#039;cachejs&#039;] = &#039;none&#039;; $conf[&#039;server&#039;][&#039;cachecss&#039;] = &#039;none&#039;;



Servers.php contains this:



$servers[&#039;binero&#039;] = array(

    &#039;name&#039; =&gt; &#039;Binero&#039;,

    &#039;server&#039; =&gt; &#039;mail.binero.se&#039;,

    &#039;hordeauth&#039; =&gt; false,

    &#039;protocol&#039; =&gt; &#039;imap/notls&#039;,

    &#039;port&#039; =&gt; 143,

    &#039;smtphost&#039; =&gt; &#039;localhost&#039;,

    &#039;smtpport&#039; =&gt; 25,

    &#039;realm&#039; =&gt; &#039;&#039;,

    &#039;preferred&#039; =&gt; &#039;&#039;,

);



Versions Im running:



FreeBSD 7.0

Horde 3.2.1

IMP H3 4.2

Apache 1.3.39

PHP 5.2.5</description> 
   <pubDate>Thu, 26 Jun 2008 08:36:26 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/6978#t46825</link> 
  </item> 
   
  <item> 
   <title>It seems that the if on lines 171 - 184 in imp/login.php cau</title> 
   <description>It seems that the if on lines 171 - 184 in imp/login.php causes the problem.



If !empty($GLOBALS[&#039;conf&#039;][&#039;server&#039;][&#039;change_server&#039;] (which is true in my case) and $credentials[&#039;imp&#039;] is set then we&#039;re redirected.



Commenting this out solves the problem for me (but it probably breakes something else.</description> 
   <pubDate>Thu, 26 Jun 2008 08:58:51 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/6978#t46827</link> 
  </item> 
   
  <item> 
   <title>I can no longer reproduce this with a current CVS checkout. </title> 
   <description>I can no longer reproduce this with a current CVS checkout. This seems to have been fixed along the way.</description> 
   <pubDate>Wed, 30 Jul 2008 22:52:10 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/6978#t47916</link> 
  </item> 
   
  <item> 
   <title>The issue exists only if there is no $credentials[&#039;imp&#039;] val</title> 
   <description>The issue exists only if there is no $credentials[&#039;imp&#039;] value set in the user&#039;s prefs....like if the user never set the pref. (The default value for this in prefs.php is the empty string. So, the check for $credentials[&#039;imp&#039;] will always fail.</description> 
   <pubDate>Mon, 08 Sep 2008 22:33:59 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/6978#t48791</link> 
  </item> 
   
  <item> 
   <title>Changes have been made in CVS for this ticket:

http://cvs.h</title> 
   <description>Changes have been made in CVS for this ticket:

http://cvs.horde.org/diff.php/imp/login.php?r1=2.291&amp;r2=2.292&amp;ty=u</description> 
   <pubDate>Mon, 08 Sep 2008 22:49:36 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/6978#t48792</link> 
  </item> 
   
  <item> 
   <title>Changes have been made in CVS for this ticket:

http://cvs.h</title> 
   <description>Changes have been made in CVS for this ticket:

http://cvs.horde.org/diff.php/imp/login.php?r1=2.222.2.25&amp;r2=2.222.2.26&amp;ty=u</description> 
   <pubDate>Mon, 08 Sep 2008 22:52:23 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/6978#t48793</link> 
  </item> 
   
   
 
 </channel> 
</rss> 
