azure-aml-datastore-listsecrets

Retrieve stored datastore credentials (storage account key, SAS token, or SP client secret) via listsecrets.

derived azure emits CanReadSecret

match (effective permission)

{ "action": "Microsoft.MachineLearningServices/workspaces/datastores/listsecrets/action", "scope_type": "resource|resourceGroup|subscription" }

emit

source typeIdentity
source<principal>
target<datastore credential (ConnectionString / AccessKey / Secret)>
permissionsMicrosoft.MachineLearningServices/workspaces/datastores/listsecrets/action

Narrative

{principal.name} can retrieve the stored credentials of AML datastore {target.name} (datastores/listsecrets/action), including storage account keys, SAS tokens, or service principal client secrets.

Raw rule rules/derived/azure/machinelearning.yaml

id: azure-aml-datastore-listsecrets
emits: CanReadSecret
description: Retrieve stored datastore credentials (storage account key, SAS token, or SP client secret)
  via listsecrets.
match_effective_permission:
  action: Microsoft.MachineLearningServices/workspaces/datastores/listsecrets/action
  scope_type: resource|resourceGroup|subscription
emit:
  source_type: Identity
  source: <principal>
  target: <datastore credential (ConnectionString / AccessKey / Secret)>
  permissions:
  - Microsoft.MachineLearningServices/workspaces/datastores/listsecrets/action
  note: "Retrieves: storage account key (AccountKey datastores), SAS token (SAS datastores), service principal\
    \ client secret (ServicePrincipal datastores), or certificate. AzureML Data Scientist does NOT include\
    \ this action \u2014 requires Contributor/Owner or an explicit custom grant."
  false_positive_note: "The built-in AzureML Data Scientist role does NOT include listsecrets/action.\
    \ Do not emit CanReadSecret for datastore credentials unless the principal explicitly holds this action\
    \ or Contributor/Owner at the workspace or resource-group scope. The action returns the credential\
    \ value; modeling this as CanReadSecret (not merely CanRead) is intentional. Credentials for identity-credential\
    \ datastores (MI-backed) contain no secret to retrieve \u2014 only emit for credential_type in [accountKey,\
    \ sas, servicePrincipal, certificate]."
  narrative: '{principal.name} can retrieve the stored credentials of AML datastore {target.name} (datastores/listsecrets/action),
    including storage account keys, SAS tokens, or service principal client secrets.'
move · open · esc close