Detection rules › Sigma

Kubernetes Secrets Modified or Deleted

Status
test
Severity
medium
Log source
product kubernetes, service audit
Author
kelnage
Source
github.com/SigmaHQ/sigma

Detects when Kubernetes Secrets are Modified or Deleted.

MITRE ATT&CK coverage

TacticTechniques
Credential AccessNo specific technique

Event coverage

Rules detecting the same action

Other rules on this platform that filter on the same API call or operation.

Rule body yaml

title: Kubernetes Secrets Modified or Deleted
id: 58d31a75-a4f8-4c40-985b-373d58162ca2
related:
    - id: 2f0bae2d-bf20-4465-be86-1311addebaa3
      type: similar
status: test
description: |
    Detects when Kubernetes Secrets are Modified or Deleted.
references:
    - https://kubernetes.io/docs/reference/config-api/apiserver-audit.v1/
    - https://commandk.dev/blog/guide-to-audit-k8s-secrets-for-compliance/
author: kelnage
date: 2024-07-11
tags:
    - attack.credential-access
logsource:
    product: kubernetes
    service: audit
detection:
    selection:
        objectRef.resource: 'secrets'
        verb:
            - 'create'
            - 'delete'
            - 'patch'
            - 'replace'
            - 'update'
    condition: selection
falsepositives:
    - Secrets being modified or deleted may be performed by a system administrator.
    - Automated processes may need to take these actions and may need to be filtered.
level: medium

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    objectRef.resource: 'secrets'
    verb:
        - 'create'
        - 'delete'
        - 'patch'
        - 'replace'
        - 'update'

Indicators

Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.

FieldKindValues
objectRef.resourceeq
  • secrets
verbeq
  • create
  • delete
  • patch
  • replace
  • update