Microsoft Foundry Keys or Connection Secrets Accessed by New Principal

Last updated 5 days ago on 2026-10-23
Created 5 days ago on 2026-10-23

About

Identifies the first time in seven days that a high-privilege Azure principal lists or regenerates the API keys of a Microsoft Foundry (Azure AI Services) account, or reads the stored secrets of a Foundry account or project connection. Account keys grant direct inference access to every model deployment on the account and bypass Entra ID conditional access, and connection secrets hold credentials for downstream services such as Azure OpenAI, storage, and search. A compromised identity retrieving these keys is a common first step in LLMjacking and in pivoting from a Foundry project to the data it is connected to.
Tags
Domain: CloudDomain: GenAIData Source: AzureData Source: Azure Activity LogsData Source: Microsoft FoundryPlatform: AzureUse Case: Threat DetectionTactic: Credential AccessTactic: Initial AccessThreat: LLMjackingThreat: Unauthorized AI UsageMitre Atlas: AML.T0055Rule Type: New TermsLanguage: kuery
Severity
medium
Risk Score
47
MITRE ATT&CK™

Credential Access (TA0006)(external, opens in a new tab or window)

Initial Access (TA0001)(external, opens in a new tab or window)

False Positive Examples
Administrators with Owner or Contributor roles opening the Keys and Endpoint blade in the Azure portal or Foundry portal, which issues a listKeys call. Confirm the activity with the principal and prefer Entra ID authentication over key-based access. Infrastructure-as-code pipelines and deployment scripts that read keys to configure applications. Prefer managed identities, or add exceptions for the service principals that run these pipelines.
License
Elastic License v2(external, opens in a new tab or window)

Definition

Rule Type
New Terms Rule
Integration Pack
Prebuilt Security Detection Rules
Index Patterns
logs-azure.activitylogs-*
Related Integrations

azure(external, opens in a new tab or window)

Query
text code block:
data_stream.dataset: "azure.activitylogs" and azure.activitylogs.operation_name: ( "MICROSOFT.COGNITIVESERVICES/ACCOUNTS/LISTKEYS/ACTION" or "MICROSOFT.COGNITIVESERVICES/ACCOUNTS/REGENERATEKEY/ACTION" or "MICROSOFT.COGNITIVESERVICES/ACCOUNTS/CONNECTIONS/LISTSECRETS/ACTION" or "MICROSOFT.COGNITIVESERVICES/ACCOUNTS/PROJECTS/CONNECTIONS/LISTSECRETS/ACTION" ) and azure.activitylogs.identity.authorization.evidence.role: ( "Owner" or "Contributor" or "Cognitive Services Contributor" or "Cognitive Services OpenAI Contributor" or "User Access Administrator" ) and event.outcome: "success"

Install detection rules in Elastic Security

Detect Microsoft Foundry Keys or Connection Secrets Accessed by New Principal in the Elastic Security detection engine by installing this rule into your Elastic Stack.

To setup this rule, check out the installation guide for Prebuilt Security Detection Rules(external, opens in a new tab or window).