• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 368
  • Last Modified:

asp.net webservice proxy classs generation using wsdl for a webservice residing in an application protected by forms authentication

I have an asp.net webservice that resides on my webserver within a virtual directory that has a web.config file forcing forms authentication.  If I move my webservice to a nonprotected directory, then I can generate my proxy class with wsdl without a worry.  But when trying to execute wsdl when the webservice resides in the protected directory/application, then I get the following error :

Error: There was an error processing 'http://www.xxxx.com/asp.net/WebService.asmx?wsdl'.
  - The HTML document does not contain Web service discovery information.

I have tried specifying the username and passsword on the command line, but I get the same result.

What should I be doing here, changing my authentication method, or changing the way I generate and access my proxy class ?

Thanks in Advance.

1 Solution
When creating a webservice, a single virtual directory is created. This should also be so on the production server. Personally I think that a webservice should NOT ever reside at the same location of a website. Problems like yours could arise if you do so.

If you create a seperate virtual directory you can also set other settings. For exam,ple you could make use of windows authentication or even create a new application pool (so it has it's own memory management and cannot interfere with the actual website).

MrMainAuthor Commented:

I have taken your suggestion on-board and have moved onto authenticating via the SoapHeader in a separate virtual directory.


Featured Post

2018 Annual Membership Survey

Here at Experts Exchange, we strive to give members the best experience. Help us improve the site by taking this survey today! (Bonus: Be entered to win a great tech prize for participating!)

Tackle projects and never again get stuck behind a technical roadblock.
Join Now