I've created a custom STS and have setup trust with SharePoint via New-SPTrustedIdentityTokenIssuer. I can use Central Admin to configure a Web Application to use both NTLM and the STS, however I can't do that via PowerShell.

Is there a PowerShell command to do that? Set-SPWebApplication has the AuthenticationMethod and AuthenticationProvider parameters, but if I specify both, only AuthenticationProvider is applied, i.e. Windows Authentication is unticked.

Any help greatly appreciated!


1 Answer 1


In case this helps anyone else (or me in the future) you can do this with:

$winAp = new-SPAuthenticationProvider -UseWindowsIntegratedAuthentication
$stsAp = Get-SPTrustedIdentityTokenIssuer "YourSTS"
Set-SPWebApplication -Identity $webApp -AuthenticationProvider $stsAp, $winAp -Zone "Default"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.