L
Lee Greco
We have a web server farm with several servers hosting web services and I'd
like to add a custom HTTP header to every web service response so our client
support can locate the server that processed the request. We use WSE
encryption on our SOAP messages so we really want a plain old HTTP header and
not a SOAP header.
I know we can go into the IIS manager and add a custom header there, but we
don't want to add a different literal value to every machine and would much
prefer the machine identifier is retrieved by a function. I also know we can
edt every existing web method in every web service and add the header to the
context object, but that won't handle the case of failed SOAP authentication,
and we don't want to change the existing web method calls.
Is there a way using Global.asax, WSE 3.0, or some other mechanism where we
can add a plain old HTTP header to every response (including those that don't
make it through WSE authentication? The header would be something like
"X-Custom-ServicedBy" with a value of the local machine identifier. Also the
local machine identifier can not be a literal value but must be determined by
a function call.
Thanks in advance
like to add a custom HTTP header to every web service response so our client
support can locate the server that processed the request. We use WSE
encryption on our SOAP messages so we really want a plain old HTTP header and
not a SOAP header.
I know we can go into the IIS manager and add a custom header there, but we
don't want to add a different literal value to every machine and would much
prefer the machine identifier is retrieved by a function. I also know we can
edt every existing web method in every web service and add the header to the
context object, but that won't handle the case of failed SOAP authentication,
and we don't want to change the existing web method calls.
Is there a way using Global.asax, WSE 3.0, or some other mechanism where we
can add a plain old HTTP header to every response (including those that don't
make it through WSE authentication? The header would be something like
"X-Custom-ServicedBy" with a value of the local machine identifier. Also the
local machine identifier can not be a literal value but must be determined by
a function call.
Thanks in advance