Page History
...
- Navigate to
https://<Admin Center>/_layouts/15/
AppInv.aspx
(e.g. https://intlock-admin.sharepoint.com/_layouts/15/AppInv.aspx). Paste client ID generated earlier into App Id field. Click Lookup. The existing values for Title, App Domain and Redirect URL should appear.
Enter the following XML into the App's Permission Request XML field to specify required permissions. Then click Create.
<
AppPermissionRequests
AllowAppOnlyPolicy
=
"true"
>
</
AppPermissionRequests
>
- You will be prompted to approve permissions for the app. Click Trust It.
- You can check the App registration details by navigating to:
https://<Admin Center>/_layouts/15/
AppPrincipals.aspx
You can test the App credentials by executing the following powershell PowerShell commands to retrieve the list of all available site collections.
$ Connect-PnPOnline https://<your-tenant>-admin.sharepoint.com -AppId <your-app-id> -AppSecret <your-app-secret>$ Get-PnPTenantSite
Anchor | ||||
---|---|---|---|---|
|
Execute the following PowerShell script with the SharePoint Online Global Administrator account in order to retrieve your App client ID. Edit the "CardioLogApp" name. You can check what is your App name by navigating to:
https://<Admin Center>/_layouts/15/
AppPrincipals.aspx
Code Block Connect-MsolService $applist = Get-MsolServicePrincipal -all |Where-Object -FilterScript { ($_.DisplayName -like "*CardioLogApp") } foreach ($appentry in $applist) { $principalId = $appentry.AppPrincipalId $principalName = $appentry.DisplayName Get-MsolServicePrincipalCredential -AppPrincipalId $principalId -ReturnKeyValues $false | ? { $_.Type -eq "Password" } | % { "$principalName;"+"`nClient ID: "+"$principalId;"+"`nClient Secret ID: " + $_.KeyId.ToString() +";" + $_.StartDate.ToString() + ";" + $_.EndDate.ToString() } | out-file -FilePath c:\appsec.txt -append }
- Open the C:\appsec.txt output file and copy the Client ID value:
Execute the following PowerShell script with the SharePoint Online Global Administrator account. Edit the "Client ID" and use the value copied from step 2.
Code Block Connect-MsolService $clientId = "Client ID" $keys = Get-MsolServicePrincipalCredential -AppPrincipalId $clientId $keys Remove-MsolServicePrincipalCredential -KeyIds $keys.KeyId -AppPrincipalId $clientId
Execute the following PowerShell script with the SharePoint Online Global Administrator account, in the same PowerShell window, in order to generate a new client secret ID.
Code Block $bytes = New-Object Byte[] 32 $rand = [System.Security.Cryptography.RandomNumberGenerator]::Create() $rand.GetBytes($bytes) $rand.Dispose() $newClientSecret = [System.Convert]::ToBase64String($bytes) $dtStart = [System.DateTime]::Now $dtEnd = $dtStart.AddYears(1) New-MsolServicePrincipalCredential -AppPrincipalId $clientId -Type Symmetric -Usage Sign -Value $newClientSecret -StartDate $dtStart -EndDate $dtEnd New-MsolServicePrincipalCredential -AppPrincipalId $clientId -Type Symmetric -Usage Verify -Value $newClientSecret -StartDate $dtStart -EndDate $dtEnd New-MsolServicePrincipalCredential -AppPrincipalId $clientId -Type Password -Usage Verify -Value $newClientSecret -StartDate $dtStart -EndDate $dtEnd $newClientSecret
Copy the client secret ID and update it in CardioLog configuration settings:
- In the Administration section of the Navigation pane, click System Configuration, and then select SharePoint Tree Adaptor.
- Click on your SharePoint Online tenant.
- Click Set next to the Authentication settings and select the OAuth option
- Enter the Client ID (copied from step 2) and renewed client secret ID (generated in step 4) and click Save.
Anchor | ||||
---|---|---|---|---|
|
...