Table of contents
TOC
Collapse the table of content
Expand the table of content

AuthenticationManager.GetHighTrustCertificateAppOnlyAuthenticatedContext Method

SharePoint Dev Documents|Last Updated: 5/19/2017
|
1 Contributor

Returns a SharePoint ClientContext using High Trust Certificate App Only Authentication

Namespace:OfficeDevPnP.Core
Assembly: OfficeDevPnP.Core.dll

Syntax

public ClientContext GetHighTrustCertificateAppOnlyAuthenticatedContext(String siteUrl, String clientId, X509Certificate2 certificate, String certificateIssuerId)

Parameters

siteUrl

  Type: System.String
  Site for which the ClientContext object will be instantiated

clientId

  Type: System.String
  The SharePoint Client ID

certificate

  Type: System.Security.Cryptography.X509Certificates.X509Certificate2
  Private key certificate (.pfx) used to authenticate

certificateIssuerId

  Type: System.String
  The IssuerID under which the CER counterpart of the PFX has been registered in SharePoint as a Trusted Security Token issuer

Return Value

Type: ClientContext
Authenticated SharePoint ClientContext

See also

© 2018 Microsoft