Skip to content

Data Classification Vendor Import

Classification ingestion enables customers to bring classification results from third-party solutions into Data Access Security where they can be combined with SailPoint’s identity context and native data access security capabilities.

By integrating existing classification data with identity and access information, customers can move beyond simply identifying sensitive data to governing who has access to it and understanding risk without having to replace their existing classification investment.

Classification Label Imports

The Classification Label Imports page provides users with the ability to view various import integrations from DSPM vendors and imported files (CSV) while also allowing the management of these integrations.

To view the import options, go to Compliance > Data Classification > Classification Label Imports.

On the Classification Label Imports page, each import has the option to edit, run it now, or delete the import.

Search for a specific import using the search bar.

Creating a New Import

Tip

When configuring an application to have data classification, a classification method needs to be selected. You can either choose to classify through Data Access Security or by a third-party classification integration.

To create a new classification import:

  1. Select Create Import.
  2. Select if this import will be created from another vendor or from a CSV file.

CSV Upload

Uploading classification from a CSV file allows you to map classification labels into Data Access Security.

Data Access Security provides a downloadable CSV template with required columns of information.

  1. Upload the correct .csv file by either dragging it to the upload box or by selecting choose a file .

  2. Select Upload.

Integrating with a Vendor

This method of importing allows classification labels to be linked from other vendors.

  1. Select Create Integration.

  2. On the General Details page, select the Vendor from the dropdown and provide a Name and Description for the connection. Providing a description is optional.

  3. Select Next.

  4. The connection details for each vendor will differ. Select the correct vendor to know what connection details are needed.

    BigID

    Provide the following:

    • Tenant URL - For example, sailpoint-poc.bigid.cloud. Note: The name cannot just be the tenant name because "bigid.cloud" is not consistent for all tenants.
    • Session Token - Value generated for a BigID user within their platform. For more information on this value and how to create it, refer to BigID documentation.
    Purview

    This application needs to be configured before use. Refer to Configuring Purview for more information.

    SharePoint Online and OneDrive applications must already be crawled along with the Classification Method set to Third Party Classification Integration. If an Exchange Online card still appears, leave it unmapped.

    Provide the following:

    • Tenant Domain Name - The Microsoft 365 tenant's initial domain. For example, contoso.onmicrosoft.com.
    • Application ID - Enter the Application ID for the Microsoft 365 application used by the Data Access Security
    • Certificate File - Certificate assigned to the Azure application used by Data Access Security. Either navigate to the certificate by selecting Choose a File, or drag the certificate onto the Certificate File field. Supported formats are pfx and p12.
    • Certificate Password - Enter the password for the certificate.
    Cyera

    Provide the following:

  5. To test the connection, select Test Connection. Once the connection was successful, select Next.

  6. On the Vendor Source Mapping page, you can map vendors to one or more applications that are within Data Access Security.
  7. Locate the appropriate vendor and select the desired applications from that dropdown within the vendor card.

    Note

    One vendor source can map to one or multiple Data Access Security applications. However, only one Data Access Security application can be mapped to a vendor.

  8. Once everything is mapped, select Next.

  9. Setting a schedule is enabled by default. If setting a scheduled integration, select a scheduling frequency from the dropdown list.

    Schedule Frequency Options
    • Run After - Create dependency of tasks. The task starts running only upon successful completion of the first task.
    • Daily - Set the start date and time.
    • Weekly - Set the day(s) of the week on which to run.
    • Monthly - Set the day of the month on which to run a task.
    • Quarterly - Set a monthly schedule with an interval of 3 months.
    • Semi-Annually - Set a monthly schedule with an interval of 6 months.
    • Yearly - Set a monthly schedule with an interval of 12 months.
  10. Set the desired days of the week for the recurrence.

  11. Fill the time and date fields with scheduling times. These fields differ depending upon the scheduling frequency selected.
  12. Select Next.
  13. On the Summary page, review all of the selected vendor integration details.
  14. Select Save.

Configuring Purview

A new Azure application must be created and configured to support the Data Access Security Microsoft Purview vendor. This application is for Classification Label Imports.

Caution

It is not a Data Access Security SharePoint Online, One Drive, or Exchange Online application.

This configuration can be performed either by running the automated PowerShell script supplied with the SailPoint distribution pack, or by creating and configuring the application through the Azure portal. Assigning Content Explorer List Viewer to the application cannot be done in the Azure portal or the Microsoft Purview portal; the script and the last manual section use Security & Compliance PowerShell for that step.

After the application is created, enter Tenant Domain Name, Application ID, the certificate file, and the certificate password in Data Access Security.

