Hi all,
I'm trying to use a webservice which is provided to me by a third party.
There are a number of webmethods that I can call but for each method I have
to supply a SOAP header which contains an identification-token. I've managed
to generate a proxy class using the wsdl.exe tool but the wsdl doesn't have
the SOAP header definition in it (quite frustrating).
I'm trying to enhance the generated class so that I can issue the header to
the webservice but I'm not having much luck.It should look like this
according to the documentation:
<soap:Header>
<AuthToken>ABCDEFGHIJKLMNOP</AuthToken>
</soap:Header>
Does anybody know how I can achieve this in my VB app (C# code samples are
also welcome)?
TIA,
Friso Wiskerke
Niels Flensted-Jensen - 25 Jan 2006 10:11 GMT
Frisco,
It sounds like you're not using WSE? If you use WSE at setup the right
"policy assertions" you should be able to get the needed identity token in
there.
Now, from your sample it seems like you need a custom header, i.e. one not
defined by any of the WS-* specs. Therefore you will probably need to write
your own policy assertion to stick in the header on the outgoing end of the
proxy. How to do this is documented in WSE documentation and a recent
article in MSDN Magazine explains the framework:
http://msdn.microsoft.com/msdnmag/issues/06/02/WSE30/default.aspx.
Niels
> Hi all,
>
[quoted text clipped - 16 lines]
> TIA,
> Friso Wiskerke