You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by William Ross <wi...@spanner.org> on 2005/11/15 03:13:13 UTC

[users@httpd] why would mod_alias eat the query string (1.3.x)

hello list,

I'm very sorry to jump straight in here with a question, but here goes:

I've got a fairly normaly thin-and-thick setup with a mod_perl server  
in the background. The thin server on 80 is a reverse proxy for the  
mod_perl server on 8081, in the usual way. The only quirk is that for  
some directories I'm forcing secure access and bypassing the proxy:  
those I redirect to the same mod_perl server, but on port 443.

It all works very nicely except for one thing:

* url with query string proxied to the non-secure port on the  
mod_perl server works fine
* url with qs redirected to the secure port on the same server  
arrives without the query string

There's quite a big stack of handlers on the mod_perl server,  
including a TransHandler, so at first I just assumed I was breaking  
the input, but I'm really not: I've been able to make sure that the  
request really does come in without the query string.

As it happens this application will accept similar input in the  
path_info so I can get by for the few cases where the redirect kicks  
in. But I thought mod_alias just ignored the query string? please  
could someone suggest why they're getting eaten? It's driving me nuts.

thank you

will



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] why would mod_alias eat the query string (1.3.x)

Posted by Joshua Slive <js...@gmail.com>.
On 11/14/05, William Ross <wi...@spanner.org> wrote:

>         <Location "/">
>                 Redirect permanent /admin https://www.foo.org/admin
>                 # and a few others the same
>         </Location>

Take the Redirects out of the <Location> section.  They don't need to
be there, and I'd give at least even money that this is what is
causing you to lose the query string.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] why would mod_alias eat the query string (1.3.x)

Posted by William Ross <wi...@spanner.org>.
On 15 Nov 2005, at 02:41, Joshua Slive wrote:

> On 11/14/05, William Ross <wi...@spanner.org> wrote:
>> hello list,
>>
>> I'm very sorry to jump straight in here with a question, but here  
>> goes:
>>
>> I've got a fairly normaly thin-and-thick setup with a mod_perl server
>> in the background. The thin server on 80 is a reverse proxy for the
>> mod_perl server on 8081, in the usual way. The only quirk is that for
>> some directories I'm forcing secure access and bypassing the proxy:
>> those I redirect to the same mod_perl server, but on port 443.
>>
>> It all works very nicely except for one thing:
>>
>> * url with query string proxied to the non-secure port on the
>> mod_perl server works fine
>> * url with qs redirected to the secure port on the same server
>> arrives without the query string
>>
>> There's quite a big stack of handlers on the mod_perl server,
>> including a TransHandler, so at first I just assumed I was breaking
>> the input, but I'm really not: I've been able to make sure that the
>> request really does come in without the query string.
>>
>> As it happens this application will accept similar input in the
>> path_info so I can get by for the few cases where the redirect kicks
>> in. But I thought mod_alias just ignored the query string? please
>> could someone suggest why they're getting eaten? It's driving me  
>> nuts.
>
> There seems to be a rash of people today posting semi-complicated
> URL-mapping problems who describe the problem but neglect to show the
> configuration they are using or any concrete examples of what is
> happening.  This makes solving the problem almost impossible.

I'm sorry. Here's my semi-complicated host configuration:

<VirtualHost *:80>
	DocumentRoot /home/foo/public_html
	ServerAdmin sysadmin@spanner.org

	ServerName www.foo.org
	ServerAlias foo.org

	DirectoryIndex index.shtml index.html index.htm

	ProxyRequests Off
	ProxyPass / http://www.foo.org:8081/
	ProxyPassReverse / http://www.foo.org:8081/
	
	CacheRoot /home/foo/html_cache
	CacheSize 5000
	CacheGcInterval 1
	CacheMaxExpire 2
	CacheLastModifiedFactor 0.1
	ProxyReceiveBufferSize 49152
	
	<Location "/">
		Redirect permanent /admin https://www.foo.org/admin
		# and a few others the same
	</Location>

	CustomLog /home/foo/logs/access_log combined
	ErrorLog /home/foo/logs/error_log
</VirtualHost>

This is 1.3.27 (oops), compiled with suexec, mod_alias, mod_rewrite  
and mod_include, and iirc nothing else.

Thanks,

will














>
> Joshua.
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server  
> Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
>    "   from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] why would mod_alias eat the query string (1.3.x)

Posted by Joshua Slive <js...@gmail.com>.
On 11/14/05, William Ross <wi...@spanner.org> wrote:
> hello list,
>
> I'm very sorry to jump straight in here with a question, but here goes:
>
> I've got a fairly normaly thin-and-thick setup with a mod_perl server
> in the background. The thin server on 80 is a reverse proxy for the
> mod_perl server on 8081, in the usual way. The only quirk is that for
> some directories I'm forcing secure access and bypassing the proxy:
> those I redirect to the same mod_perl server, but on port 443.
>
> It all works very nicely except for one thing:
>
> * url with query string proxied to the non-secure port on the
> mod_perl server works fine
> * url with qs redirected to the secure port on the same server
> arrives without the query string
>
> There's quite a big stack of handlers on the mod_perl server,
> including a TransHandler, so at first I just assumed I was breaking
> the input, but I'm really not: I've been able to make sure that the
> request really does come in without the query string.
>
> As it happens this application will accept similar input in the
> path_info so I can get by for the few cases where the redirect kicks
> in. But I thought mod_alias just ignored the query string? please
> could someone suggest why they're getting eaten? It's driving me nuts.

There seems to be a rash of people today posting semi-complicated
URL-mapping problems who describe the problem but neglect to show the
configuration they are using or any concrete examples of what is
happening.  This makes solving the problem almost impossible.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org