Licensing Requirements

The Purview import reads Content Explorer. This means Microsoft 365 E5, Office 365 E5, or an E5 compliance or information protection add-on is needed.

To confirm, go to the Purview portal and then Data lifecycle management. Select Explorers, then Data Explorer to browse classification results.

What this Import Includes

This import reads Sensitive Information Type matches from Data Explorer, such as credit card numbers. Data Access Security creates one category per type name.

Sensitivity labels applied to a file, including labels from an older information protection license, are separate. This import does not read them.

Retention labels and trainable classifiers are outside of this release.

Creating and Configuring the Application Automatically

The PowerShell script below performs all Azure application creation and configuration steps required for the Microsoft Purview vendor.

To run this script, use PowerShell 7 (pwsh) on Windows, macOS, or Linux. Install the Microsoft Graph PowerShell module and the Exchange Online Management module. Run the script from pwsh, not from zsh or bash (shell backticks are not PowerShell line continuation).

On macOS and Linux, OpenSSL must be on PATH (it is present by default on macOS). On Windows, the script uses New-SelfSignedCertificate (Git for Windows OpenSSL often lacks a usable openssl.cnf). The script types the PFX password twice and verifies that .NET can load the PFX before continuing.

The script prompts for the Entra tenant ID GUID (or accept -TenantId) so Microsoft Graph signs into the correct directory. After Graph, Security & Compliance PowerShell uses device-code login on Windows, macOS, and Linux. Interactive Connect-IPPSSession in the same process as Microsoft.Graph breaks MSAL/WAM on Windows.

Open the CreatePurviewVendorApp.ps1 file in a text editor to review the default parameters. The parameters can be edited in the file or passed as parameters when running the script.

