6.0.0-beta1
▾
Tasks
New Task
Search
Photos
Wiki
▾
Tickets
New Ticket
Search
dev.horde.org
Toggle Alerts Log
Help
9/16/25
H
istory
A
ttachments
C
omment
W
atch
Download
Comment on [#4420] URL paths sometimes duplicated when php run as CGI
*
Your Email Address
*
Spam protection
Enter the letters below:
.__ .___.. . ..__. [__) | | |_/ | | | \ | |___| \|__|
Comment
> Jan Schneider asked me to open this ticket. This problem originally > occurred using MIMP, and then I observed it when IMP tried to perform > it's maintenance. The problem is that I'd sometimes get URL's like > this: > > http://www.server.com/horde/imp/redirect.php/horde/imp/redirect.php?nocache=6de35ay90a68&maintenance_done=1&domaintenance=1 > > and > > http://www.server.com/horde/index.php?url=http%3A%2F%2Fwww.server.com%2Fhorde%2Fmimp%2Findex.php%2Fhorde%2Fmimp%2Findex.php%3Fnocache%3D5310v7zf1jsw > > > > Below is my email from the MIMP mail list, describing what I found > and how I fixed it. > > > > I think I found something, may be just an issue with the way my > > server (Dreamhost) works. I found that the Delete url gets > > constructed differently than the rest of the links in the Menu > > section; it's created by Util::addParameter which uses Horde::selfUrl. > > > > In Horde::selfUrl, the first check is if the script is running as > > CGI (I had to recompile php to use Imp on Dreamhost, so it's > > executing as CGI). The problem occurs when the url is constructed > > with the script parameters: > > if ($script_params) { > > if (!empty($_SERVER['PATH_INFO'])) { > > if($_SERVER['PATH_INFO'] == $_SERVER['PHP_SELF']) > > { > > // print "<br><br>Blah!<br><br>\n"; > > } else { > > $url .= $_SERVER['PATH_INFO']; > > } > > } > > if (!empty($_SERVER['QUERY_STRING'])) { > > $url .= '?' . $_SERVER['QUERY_STRING']; > > } > > } > > > > I added the if check for PATH_INFO == PHP_SELF. Basically, the > > /horde/mimp/message.php (PATH_INFO) was getting appended to $url > > which already was set to /horde/mimp/message.php (PHP_SELF). My > > silly fix seems to work for the few cases I tried, and Imp seems to > > still function ok. Again, not fully tested. > > > > I'm guessing this is an issue due to the way my server is working, > > or else I'm fixing something that's not really a bug, but is shown > > due to a problem elsewhere. > >
Attachment
Watch this ticket
N
ew Ticket
M
y Tickets
S
earch
Q
uery Builder
R
eports
Saved Queries
Open Bugs
Bugs waiting for Feedback
Open Bugs in Releases
Open Enhancements
Enhancements waiting for Feedback
Bugs with Patches
Enhancements with Patches
Release Showstoppers
Stalled Tickets
New Tickets
Horde 5 Showstoppers