How do I authenticate to SharePoint on Prem with Azure Proxy AD and ADAL?
I am trying to call a Rest Host web service hosted on a SharePoint 2013 server published with Azure Proxy AD (as described here: Kirk Evans Blog , I am using Adal for Auth from an Azure AD tenant:
var authContext = new AuthenticationContext(authority, false);
HttpClientHandler handler = new HttpClientHandler() { CookieContainer = new CookieContainer() };
HttpClient httpClient = new HttpClient(handler);
var result = authContext.AcquireToken("https:/AzureADAppUrl", "ID Apps",new UserCredential("login@domain.com","pass@word"));
Get me an access token, but even if I use this token in the Bearer authorization header or in the AzureAppProxyAccessCookie . I get a 302 redirect response when requesting a WCF web service: Auth is not recognized ... How can I authenticate to an Azure AD Proxy enabled Sharepoint server?
+3
source to share