sharepoint - how to get authentication provider status list from IIS. For share point site? -
i need authentication provider status of web application available in iis?.
ex:
is basic authentication available x site?. through c# or python code
try use code this:
using (spsite site = new spsite("site_url_here")) { var webapp = site.webapplication; var customzonesettings = webapp.iissettings[microsoft.sharepoint.administration.spurlzone.custom]; bool usebasicforcustomzone = customzonesettings.usebasicauthentication; }
here parent spwebapplication specified site , looking iissettings specified zone (because there different settings different zones). spiissettings object contains lot of properties complete task, example, usebasicauthentication.
Comments
Post a Comment