-
Notifications
You must be signed in to change notification settings - Fork 661
Added new flag DisableFormsBasedAuthentication #2068
Conversation
- Disables Forms Based Auth when using On Prem SharePoint with additional claims providers
I need this for PnP PowerShell 2016 to disable forms based auth. Will this get merged back to the core PnP or do I need to use this branch going forward. I an new to GitHub and and PnP so any help would be appreciated! Thanks in advanced. |
This would fix a major issue for me. I'm attempting to post a file to an on-prem SharePoint site via an automated powershell script, but it is failing because the site in question uses multiple authentication providers. Is there any information on when this might get merged? |
I gave up and used the workaround #808 |
Sorry @lafe for the delay in getting this looked at. As it is a more drastic code change involving changing PnP Sites Core I would like @erwinvanhunen to make a judgement about this one. Am I right by stating after examining your PR that this will only fix it for a couple of App PnP PowerShell commands, but using other PnP PowerShell commands would still not work in your Forms Based Auth scenario? |
If I remember correctly, I implemented it for those commands that are based on APIs that are based on the REST API and which are available in SharePoint 2019. The REST API commands have their own HttpClient which has to include the flag. CSOM based command did not have the issue. |
This issue should be resolved with PR #2571 which solves this in a much cleaner way. Please try it again with that branch or wait for the April 2020 release which will include this PR and try it again. Will close this PR for now assuming it is fixed. If it turns out not to be fixed yet with the April 2020 release, feel free to reopen this PR. |
Type
Related Issues?
Fixes #808, requires pnp/PnP-Sites-Core#2230
What is in this Pull Request ?
Optionally disables Forms Based Authentication with a new
DisableFormsBasedAuthentication
flag when using On Prem SharePoint with additional claims providers. This flag sets theX-FORMS_BASED_AUTH_ACCEPTED
flag tof
, so that forms based authentication is disabled.This PR requires the Pull Request pnp/PnP-Sites-Core#2230, because for REST based calls, new web requests are constructed in the PnP-Sites-Core project that also need the new flag.