Skip to content

AZT601.2 - Steal Managed Identity JsonWebToken: Azure Kubernetes Service IMDS Request#

By utilizing access to IMDS, an attacker can request a JWT for a Managed Identity on an AKS Cluster if they have access to execute commands on the system.

Resource

Azure Kubernetes Service

Actions

  • Microsoft.ContainerService/managedClusters/runcommand/action
  • Microsoft.ContainerService/managedclusters/commandResults/read

Examples

Detections

Detection Details#

Logs are only generated when running a command through az cli or Az PowerShell. Using kubectl will not generate logs.

Logs#

Data Source Operation Name Action Log Provider
Resource RunCommand Microsoft.ContainerService/managedClusters/runCommand/action AzureActivity

Queries#

Platform Query
Log Analytics AzureDiagnostics | where log_s has '169.254.169.254'

Azure Monitor Alert#

Deploy to Azure