Access SharePoint/ProjectServer with AzureAD Authentication from .Net/C# application

Joerg Schrocke 1 Reputation point
2021-04-07T07:13:43.403+00:00

Hi,

We have setup our SharePoint 2019/ProjectServer on-premise environment to authenticate via AzureAD by using the Trusted Provider solution.

Previously we used NTLM to connect to the sites, but this is fully disabled now. Our question is now, how to connect to SharePoint/Project Server by providing the credentials e.g. in a .Net or C# application?

Any ideas or recommendations?

Thanks for your help.

Joerg

Microsoft 365 and Office | SharePoint Server | Development
{count} votes

1 answer

Sort by: Most helpful
  1. MichaelHan-MSFT 18,136 Reputation points
    2021-04-08T09:38:22.987+00:00

    Hi @Joerg Schrocke ,

    Not sure if this works for you. But you could try to use the AuthenticationManager Class to get SharePointContext in SharePointPnPCore.

    Reference: https://learn.microsoft.com/en-us/dotnet/api/officedevpnp.core.authenticationmanager?view=sharepoint-pnpcoreol-3.2.1810


    If an Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.