httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Swapan Gupta" <swapan_gu...@infosys.com>
Subject RE: Problem with getting custom HTTP header in IHS 2.42.x
Date Mon, 13 Oct 2003 07:47:18 GMT


> I am facing a problem there. When I try to get the HTTP headers, on 
> Apache2x I am getting both the Default (such as HTTP_COOKIE, 
> HTTP_CONNECTION) and Custom HTTP headers such as HTTP_FOO. But when I 
> test the same code on IHS, I see that I am able to only get the default 
> HTTP headers and not my Custom HTTP headers.

Where do these custom headers come from?  From the original request or 
from the response?

[Swapan] The custom HTTP headers are generated as part of the response. However I could not
get the headers out of either headers_in or headers_out.

When you refer to these "custom HTTP headers" you're naming them as if 
they are environment variables.  Maybe your module is looking at the 
table of environment variables passed to subprocesses instead of the 
table of request or response headers, 

[Swapan] I am using the apr_table_get for looking the headers. Please let me know if this
is not the correct way of looking for these.


and your Apache setup differs from 
your IHS setup such that with Apache the table of environment variables 
has been populated with these request or response headers?

[Swapan] How can I check for this? Please let me know.

> Any idea why this should happen or do I need to do something special to 
> get custom headers such as HTTP_FOO?

Regardless of Apache or IHS: If these are request headers, your module 
should look in r->headers_in.  If these are response headers, your 
module should refer to r->headers_out and r->err_headers_out.  


Such 
headers may or may not be reflected in the subprocess env table based on 
the configuration directives and the set of modules loaded and the type 
of request and so forth.

[Swapan] Any addtinal info on this. How can I find out that my Apache setup is showing the
HTTP headers as env variables?




Mime
View raw message