CreatePurviewVendorApp.ps1
 # Configures Azure Application for use as DAS Microsoft Purview Vendor:
 #   Creates Azure app with the following permissions:
 #   Office 365 Exchange Online:
 #      Exchange.ManageAsApp
 #   Creates and uploads certificate as app client credential.
 #   Assigns application to Compliance Administrator directory role.
 #   Prompts for application admin consent.
 #   Registers the vendor app in Security & Compliance PowerShell and adds it to
 #      the Content Explorer List Viewer role group (required for Export-ContentExplorerData).
 #
 # This is for the Purview *vendor* (Classification Label Imports), not a DAS
 # SharePoint Online, OneDrive, or Exchange Online *application*.
 #
 # Runs on PowerShell 7 (pwsh) on Windows, macOS, and Linux.
 # Run from pwsh (not zsh). zsh backticks are not PowerShell line continuation.
 #
 # NOTE: AzureAD PowerShell is deprecated. Use Microsoft.Graph instead.
 param(
   [string]$AppName = 'DAS Purview Vendor App',
   [string]$DirectoryRole = 'Compliance Administrator',
   # DnsName will be included in Cert subject name
   [string]$CertDnsName = 'organization.com',
   [int]$CertYearsValid = 10,
   [int]$SleepBeforeConsentSeconds = 30,
   [Security.SecureString]$CertPassword,
   [Parameter(Mandatory=$True)]
   [string]$AdminUpn,
   [string]$TenantId
 )

 # Stop the script on error
 $ErrorActionPreference = "Stop"

 function Test-IsWindowsOs {
   if ($PSVersionTable.PSVersion.Major -ge 6) {
       return [bool]$IsWindows
   }
   return $true
 }

 function Get-PlainPassword {
   param([Security.SecureString]$SecureString)
   return [System.Net.NetworkCredential]::new('', $SecureString).Password
 }

 function Get-ConfirmedCertPassword {
   param([Security.SecureString]$CertPassword)
   if ($CertPassword) {
       return $CertPassword
   }

   $first = Read-Host 'PFX password (needed later for DAS / tests)' -AsSecureString
   $second = Read-Host 'Re-enter PFX password' -AsSecureString
   if ((Get-PlainPassword $first) -cne (Get-PlainPassword $second)) {
       throw 'PFX passwords did not match. Re-run the script.'
   }
   if ([string]::IsNullOrEmpty((Get-PlainPassword $first))) {
       throw 'PFX password cannot be empty.'
   }
   return $first
 }

 function Get-ConfirmedTenantId {
   param([string]$TenantId)

   if ([string]::IsNullOrWhiteSpace($TenantId)) {
       do {
         $TenantId = Read-Host 'Entra tenant ID (GUID from Azure portal > Entra ID > Overview)'
         $TenantId = $TenantId.Trim()
       } while ([string]::IsNullOrWhiteSpace($TenantId))
   }
   else {
       $TenantId = $TenantId.Trim()
   }

   if ($TenantId -notmatch '^[0-9a-fA-F]{8}-([0-9a-fA-F]{4}-){3}[0-9a-fA-F]{12}$') {
       throw "TenantId must be a GUID. Value provided: $TenantId"
   }

   return $TenantId
 }

 function Get-SafeFileName {
   param([string]$Name)
   $safe = $Name -replace '[^\w\.-]+', '-'
   $safe = $safe.Trim('-')
   if ([string]::IsNullOrEmpty($safe)) {
       return 'DAS-Purview-Vendor-App'
   }
   return $safe
 }

 function Open-DefaultBrowser {
   param([string]$Url)
   if (Test-IsWindowsOs) {
       Start-Process $Url
       return
   }
   if ($PSVersionTable.PSVersion.Major -ge 6 -and $IsMacOS) {
       & /usr/bin/open $Url
       return
   }
   $xdg = Get-Command xdg-open -ErrorAction SilentlyContinue
   if ($xdg) {
       & $xdg.Source $Url
       return
   }
   Write-Host "Open this URL in a browser: $Url"
 }

 function Get-ContentExplorerListViewerRoleGroup {
   $roleGroup = @(Get-RoleGroup | Where-Object {
       ($_.Name -replace '\s', '') -ieq 'ContentExplorerListViewer'
   })
   if ($roleGroup.Count -eq 1) {
       return $roleGroup[0]
   }
   $contentExplorerNames = @(Get-RoleGroup | Where-Object { $_.Name -like '*Content*Explorer*' } |
       Select-Object -ExpandProperty Name)
   if ($roleGroup.Count -gt 1) {
       throw "Found more than one Content Explorer List Viewer role group: $($roleGroup.Name -join ', ')"
   }
   throw "Could not find the Content Explorer List Viewer role group. Content Explorer groups in this tenant: $($contentExplorerNames -join ', ')"
 }

 function Get-RoleGroupKey {
   param($RoleGroup)
   if ($RoleGroup.Guid) {
       return $RoleGroup.Guid.ToString()
   }
   return $RoleGroup.Name
 }

 function Get-OauthErrorCode {
   param($ErrorRecord)
   try {
       return ($ErrorRecord.ErrorDetails.Message | ConvertFrom-Json).error
   }
   catch {
       return $null
   }
 }

 function Get-ComplianceAccessTokenByDeviceCode {
   param(
       [string]$TenantId,
       [string]$Scope
   )

   $clientId = 'fb78d390-0c51-40cd-8e17-fdbfab77341b'
   $deviceUri = "https://login.microsoftonline.com/$TenantId/oauth2/v2.0/devicecode"
   $tokenUri = "https://login.microsoftonline.com/$TenantId/oauth2/v2.0/token"
   $device = Invoke-RestMethod -Method Post -Uri $deviceUri -Body @{
       client_id = $clientId
       scope = $Scope
   }
   Write-Host $device.message
   $deadline = (Get-Date).AddSeconds([int]$device.expires_in)
   do {
       Start-Sleep -Seconds ([Math]::Max(5, [int]$device.interval))
       try {
         $token = Invoke-RestMethod -Method Post -Uri $tokenUri -Body @{
             grant_type = 'urn:ietf:params:oauth:grant-type:device_code'
             client_id = $clientId
             device_code = $device.device_code
         }
         return $token.access_token
       }
       catch {
         $code = Get-OauthErrorCode $_
         if ($code -eq 'authorization_pending' -or $code -eq 'slow_down') {
             continue
         }
         throw
       }
   } while ((Get-Date) -lt $deadline)

   throw 'Device code login timed out.'
 }

 function Connect-PurviewAdminIppsSession {
   param(
       [string]$AdminUpn,
       [string]$TenantId,
       [string]$Organization
   )

   Write-Host "Connecting to Security & Compliance PowerShell as $AdminUpn ..."
   Write-Host 'Using device code sign-in (Graph + ExchangeOnlineManagement in the same session breaks interactive MSAL/WAM auth).'

   $scopes = @(
       'https://ps.compliance.protection.outlook.com/.default',
       'https://outlook.office365.com/.default'
   )
   $accessToken = $null
   $lastError = $null
   foreach ($scope in $scopes) {
       try {
         $accessToken = Get-ComplianceAccessTokenByDeviceCode -TenantId $TenantId -Scope $scope
         break
       }
       catch {
         $lastError = $_
       }
   }
   if ([string]::IsNullOrEmpty($accessToken)) {
       throw "Could not acquire a compliance access token. $($lastError.Exception.Message)"
   }

   Connect-IPPSSession -AccessToken $accessToken -Organization $Organization -UserPrincipalName $AdminUpn -ShowBanner:$false
 }

 function Resolve-OpenSslEnvironment {
   param([string]$OpenSslPath)

   $previousConf = $env:OPENSSL_CONF
   $confPath = $null

   if (-not [string]::IsNullOrWhiteSpace($previousConf) -and (Test-Path -LiteralPath $previousConf)) {
       return @{
         PreviousOpenSslConf = $previousConf
         ChangedOpenSslConf = $false
       }
   }

   $searchRoots = @(
       (Split-Path -Parent $OpenSslPath)
       (Split-Path -Parent (Split-Path -Parent $OpenSslPath))
   )
   foreach ($root in ($searchRoots | Select-Object -Unique)) {
       $candidate = Join-Path $root 'ssl\openssl.cnf'
       if (Test-Path -LiteralPath $candidate) {
         $confPath = $candidate
         break
       }
   }

   if ($confPath) {
       $env:OPENSSL_CONF = $confPath
   }
   else {
       Remove-Item Env:OPENSSL_CONF -ErrorAction SilentlyContinue
   }

   return @{
       PreviousOpenSslConf = $previousConf
       ChangedOpenSslConf = $true
   }
 }

 function New-VendorCertificateWithOpenSsl {
   param(
       [string]$CertDnsName,
       [int]$DaysValid,
       [string]$CerPath,
       [string]$PfxPath,
       [string]$KeyPath,
       [string]$PlainPassword,
       [string]$OpenSslPath
   )

   $previous = $env:CERT_PASSWORD
   $env:CERT_PASSWORD = $PlainPassword
   $openSslEnv = Resolve-OpenSslEnvironment -OpenSslPath $OpenSslPath
   try {
       & openssl req -x509 -newkey rsa:2048 -sha256 -days $DaysValid `
         -subj "/CN=$CertDnsName" `
         -keyout $KeyPath `
         -out $CerPath `
         -passout env:CERT_PASSWORD
       if ($LASTEXITCODE -ne 0) {
         throw "openssl req failed with exit code $LASTEXITCODE"
       }

       $pkcs12 = @(
         'pkcs12', '-export',
         '-inkey', $KeyPath,
         '-in', $CerPath,
         '-out', $PfxPath,
         '-passin', 'env:CERT_PASSWORD',
         '-passout', 'env:CERT_PASSWORD',
         '-certpbe', 'PBE-SHA1-3DES',
         '-keypbe', 'PBE-SHA1-3DES',
         '-macalg', 'sha1'
       )
       & openssl @pkcs12
       if ($LASTEXITCODE -ne 0) {
         & openssl @($pkcs12 + '-legacy')
       }
       if ($LASTEXITCODE -ne 0) {
         throw "openssl pkcs12 failed with exit code $LASTEXITCODE"
       }
   }
   finally {
       if ($openSslEnv.ChangedOpenSslConf) {
         if ([string]::IsNullOrWhiteSpace($openSslEnv.PreviousOpenSslConf)) {
             Remove-Item Env:OPENSSL_CONF -ErrorAction SilentlyContinue
         }
         else {
             $env:OPENSSL_CONF = $openSslEnv.PreviousOpenSslConf
         }
       }
       if ($null -eq $previous) {
         Remove-Item Env:CERT_PASSWORD -ErrorAction SilentlyContinue
       }
       else {
         $env:CERT_PASSWORD = $previous
       }
   }
 }

 function New-VendorCertificateWithWindowsApi {
   param(
       [string]$CertDnsName,
       [int]$CertYearsValid,
       [string]$CerPath,
       [string]$PfxPath,
       [Security.SecureString]$CertPassword
   )

   $created = New-SelfSignedCertificate `
       -DnsName $CertDnsName `
       -CertStoreLocation 'Cert:\CurrentUser\My' `
       -NotAfter (Get-Date).AddYears($CertYearsValid) `
       -KeySpec KeyExchange
   $null = $created | Export-PfxCertificate -FilePath $PfxPath -Password $CertPassword
   $null = $created | Export-Certificate -FilePath $CerPath
 }

 function New-VendorCertificateFiles {
   param(
       [string]$FileBaseName,
       [string]$CertDnsName,
       [int]$CertYearsValid,
       [Security.SecureString]$CertPassword
   )

   $outputDir = (Get-Location).Path
   $cerPath = Join-Path $outputDir "$FileBaseName.cer"
   $pfxPath = Join-Path $outputDir "$FileBaseName.pfx"
   $keyPath = Join-Path $outputDir "$FileBaseName.key"
   $openssl = Get-Command openssl -ErrorAction SilentlyContinue

   if (Test-IsWindowsOs) {
       Write-Host 'Creating certificate with New-SelfSignedCertificate...'
       New-VendorCertificateWithWindowsApi `
         -CertDnsName $CertDnsName `
         -CertYearsValid $CertYearsValid `
         -CerPath $cerPath `
         -PfxPath $pfxPath `
         -CertPassword $CertPassword
   }
   elseif ($openssl) {
       Write-Host 'Creating certificate with OpenSSL...'
       New-VendorCertificateWithOpenSsl `
         -CertDnsName $CertDnsName `
         -DaysValid ($CertYearsValid * 365) `
         -CerPath $cerPath `
         -PfxPath $pfxPath `
         -KeyPath $keyPath `
         -PlainPassword (Get-PlainPassword $CertPassword) `
         -OpenSslPath $openssl.Source
       Remove-Item -LiteralPath $keyPath -Force -ErrorAction SilentlyContinue
   }
   else {
       throw 'OpenSSL was not found on PATH. Install OpenSSL (required on macOS and Linux).'
   }

   if (-not (Test-Path -LiteralPath $cerPath) -or -not (Test-Path -LiteralPath $pfxPath)) {
       throw "Certificate files were not created: $cerPath / $pfxPath"
   }

   $plain = Get-PlainPassword $CertPassword
   $loaded = [System.Security.Cryptography.X509Certificates.X509CertificateLoader]::LoadPkcs12FromFile(
       $pfxPath,
       $plain,
       [System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::Exportable)
   Write-Host "Verified PFX loads in .NET (DAS tests / wizard). Thumbprint=$($loaded.Thumbprint)"

   $publicCert = [System.Security.Cryptography.X509Certificates.X509Certificate2]::new($cerPath)
   return [pscustomobject]@{
       CerPath = $cerPath
       PfxPath = $pfxPath
       Certificate = $publicCert
   }
 }

 $CertPassword = Get-ConfirmedCertPassword -CertPassword $CertPassword
 $fileBaseName = Get-SafeFileName -Name $AppName

 ''
 'Connecting to Microsoft Graph...'

 # Import only the Graph submodules needed for this script to reduce startup time
 $graphModules = @(
   'Microsoft.Graph.Authentication',
   'Microsoft.Graph.Applications',
   'Microsoft.Graph.Identity.DirectoryManagement'
 )
 foreach ($module in $graphModules) {
   if (-not (Get-Module -ListAvailable -Name $module)) {
       throw "Required module not found: $module"
   }
   Import-Module $module -ErrorAction Stop
 }

 if (-not (Get-Module -ListAvailable -Name ExchangeOnlineManagement)) {
   throw "Required module not found: ExchangeOnlineManagement"
 }
 Import-Module ExchangeOnlineManagement -ErrorAction Stop

 $TenantId = Get-ConfirmedTenantId -TenantId $TenantId
 Connect-MgGraph -TenantId $TenantId -Scopes 'Application.Read.All', 'Application.ReadWrite.All', 'AppRoleAssignment.ReadWrite.All', 'Directory.ReadWrite.All', 'RoleManagement.ReadWrite.Directory', 'Organization.Read.All'

 ''
 'Getting required API details...'
 function Get-RequireResource{
   param($appId, $permissionValues)

   $appObj = (Get-MgServicePrincipal -Filter ("AppId eq '{0}'" -f $appId))
   $appPermissions = $appObj.AppRoles | Where-Object {$_.Value -in $permissionValues}
   $appHT = @()
   foreach($ap in $appPermissions){
       $appHT += @{
         Id = $ap.Id;
         Type = "Role";
       }
   }
   $appResource = @{
       ResourceAppId = $appId
       ResourceAccess = $appHt
   }
   return $appResource;
 }

 $exoPermissionValues = 'Exchange.ManageAsApp'

 ''
 'Building API permissions...'
 ## Build the API permission object (TYPE: Role = Application)
 $AppsAndPermissions = @{
   '00000002-0000-0ff1-ce00-000000000000' = $exoPermissionValues
 }
 $apiPermission = @()
 foreach($aAndP in $AppsAndPermissions.GetEnumerator()) {
   $apiPermission += Get-RequireResource $aAndP.Name $aAndP.Value
 }

 ''
 'Registering Azure App...'
 ## Register the new Azure AD App with API Permissions
 $myApp = New-MgApplication -DisplayName $AppName -RequiredResourceAccess $apiPermission

 ## Enable the Service Principal
 $mySP = New-MgServicePrincipal -AppId $myApp.AppID

 ## Find or activate the directory role
 $role = Get-MgDirectoryRole -Filter ("displayName eq '{0}'" -f $DirectoryRole)
 if (-not $role) {
   $roleTemplate = Get-MgDirectoryRoleTemplate -Filter ("displayName eq '{0}'" -f $DirectoryRole)
   if ($roleTemplate) {
       $role = New-MgDirectoryRole -RoleTemplateId $roleTemplate.Id
   }
 }

 ## Add the service principal to the directory role
 if ($role) {
   $refBody = @{
       "@odata.id" = "https://graph.microsoft.com/v1.0/directoryObjects/$($mySP.Id)"
   }
   New-MgDirectoryRoleMemberByRef -DirectoryRoleId $role.Id -BodyParameter $refBody
 }

 # Display the new App properties
 ''
 "App Display Name: $($myApp.DisplayName)"
 "App ID: $($myApp.AppID)"
 "Enterprise Application Object ID: $($mySP.Id)"

 ''
 'Creating certificate...'
 $certFiles = New-VendorCertificateFiles `
   -FileBaseName $fileBaseName `
   -CertDnsName $CertDnsName `
   -CertYearsValid $CertYearsValid `
   -CertPassword $CertPassword
 $myCert = $certFiles.Certificate

 ''
 "Certificate pfx file path: $($certFiles.PfxPath)"
 "Certificate cer file path: $($certFiles.CerPath)"
 ''
 'Uploading certificate to Azure App...'
 ## Upload and assign the certificate to application in Microsoft Graph
 $keyCredentials = @{
   customKeyIdentifier = $myCert.GetCertHash()
   key = $myCert.GetRawCertData()
   type = "AsymmetricX509Cert"
   usage = "Verify"
   startDateTime = $myCert.NotBefore
   endDateTime = $myCert.NotAfter
 }
 Update-MgApplication -ApplicationId $myApp.Id -KeyCredentials $keyCredentials

 ''
 "Waiting $SleepBeforeConsentSeconds seconds to allow the Azure App to be fully created before consent..."

 Start-Sleep $SleepBeforeConsentSeconds

 ''
 'Getting tenant details for consent...'
 ## Get the TenantID
 $org = Get-MgOrganization
 $tenantID = $org.Id
 $organization = @($org.VerifiedDomains | Where-Object { $_.IsInitial } | Select-Object -ExpandProperty Name)[0]
 if ([string]::IsNullOrEmpty($organization)) {
   $organization = @($org.VerifiedDomains | Where-Object { $_.Name -like '*.onmicrosoft.com' } | Select-Object -ExpandProperty Name)[0]
 }

 ## Browse this URL
 $consentURL = "https://login.microsoftonline.com/$tenantID/adminconsent?client_id=$($myApp.AppId)"

 # Display the consent URL
 ''
 "Consent URL: $consentURL"

 ''
 'Launching browser for consent...'
 Open-DefaultBrowser -Url $consentURL
 $null = Read-Host 'Press Enter after Entra API permissions shows Exchange.ManageAsApp as Granted'

 Connect-PurviewAdminIppsSession -AdminUpn $AdminUpn -TenantId $tenantID -Organization $organization

 $existing = Get-ServicePrincipal | Where-Object AppId -eq $myApp.AppId
 if ($existing) {
   $ippsSp = $existing
   "Service principal already registered: $($ippsSp.DisplayName)"
 }
 else {
   $ippsSp = New-ServicePrincipal -AppId $myApp.AppId -ObjectId $mySP.Id -DisplayName $AppName
   "Created service principal: $($ippsSp.Identity)"
 }

 $listViewer = Get-ContentExplorerListViewerRoleGroup
 $listViewerKey = Get-RoleGroupKey -RoleGroup $listViewer
 $members = @(Get-RoleGroupMember -Identity $listViewerKey)
 if ($members.Identity -contains $ippsSp.Identity) {
   "Already a member of '$($listViewer.Name)'."
 }
 else {
   Add-RoleGroupMember -Identity $listViewerKey -Member $ippsSp.Identity
   "Added to '$($listViewer.Name)'."
 }

 Disconnect-ExchangeOnline -Confirm:$false

 ''
 'Done.'
 ''
 'Gather this for Data Access Security / explicit tests:'
 "  App ID: $($myApp.AppId)"
 "  Organization: $organization"
 "  PFX: $($certFiles.PfxPath)"
 '  Password: the PFX password you entered at the start'

Run the script. When prompted, log in with administrator credentials to create and configure Azure applications. Type the PFX password twice when asked.

  1. Open PowerShell 7 (pwsh).
  2. Install the Microsoft Graph PowerShell module: Install-Module -Name Microsoft.Graph
  3. Install the Exchange Online Management module: Install-Module -Name ExchangeOnlineManagement
  4. From the directory that contains the script, run: ./CreatePurviewVendorApp.ps1 -AppName "DAS Purview Vendor App" -DirectoryRole "Compliance Administrator" -CertDnsName "contoso.com" -CertYearsValid 10 -AdminUpn "admin@contoso.onmicrosoft.com" -TenantId "<entra-tenant-guid>"

The consent step of the script will launch a URL to grant admin consent for the application. After granting consent the page will redirect to a missing localhost URL. This can be ignored. Select Enter in the script after API permissions shows Exchange.ManageAsApp as Granted.

The last step of the script connects to Security & Compliance PowerShell as AdminUpn and assigns Content Explorer List Viewer. It uses device-code login on every OS (open the URL and enter the code it prints). Use an account that can manage Purview role groups.

Note

If you experience an access denied error or other error in the web browser when granting admin consent, this might be a timing issue. This can be resolved by either manually granting admin consent through the Azure portal. Alternatively, you can copy and paste the consent URL into your browser. This is the last line of output from the script output that contains text adminconsent.

The following output should be gathered or noted when running the script. This information will be used to configure the Microsoft Purview vendor in Data Access Security.

  1. The App ID value in the console output.
  2. The created certificate file .pfx located in your working directory.
  3. The certificate password that was entered when prompted.

Creating and Configuring the Application Manually

The following steps will create and configure an Azure application for Microsoft Purview vendor authentication through the Azure portal.

These steps are adapted from Microsoft documentation.

Registering the Application in Azure AD

  1. Go to the the Azure AD portal.
  2. Under Manage Azure Active Directory, select View.
  3. On the Overview page, select App registrations under Manage.
  4. On the App registrations page, select New registration.
  5. On the Register an application page, configure the following settings:
    • Name - Enter something descriptive, like "DAS Purview Vendor App"
    • Supported account types - Verify that Accounts in this organizational directory only (Single tenant) is selected.
    • Redirect URI (optional) - Leave empty
  6. Select Register.

The portal now shows the app registration. Note two different GUIDs on that Overview page:

Label in the portal What it is Used for
Application (client) ID The app's client ID (AppId) Data Access Security wizard Application ID; New-ServicePrincipal -AppId
Object ID (on App registrations) The registration object Do not use for the Purview List Viewer step

Entra also creates a second object: the enterprise application (service principal). That object has its own Object ID.

Where to open it Label Used for
Entra ID > Enterprise applications > the same app name > Overview Object ID New-ServicePrincipal -ObjectId (Content Explorer List Viewer)

From Graph, given only the Application (client) ID:

Get-MgServicePrincipal -Filter "appId eq '<application-client-id>'" | Select-Object DisplayName, AppId, Id

Id is the enterprise application Object ID. The automated script prints this as Enterprise Application Object ID.

Assigning API Permissions to the Application

  1. On the Manifest page, under Manage, select Manifest.
  2. On the Manifest page, find the `requiredResourceAccess entry.
  3. Replace the entire requiredResourceAccess entry with the following:

    "requiredResourceAccess": [
       {
           "resourceAppId": "00000002-0000-0ff1-ce00-000000000000",
           "resourceAccess": [
               {
                   "id": "dc50a0fb-09a3-484d-be87-e023b12c6440",
                   "type": "Role"
               }
           ]
       }
    ],
    
  4. Select Save.

  5. On the Manifest page, under Manage, select API permissions.
  6. On the API permissions page, verify that Exchange.ManageAsApp appears on the list.
  7. Select Grant admin consent for <Organization>. Read the confirmation dialog.
  8. Select Yes in the confirmation dialog. The Status value should now be Granted for the entry.
  9. Close the API Permissions page (not the browser tab).

Generating a Self-Signed Certificate

Create a self-signed x.509 certificate using the following PowerShell commands. These Windows commands match the Exchange Online help page. On macOS or Linux, use the automated script (OpenSSL) instead of this section.

Edit parameters such as DnsName, Certificate expiration, and password as appropriate:

Create certificate

$mycert = New-SelfSignedCertificate -DnsName **"contoso.org"** -CertStoreLocation "cert:\LocalMachine\My" -NotAfter (Get-Date).AddYears(**15**) -KeySpec KeyExchange 

Export certificate to .pfx file

This .pfx file will be used in the application configuration.

$mycert | Export-PfxCertificate -FilePath mycert.pfx -Password $(ConvertTo-SecureString -String "**P@ssw0Rd1234**" -AsPlainText -Force)

Export certificate to .cer file.

$mycert | Export-Certificate -FilePath mycert.cer

Assigning the Certificate to the Azure Active Directory Application

After you register the certificate with your application, you can use the private key (.pfx file) for authentication.

  1. Go to the the Azure AD portal.
  2. Under Manage Azure Active Directory, select View.
  3. On the Overview page, under Manage, select App registrations.
  4. On the Apps registration page, select the application you registered.
  5. On the application page, under Manage, select Certificates & secrets.
  6. Select Upload Certificate.
  7. Browse to the self-signed certificate .cer file that you created when generating a self-signed certificate.
  8. Select Add.

The certificate is now shown in the Certificates section.

Assigning the Compliance Administrator Role to the Application

  1. Go to the the Azure AD portal.
  2. Under Manage Azure Active Directory, select View.
  3. On the Overview page, under Manage, select Roles and Administrators.
  4. Select the Compliance Administrator role by clicking on the name of the role, not the checkbox.
  5. The Add assignment dialog displays. Find and select the application you registered.
  6. Select Add.

On the Assignments page, verify the application has been assigned to the role.

Assigning the Content Explorer List Viewer Role to the Application

Note

Do this in PowerShell. The portals can add a user or a security group to Content Explorer List Viewer. They do not add the application. If the member you see is a security group that contains the app, that is not the membership this import uses. The import signs in as the app. We believe the app itself has to be a member, using the commands below.

This assignment cannot be performed in the Azure portal or the Microsoft Purview portal. It is required for Export-ContentExplorerData (ImportVendor Run Now). Wizard Test Connection does not check this role; a green test with a failed import usually means List Viewer is missing.

Perform CreatePurviewVendorApp.ps1 (device-code login). The commands below are the manual path. Use a new PowerShell window (do not reuse the Graph session from the automated script). Interactive Connect-IPPSSession works in that standalone session.

  1. Open PowerShell.
  2. Install the Exchange Online Management module if needed: Install-Module -Name ExchangeOnlineManagement
  3. Connect to Security & Compliance PowerShell as an administrator who can manage Purview role groups:

    Connect-IPPSSession -UserPrincipalName "admin@contoso.onmicrosoft.com"
    
  4. Create the Purview service principal for the Entra enterprise application. Pass both IDs:

    • AppId — Application (client) ID from App registrations.
    • ObjectId — Object ID from Enterprise applications (the Graph Get-MgServicePrincipal Id above). Do not use the Object ID from the App registrations Overview page.
    New-ServicePrincipal -AppId "<application-client-id>" -ObjectId "<enterprise-application-object-id>" -DisplayName "DAS Purview Vendor App"
    
  5. Add the service principal to Content Explorer List Viewer. Use the role group Guid (the Identity path can match more than one object). This only adds a member; it does not remove other apps already in the group.

    $sp = Get-ServicePrincipal | Where-Object AppId -eq "<application-client-id>"
    $listViewer = Get-RoleGroup | Where-Object { ($_.Name -replace '\s', '') -ieq 'ContentExplorerListViewer' }
    Add-RoleGroupMember -Identity $listViewer.Guid.ToString() -Member $sp.Identity
    

Do not assign Content Explorer Content Viewer. Data Access Security exports item locations and classification names, not file contents.

Data Access Security Values

In Compliance > Data Classification > Classification Label Imports > Source Configuration, enter:

Field Value from this procedure
Tenant Domain Name The tenant's initial domain (contoso.onmicrosoft.com). Not the Directory (tenant) ID. Not a custom domain.
Application ID Application (client) ID from the script output (or App registrations → Overview).
Certificate File The .pfx or p12 file created in the working directory.
Certificate Password The password entered when the script (or manual cert export) created that file.

Documentation Feedback

Feedback is provided as an informational resource only and does not form part of SailPoint’s official product documentation. SailPoint does not warrant or make any guarantees about the feedback (including without limitation as to its accuracy, relevance, or reliability). All feedback is subject to the terms set forth at https://developer.sailpoint.com/discuss/tos.