A
APA
In the constructor of my web service I have no access to the SoapContext (i.e. RequestSoapContext.Current). Not only that but I have implemented a
customer UsernameTokenmanger.AuthenticateToken method and it doesn't call that either. I have the following setup in my web.config
<configSections>
<section name="microsoft.web.services3" type="Microsoft.Web.Services3.Configuration.WebServicesConfiguration, Microsoft.Web.Services3,
Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</configSections>
and
<microsoft.web.services3>
<security>
<securityTokenManager type="AppCommonProj.CustomUsernameTokenManager, AppCommonProj"
xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" qname="wsse:UsernameToken"/>
</security>
<diagnostics/>
</microsoft.web.services3>
I'm using a testing tool (that works fine with other web services that I've developed in .NET 1.1 but this web service is developed in .NET2.0 using
WSE3. I'm not really doing anything odd just checking the SoapContext to see if the request was made using SOAP and not using POST or GET. Here's
what I'm doing in my web service's constructor.
SoapContext sContext = RequestSoapContext.Current;
if (sContext == null)
{
throw new Exception("Invalid web service request.");
}
sContext is always null. Have no idea why and I don't understand why the UsernameTokenmanger.AuthenticateToken method is not being called either.
TIA.
customer UsernameTokenmanger.AuthenticateToken method and it doesn't call that either. I have the following setup in my web.config
<configSections>
<section name="microsoft.web.services3" type="Microsoft.Web.Services3.Configuration.WebServicesConfiguration, Microsoft.Web.Services3,
Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</configSections>
and
<microsoft.web.services3>
<security>
<securityTokenManager type="AppCommonProj.CustomUsernameTokenManager, AppCommonProj"
xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" qname="wsse:UsernameToken"/>
</security>
<diagnostics/>
</microsoft.web.services3>
I'm using a testing tool (that works fine with other web services that I've developed in .NET 1.1 but this web service is developed in .NET2.0 using
WSE3. I'm not really doing anything odd just checking the SoapContext to see if the request was made using SOAP and not using POST or GET. Here's
what I'm doing in my web service's constructor.
SoapContext sContext = RequestSoapContext.Current;
if (sContext == null)
{
throw new Exception("Invalid web service request.");
}
sContext is always null. Have no idea why and I don't understand why the UsernameTokenmanger.AuthenticateToken method is not being called either.
TIA.