SYSTEM 8Discuss a system ↗
DOCS / RUN-GRAPH-001

RUN-GRAPH-001 / SOURCE CONTROLLED

Microsoft Graph Selected-permission review runbook

Use when an unattended application accesses a bounded SharePoint workload but holds broad Microsoft Graph application permission such as Sites.ReadWrite.All.

● CONTROLLEDOWNER / SYSTEM 8REVIEW / MONTHLY
01

Authority and zero gate

  • Name business, application, SharePoint and security owners.
  • Classify active incident versus planned least-privilege migration.
  • Freeze unapproved consent and credential changes.
  • Preserve service-principal sign-in, consent, deployment and API evidence.
  • Never record credential values or access tokens in the review pack.
02

Identity and authority inventory

OBJECTCAPTUREPROOF
ApplicationApp ID, object ID, tenant, publisher, ownersApplication export
Service principalObject ID, enabled state, app-role assignmentsEnterprise-app export
CredentialsType, key ID, owner, store, expiryMetadata only
TokenAudience, tenant, app identity, roles, issue/expiryRedacted decoded claims
SharePoint grantsSite/list/item, app identity, rolePermission resource output
HostRuntime, deployment source, vault/RBAC, networkConfiguration evidence
03

Operation-to-permission contract

OPERATIONRESOURCEENDPOINT/METHODMINIMUM ROLEFAILURE EFFECT
Resolve targetKnown siteRecord exact callProve Selected fitStop; no broad discovery fallback
Read source stateNamed list/libraryRecord exact callReadVisible retry/reconcile
Create/updateNamed list/libraryRecord exact callWriteIdempotent replay
Delete/manageExplicit item/siteRecord exact callOnly if approvedBusiness approval required

Populate this table from code and observed traffic. Do not select permissions from product names alone.

04

Selected-permission implementation

  1. Choose the narrowest supported Selected scope: site, list, list item/folder or file.
  2. Grant that scope to the runtime application in Entra ID.
  3. Using a separate authorised grantor, create the explicit resource permission with the minimum role.
  4. Acquire a new runtime token containing the Selected scope.
  5. Test every contracted endpoint on the target.
  6. Remove global SharePoint application roles only after the bounded path passes.
  7. Acquire another new token and prove unrelated-resource denial.

Selected scope consent without a resource assignment provides no access. A resource assignment without the matching token scope also provides no access.

05

Positive and negative matrix

TESTEXPECTEDEVIDENCE
Contracted target operationsSuccessBusiness record + Graph status
Unrelated project siteDeniedFresh-token response
Sensitive finance/people siteDeniedFresh-token response
Similarly named siteDeniedFresh-token response
Out-of-scope list/itemDenied when narrower grant usedFresh-token response
Permission/grant modificationDenied to runtimeGraph response
Credential revocationNew token deniedSign-in/token result
06

Credential and host control

  • Prefer managed identity or workload identity federation where supported.
  • Otherwise govern certificate or client-secret storage, rotation, expiry and revocation.
  • Separate development, test and production identities and sites.
  • Remove departed owners; retain accountable primary and backup operators.
  • Constrain host, vault and pipeline rights independently of Graph consent.
  • Never give the runtime identity consent-granting or resource-granting authority.
07

Release and review gate

Release only when every contracted operation passes, every prohibited resource is denied with a fresh token, the broad app role is absent, the explicit resource grant matches the intended application and role, obsolete credentials are revoked, and a second operator can rotate or disable the workload. Review quarterly and after code, endpoint, owner, credential, hosting or consent changes.

08

Limits

Selected permissions constrain supported SharePoint and OneDrive resource access; they do not constrain unrelated Graph permissions, Azure RBAC, host compromise or the damage possible inside the granted resource. Endpoint compatibility must be tested. This runbook does not authorise incident closure, consent grant or deletion of an unknown enterprise application.