[New Rule] Azure AKS Ephemeral Container Added to Pod#6426
Open
terrancedejesus wants to merge 8 commits into
Open
[New Rule] Azure AKS Ephemeral Container Added to Pod#6426terrancedejesus wants to merge 8 commits into
terrancedejesus wants to merge 8 commits into
Conversation
Contributor
Rule: New - GuidelinesThese guidelines serve as a reminder set of considerations when proposing a new rule. Documentation and Context
Rule Metadata Checks
New BBR Rules
Testing and Validation
|
terrancedejesus
marked this pull request as ready for review
July 20, 2026 20:13
terrancedejesus
requested review from
Aegrah,
Samirbous,
bryans3c,
django-88,
eric-forte-elastic,
imays11 and
w0rk3r
July 20, 2026 20:13
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds a new Azure AKS detection rule to identify non-system identities injecting ephemeral (debug) containers into running pods via the pods/ephemeralcontainers subresource, and updates the non-ECS schema to include additional AKS kube-audit fields referenced by the rule.
Changes:
- Added a new KQL/Kuery rule for AKS ephemeral container injection activity in
azure.platformlogskube-audit logs. - Extended
non-ecs-schema.jsonwith additionalazure.platformlogs.properties.log.*fields used by the rule and investigation fields.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| rules/integrations/azure/execution_azure_aks_ephemeral_container_added.toml | New production rule + investigation guide for detecting AKS ephemeral container injection via kube-audit logs. |
| detection_rules/etc/non-ecs-schema.json | Adds schema entries for additional azure.platformlogs kube-audit fields needed by the new rule. |
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request
Issue link(s):
Summary - What I changed
Detects an identity injecting an ephemeral (debug) container into a running AKS (Azure Kubernetes Service) pod via the pods/ephemeralcontainers subresource, excluding known AKS control-plane and platform identities. Ephemeral containers share the target pod's namespaces and give stealthy interactive access to its processes and mounted secrets without creating a new pod. Coverage includes workload service accounts (system:serviceaccount:*), so a compromised in-cluster token used to attach a debug container is not excluded.
How To Test
Query can be used in TRADE stack.
Checklist
bug,enhancement,schema,maintenance,Rule: New,Rule: Deprecation,Rule: Tuning,Hunt: New, orHunt: Tuningso guidelines can be generatedmeta:rapid-mergelabel if planning to merge within 24 hoursContributor checklist