Is it possible to set a web service to use Basic authentication during install or dynamically when the web service is started? I am currently using Visual Studio to create and MSI to install the web service.
A:
Setting a Web Service to accept Basic authentication depends not only on your projects configuration but also on your hosting environment.
IIS: Basic Auth against primary AD? Let IIS solve this:
- Turn basic auth on in IIS settings.
Basic Auth against custom LDAP? Let ASP.Net solve this.
- Turn auth off in IIS settings,
- Configure an LDAP HttpModule in your web.config
- [optional] Add Principle&Identity providers (code) to your WCF runtime (config).
So, looking at this; I would advise for your MSI to apply the appropriate settings to IIS and 'adjust/modify' the 'web.config' file during/after installation.
Hope this helps,
Marvin Smit
2010-02-11 19:52:20