azure-appsvc-publishxml

derived azure emits CanReadSecret

match (effective permission)

{ "action": "Microsoft.Web/sites/publishxml/action", "scope_type": "resource|resourceGroup|subscription" }

emit

source<principal>
target<publishing profile credential of the site>
permissionsMicrosoft.Web/sites/publishxml/action
conditionsservice_state

Narrative

{principal.name} can download the publishing profile of {target.name} (publishxml/action), yielding SCM/FTP username+password without Key Vault access.

Raw rule rules/derived/azure/appservice.yaml

id: azure-appsvc-publishxml
emits: CanReadSecret
match_effective_permission:
  action: Microsoft.Web/sites/publishxml/action
  scope_type: resource|resourceGroup|subscription
emit:
  source: <principal>
  target: <publishing profile credential of the site>
  permissions:
  - Microsoft.Web/sites/publishxml/action
  conditions:
  - service_state
  note: Returns the publishing profile XML (userName/userPWD) for Web Deploy, FTP, and the SCM/Kudu site
    -> data-plane code execution. The companion credential-exposure fact is emitted by azure-appsvc-publishxml-exposescred
    (ExposesCredential).
  false_positive_note: 'The returned creds only authenticate if basic auth is enabled: if basicPublishingCredentialsPolicies
    (SCM/FTP) allow=false the profile is useless -> emit CONDITIONAL(service_state) or BLOCKED unless
    the attacker also holds basicPublishingCredentialsPolicies/write (azure-appsvc-reenable-basic-auth).'
  narrative: '{principal.name} can download the publishing profile of {target.name} (publishxml/action),
    yielding SCM/FTP username+password without Key Vault access.'
move · open · esc close