I need to detect authentication type being used by SharePoint 2013 and 2016. I need to distinguish between ASP.NET Forms (cookies) authentication and Windows (Basi/Digest/NTLM/Ketberos) authentication.
I see that it is possible to detect authentication mode on server side: Programmatically determine authentication mode. But our SharePoint add-in is a pure JavaScript and does not have any server-side code.
Is it possible to detect SharePoint authentication in JavaScript?
I think that you should investigate the HTTP headers of your web page.
They can be read through javascript (see this link) and contain information regarding the authentication type in use.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With