AuthenticationManager Class

Definition

This manager class can be used to obtain a SharePointContext object

public class AuthenticationManager
Inheritance
AuthenticationManager

Constructors

AuthenticationManager()

Methods

GetADFSCertificateMixedAuthenticationContext(String, String, String, String, Int32)

Returns a SharePoint on-premises ClientContext for sites secured via ADFS

GetADFSUserNameMixedAuthenticatedContext(String, String, String, String, String, String, Int32)

Returns a SharePoint on-premises ClientContext for sites secured via ADFS

GetAppOnlyAuthenticatedContext(String, String, String)

Returns an app only ClientContext object

GetAppOnlyAuthenticatedContext(String, String, String, AzureEnvironment)

Returns an app only ClientContext object

GetAppOnlyAuthenticatedContext(String, String, String, String, String, String)

Returns an app only ClientContext object

GetAzureADAccessTokenAuthenticatedContext(String, String)

Returns a SharePoint ClientContext using Azure Active Directory authentication. This requires that you have a Azure AD Web Application registered. The user will not be prompted for authentication, the current user's authentication context will be used by leveraging an explicit OAuth 2.0 Access Token value.

GetAzureADACSEndPoint(AzureEnvironment)

Get's the Azure ASC login end point for the given environment

GetAzureADACSEndPointPrefix(AzureEnvironment)

Get's the Azure ACS login end point prefix for the given environment

GetAzureADAppOnlyAuthenticatedContext(String, String, String, X509Certificate2, AzureEnvironment)

Returns a SharePoint ClientContext using Azure Active Directory App Only Authentication. This requires that you have a certificated created, and updated the key credentials key in the application manifest in the azure AD accordingly.

GetAzureADAppOnlyAuthenticatedContext(String, String, String, String, SecureString, AzureEnvironment)

Returns a SharePoint ClientContext using Azure Active Directory App Only Authentication. This requires that you have a certificated created, and updated the key credentials key in the application manifest in the azure AD accordingly.

GetAzureADAppOnlyAuthenticatedContext(String, String, String, String, String, AzureEnvironment)

Returns a SharePoint ClientContext using Azure Active Directory App Only Authentication. This requires that you have a certificated created, and updated the key credentials key in the application manifest in the azure AD accordingly.

GetAzureADAppOnlyAuthenticatedContext(String, String, String, StoreName, StoreLocation, String, AzureEnvironment)

Returns a SharePoint ClientContext using Azure Active Directory App Only Authentication. This requires that you have a certificated created, and updated the key credentials key in the application manifest in the azure AD accordingly.

GetAzureADLoginEndPoint(AzureEnvironment)

Get's the Azure AD login end point for the given environment

GetAzureADNativeApplicationAuthenticatedContext(String, String, String, TokenCache, AzureEnvironment)

Returns a SharePoint ClientContext using Azure Active Directory authentication. This requires that you have a Azure AD Native Application registered. The user will be prompted for authentication.

GetAzureADNativeApplicationAuthenticatedContext(String, String, Uri, TokenCache, AzureEnvironment)

Returns a SharePoint ClientContext using Azure Active Directory authentication. This requires that you have a Azure AD Native Application registered. The user will be prompted for authentication.

GetAzureADWebApplicationAuthenticatedContext(String, Func<String,String>)

Returns a SharePoint ClientContext using Azure Active Directory authentication. This requires that you have a Azure AD Web Application registered. The user will not be prompted for authentication, the current user's authentication context will be used by leveraging ADAL.

GetHighTrustCertificateAppOnlyAuthenticatedContext(String, String, X509Certificate2, String)

Returns a SharePoint ClientContext using High Trust Certificate App Only Authentication

GetHighTrustCertificateAppOnlyAuthenticatedContext(String, String, String, SecureString, String)

Returns a SharePoint ClientContext using High Trust Certificate App Only Authentication

GetHighTrustCertificateAppOnlyAuthenticatedContext(String, String, String, String, String)

Returns a SharePoint ClientContext using High Trust Certificate App Only Authentication

GetHighTrustCertificateAppOnlyAuthenticatedContext(String, String, StoreName, StoreLocation, String, String)

Returns a SharePoint ClientContext using High Trust Certificate App Only Authentication

GetNetworkCredentialAuthenticatedContext(String, String, SecureString, String)

Returns a SharePoint on-premises / SharePoint Online Dedicated ClientContext object

GetNetworkCredentialAuthenticatedContext(String, String, String, String)

Returns a SharePoint on-premises / SharePoint Online Dedicated ClientContext object

GetSharePointOnlineAuthenticatedContextTenant(String, String, SecureString)

Returns a SharePointOnline ClientContext object

GetSharePointOnlineAuthenticatedContextTenant(String, String, String)

Returns a SharePointOnline ClientContext object

GetWebLoginClientContext(String, Icon)

Returns a SharePoint on-premises / SharePoint Online ClientContext object. Requires claims based authentication with FedAuth cookie.

RefreshADFSCertificateMixedAuthenticationContext(String, String, String, String, Int32)

Refreshes the SharePoint FedAuth cookie

RefreshADFSUserNameMixedAuthenticatedContext(String, String, String, String, String, String, Int32)

Refreshes the SharePoint FedAuth cookie

Extension Methods

GetPublicInstanceProperty(Object, String)

Retrieves a public, instance property

GetPublicInstancePropertyValue(Object, String)

Retrieves the value of a public, instance property

SetPublicInstancePropertyValue(Object, String, Object)

Sets the value of a public, instance property

ValidateNotNullOrEmpty<T>(T, String)

Validates an object for not being null or not being the default value

Applies to