dt-sec-insights

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Security Insights Skill

安全洞察技能

Query and analyze Dynatrace security data in
security.events
using DQL. Events come from Dynatrace-native sources (RVA, RAP, Automated Detections, SPM) or external products ingested via integrations (AWS Security Hub, Amazon GuardDuty, GitHub Advanced Security, Snyk, Qualys, Tenable, and more).
使用DQL查询并分析
security.events
中的Dynatrace安全数据。事件来源于Dynatrace原生数据源(RVA、RAP、自动化检测、SPM)或通过集成接入的外部产品(AWS Security Hub、Amazon GuardDuty、GitHub Advanced Security、Snyk、Qualys、Tenable等)。

What This Skill Covers

本技能覆盖范围

  • Vulnerability management — open CVEs on running code from DT-native RVA (risk-ranked with Dynatrace Security Score and the four-dimension runtime assessment: vulnerable-function-in-use, public network exposure, reachable data assets, public exploit available) plus external SCA / SAST / image scanners.
  • Compliance posture — DT-native KSPM (Kubernetes-only: CIS, DORA, NIST, STIG) plus CSPM/VSPM and external compliance/posture providers.
  • Runtime attacks and threats — DT-native detections (RAP runtime attacks, Automated Detections rules) plus external detection providers.
  • Threat intelligence — external threat-intelligence reports (AlienVault OTX pulses, CrowdStrike Falcon Intelligence) with actor / campaign / targeting context and indicators of compromise (IOCs); correlate reported IOCs / CVEs / techniques against your monitored environment. These are threat intel about the wild — not findings on your entities — and are queried separately.
  • Scan coverage analysis — covered vs. not-covered k8s workloads/hosts/processes, by Dynatrace scanning feature (
    Library Vulnerability Analytics
    ,
    Operating System Vulnerability Analytics
    ,
    Code-level Vulnerability Analytics
    ) or by external product.
  • Entity enrichment — map external findings to Dynatrace runtime entities (hosts, K8s workloads, cloud resources) via Smartscape.
  • Dashboards / KPIs — tiles, top-N tables, trend charts, coverage donuts.
  • 漏洞管理 — 来自DT原生RVA的运行代码中的未修复CVE(通过Dynatrace安全评分及四维运行时评估进行风险排序:易受攻击函数是否在使用、公网暴露情况、可达数据资产、是否存在公开利用方式),以及外部SCA/SAST/镜像扫描器的检测结果。
  • 合规态势 — DT原生KSPM(仅针对Kubernetes:支持CIS、DORA、NIST、STIG标准),以及CSPM/VSPM和外部合规/态势管理工具的检测结果。
  • 运行时攻击与威胁 — DT原生检测(RAP运行时攻击、自动化检测规则),以及外部检测工具的结果。
  • 威胁情报 — 外部威胁情报报告(AlienVault OTX脉冲、CrowdStrike Falcon Intelligence),包含攻击者/攻击活动/目标上下文及入侵指标(IOC);将报告的IOC/CVE/攻击技术与您的监控环境进行关联。这些是针对外部环境的威胁情报,并非您环境内实体的检测结果,需单独查询。
  • 扫描覆盖分析 — 已覆盖与未覆盖的K8s工作负载/主机/进程,按Dynatrace扫描功能(
    Library Vulnerability Analytics
    Operating System Vulnerability Analytics
    Code-level Vulnerability Analytics
    )或外部产品统计。
  • 实体关联 — 通过Smartscape将外部检测结果映射到Dynatrace运行时实体(主机、K8s工作负载、云资源)。
  • 仪表盘/KPI — 指标卡片、Top-N表格、趋势图表、覆盖占比环形图。

When to Use This Skill

适用场景

Must-first routing rule: identify user intent first, then load the matching primary reference from Quick Start: Find Your Use Case before generating DQL.
Identify the intent, then load the matching reference before writing DQL.
Cross-cutting (any / all finding types)
Intent / exampleReferencePattern
Security posture / overview across all products (incl. DT-native)
all-security-events.md
§ Broad-Question Query Decomposition
3-stream decomposition (external+detections
24h
/ RVA
30m
/ KSPM
1h
), merged; lead the count summary with KSPM compliance — CIS first (other standards + RVA + detections beneath) →
compliance.md
§ CIS-Primary Standard Summary
Findings on a specific entity — direct or related (blast radius)dt-sec-contextualization
entity-enrichment.md
·
all-security-events.md
Broad entity-security questions must decompose: external
*_FINDING
by
dt.smartscape_source.id
/
dt.entity.*
/
k8s.*
(
24h
) + DT RVA entity scope (
30m
) + DT SPM entity scope (
1h
)
Findings from a specific provider
all-security-events.md
§ Scoping to a Specific Provider
contains(lower(event.provider | product.vendor), "<p>")
Which third-party / external tools are sending data (DT-native excluded)
all-security-events.md
§ Which external integrations are active
external-only enumeration (single query)
Which security products are integrated? / what security data do we have? (default: include DT-native RVA + KSPM)
all-security-events.md
§ Broad-Question Query Decomposition
3-stream decomposition; never a single wide
security.events
scan
Which products cover a specific entitydt-sec-contextualization
correlation-and-coverage.md
·
all-security-events.md
summarize by
product.*
; findings-vs-scans split
Routing tie-breaker: an unqualified "which security products are integrated? / are we covered? / what do we have?" defaults to the DT-inclusive 3-stream decomposition (it must query DT vulnerabilities and compliance). Take the external-only single query only when the user explicitly scopes to external / third-party tools ("which external tools are sending us data?").
Vulnerabilities (CVE management)
Intent / exampleReferencePattern
Counts / severity ("how many critical?", by risk + mute status)
vulnerabilities-dynatrace.md
RVA snapshot Steps 1–3
Most vulnerable components / hosts / workloads (rankings)
vulnerabilities-entities.md
Steps 1–3 +
expand
typed
related_entities.<group>.ids
smartscapeNodes
lookup on
id_classic
— ⚠
k8s.*
/
dt.entity.*
are null on RVA events
CVE / library lookup; "am I vulnerable to log4shell?"
vulnerabilities-dynatrace.md
§ Entity Scoping
Step 2 CVE/component filter; scope RVA to a known entity
Blast radius — which entities are affected by CVE X
vulnerabilities-entities.md
related_entities.*
indirect-relation expand
Lifecycle — new / resolved / open-duration / MTTR
vulnerabilities-dynatrace.md
post-derive
resolution.change_date
; MTTR via change-events-only snippet (§ Resolution time)
Runtime advanced — function-in-use, exposure, exploit, data-assets
vulnerabilities-dynatrace.md
Davis-assessment
fieldsAdd
(Step 3)
External scanner vulns — containers / artifacts / components
vulnerabilities-external.md
VULNERABILITY_FINDING
+ external routing
Verify external vulnerability findings with RVA
vulnerabilities-external.md
§ Verify external vulnerability findings with RVA · dt-sec-contextualization
entity-enrichment.md
First match the same vulnerability by
vulnerability.references.cve
; then prove runtime relatedness via direct
dt.smartscape*
IDs, container-image digest → running
CONTAINER
, or host
host.ip
→ Smartscape HOST
"Newly reported this period and not in the previous period" (external)
vulnerabilities-external.md
·
common-patterns.md
§ 18
prior-period anti-join (
isNull(right.*)
) — a
finding.time.created
filter is NOT equivalent
AI/LLM/GenAI workload vulnerabilities; "which AI services have vulnerabilities?"
vulnerabilities-dynatrace-advanced.md
§ AI-workload vulnerabilities
DT findings + GENAI scope (
30m
, dedup
finding.id
)
New AI-workload vulnerabilities this period
vulnerabilities-dynatrace-advanced.md
§ UC-AI2
prior-window anti-join on
{genai_service.id, vulnerability.id}
Detections (threats & attacks)
Intent / exampleReferencePattern
Severity / time-window overview (DT + external)
detections.md
·
all-security-events.md
DETECTION_FINDING
summary; default unqualified timeframe is
2h
, widen to
24h
only if empty
By attack type (
SQL injection
, crypto-mining, …)
detections.md
finding.type
substring match
Attacker IPs / campaigns
detections.md
expand actor.ips
+
ip()
MITRE technique / sub-technique
detections.md
threat.attack.*
arrays
RAP-only / Automated-Detections-only
detections.md
§ Provider Routing
product.name=="Runtime Application Protection"
/
event.provider=="Dynatrace Automated Detections"
Map detections to entities; repeated firing
detections.md
· dt-sec-contextualization
entity-enrichment.md
object.id
grouping / enrichment
A specific external provider
all-security-events.md
§ Scoping to a Specific Provider
provider
contains
idiom
MITRE routing tie-breaker: a MITRE ATT&CK question routes by intent. "Which techniques did we detect / observe (on our entities)?" →
detections.md
(
DETECTION_FINDING
). "Which techniques are reported in threat intel / campaigns in the wild?" →
threat-intelligence.md
(
THREAT_REPORT
). Don't merge the two — a report tagged T1059 is not evidence T1059 occurred in your environment.
Threat intelligence (external reports & IOCs)
Intent / exampleReferencePattern
Show / list / count threat intelligence reports; reports by provider, actor, malware family, targeted country/industry, TLP, report type
threat-intelligence.md
THREAT_REPORT
+
dedup {threat.report.id}
(SD guard first); never the four-key finding summarize
Top IOCs (CVEs / IPs / domains / URLs / emails / hashes) or MITRE techniques across reports
threat-intelligence.md
§ IOC extraction
dedup
expand
observable →
countDistinctExact(threat.report.id)
Am I exposed to report X / are these IOCs in my environment? (threat-exposure)
threat-intelligence.md
§ Threat-Exposure Correlation
join
report IOCs/CVEs/techniques to
VULNERABILITY_FINDING
/RVA/
DETECTION_FINDING
; logs/spans IoC hunt →
dt-sec-ioc-hunting
Compliance (policy violations & benchmarks)
Intent / exampleReferencePattern
Pass-rate / posture (CIS / DORA / NIST / STIG)
compliance.md
Load
compliance.md
first
— SPM Steps 1–2 + passRate
Critical misconfigurations
compliance.md
Load
compliance.md
first
— Steps 1–2 + severity filter
Compliance / misconfigurations on a specific entity
compliance.md
§ Entity Security-Tab View (entity-scoped
${entityIdsOrNames}
filter) ·
entity-enrichment.md
Mirror the entity Security tab (CIS default, failed-only): Table 1 DT CIS failed rules → Table 2 other DT standards (overlap caveat) → Table 3 external misconfigs. Broad posture/count questions instead use § CIS-Primary Standard Summary (scorecard).
Map control/standard → entities; per-namespace
compliance.md
entity scoping via
compliance.standard.short_name
/
compliance.rule.id
(⚠ never
metadata_json
)
Cloud / non-K8s (PCI/ISO/HIPAA/GDPR; AWS/Azure/GCP)
compliance.md
§ External
external taxonomy (
compliance.standards
/
policy
/
control
)
External violations grouped by standard / framework
compliance.md
§ External
compliance.standards
is an array
expand
it before
summarize
Config drift / newly failing rules vs previous week (DT)
compliance.md
§ Week-over-Week Config Drift
prior-period anti-join — a wide fetch window is NOT a substitute
External compliance findings new this period, absent in prior
compliance.md
§ External
prior-period anti-join (same rule as drift)
KSPM (Kubernetes-only, DT-native)
compliance.md
product.name=="Security Posture Management"
Coverage, enrichment & dashboards
Intent / exampleReferencePattern
Coverage / "covered vs not covered" / coverage gaps — hosts / processes / workloads
coverage-and-dashboards.md
(counting logic) · dt-sec-contextualization
correlation-and-coverage.md
(match recipes)
MUST start from
smartscapeNodes
+
lookup
scan events
— summarizing scan events alone has no denominator and cannot answer a coverage question
Specific entity coverage by a DT capability (RVA, SPM, RAP, other DT-native)
coverage-and-dashboards.md
If no relevant findings or scan/completion events exist for that entity in the capability's operational window, answer not covered — capability is likely not enabled or not configured for that entity
Map external findings → workloads / hosts / clouddt-sec-contextualization
entity-enrichment.md
3-way match (K8s) / host-by-IP / Path-1 (cloud) — ⚠ always join to Smartscape; never group findings by raw
object.name
/
k8s.namespace.name
/
host.name
/ cloud resource IDs alone
One-row-per-entity risk summarydt-sec-contextualization
entity-enrichment.md
·
coverage-and-dashboards.md
RVA + external merge
Dashboards — KPI tiles, top-N, trends, donuts
coverage-and-dashboards.md
makeTimeseries
, summarization recipes
Don't use for:
  • Dynatrace-detected problems →
    dt-obs-problems
  • Application/infrastructure logs →
    dt-obs-logs
  • Distributed tracing →
    dt-obs-tracing
  • Service performance/RED metrics →
    dt-obs-services
首要路由规则: 先识别用户意图,再从快速入门:找到您的使用场景中加载匹配的主参考文档,之后再生成DQL。
先识别意图,再加载匹配的参考文档,然后编写DQL。
跨场景(所有检测类型)
意图/示例参考文档模式
全产品(含DT原生)的安全态势/概览
all-security-events.md
§ 宽泛问题查询分解
三流分解(外部+检测结果
24h
/ RVA
30m
/ KSPM
1h
)并合并;合规统计以KSPM合规为先——优先展示CIS标准(其他标准+RVA+检测结果置于下方)→
compliance.md
§ CIS主标准汇总
特定实体的检测结果——直接或关联影响(爆炸半径)dt-sec-contextualization
entity-enrichment.md
·
all-security-events.md
宽泛的实体安全问题必须分解:外部
*_FINDING
dt.smartscape_source.id
/
dt.entity.*
/
k8s.*
筛选(
24h
) + DT RVA实体范围(
30m
) + DT SPM实体范围(
1h
特定供应商的检测结果
all-security-events.md
§ 限定到特定供应商
contains(lower(event.provider | product.vendor), "<p>")
哪些第三方/外部工具正在发送数据(排除DT原生)
all-security-events.md
§ 哪些外部集成处于活跃状态
仅外部工具的枚举查询(单查询)
已集成哪些安全产品?/ 我们拥有哪些安全数据?(默认:包含DT原生RVA + KSPM)
all-security-events.md
§ 宽泛问题查询分解
三流分解;切勿直接扫描整个
security.events
哪些产品覆盖了特定实体dt-sec-contextualization
correlation-and-coverage.md
·
all-security-events.md
product.*
汇总;区分检测结果与扫描记录
路由决胜规则: 未明确限定的“已集成哪些安全产品?/ 我们是否被覆盖?/ 我们有什么?”默认采用包含DT的三流分解(必须查询DT漏洞与合规数据)。仅当用户明确限定为外部/第三方工具时(“哪些外部工具正在向我们发送数据?”),才采用仅外部工具的单查询。
漏洞(CVE管理)
意图/示例参考文档模式
数量/严重程度(“有多少严重漏洞?”,按风险+静音状态统计)
vulnerabilities-dynatrace.md
RVA快照步骤1–3
最易受攻击的组件/主机/工作负载(排名)
vulnerabilities-entities.md
步骤1–3 +
expand
类型化
related_entities.<group>.ids
→ 在
smartscapeNodes
中按
id_classic
查找 — ⚠ RVA事件中的
k8s.*
/
dt.entity.*
为空
CVE/库查询;“我们是否受Log4Shell影响?”
vulnerabilities-dynatrace.md
§ 实体范围限定
步骤2的CVE/组件筛选;将RVA范围限定到已知实体
爆炸半径——哪些实体受CVE X影响
vulnerabilities-entities.md
related_entities.*
间接关系展开
生命周期——新增/已修复/未修复时长/平均修复时间(MTTR)
vulnerabilities-dynatrace.md
派生
resolution.change_date
字段;通过仅变更事件片段计算MTTR(§ 修复时间)
运行时高级分析——函数使用情况、暴露面、可利用性、数据资产
vulnerabilities-dynatrace.md
Davis评估
fieldsAdd
(步骤3)
外部扫描器漏洞——容器/制品/组件
vulnerabilities-external.md
VULNERABILITY_FINDING
+ 外部路由
使用RVA验证外部漏洞检测结果
vulnerabilities-external.md
§ 使用RVA验证外部漏洞检测结果 · dt-sec-contextualization
entity-enrichment.md
首先通过
vulnerability.references.cve
匹配相同漏洞;然后通过直接
dt.smartscape*
ID、容器镜像摘要→运行中
CONTAINER
或主机
host.ip
→Smartscape HOST证明运行时关联性
“本期新增且上期未出现”的漏洞(外部)
vulnerabilities-external.md
·
common-patterns.md
§ 18
上期反连接
isNull(right.*)
)——仅筛选
finding.time.created
并不等价
AI/LLM/GenAI工作负载漏洞;“哪些AI服务存在漏洞?”
vulnerabilities-dynatrace-advanced.md
§ AI工作负载漏洞
DT检测结果 + GENAI范围(
30m
,按
finding.id
去重)
本期新增的AI工作负载漏洞
vulnerabilities-dynatrace-advanced.md
§ UC-AI2
{genai_service.id, vulnerability.id}
对上一窗口进行反连接
检测结果(威胁与攻击)
意图/示例参考文档模式
严重程度/时间窗口概览(DT + 外部)
detections.md
·
all-security-events.md
DETECTION_FINDING
汇总;默认未指定时间范围为
2h
,仅当结果为空时扩大到
24h
按攻击类型(
SQL注入
、加密货币挖矿等)
detections.md
finding.type
子字符串匹配
攻击者IP/攻击活动
detections.md
expand actor.ips
+
ip()
MITRE技术/子技术
detections.md
threat.attack.*
数组
仅RAP/仅自动化检测
detections.md
§ 供应商路由
product.name=="Runtime Application Protection"
/
event.provider=="Dynatrace Automated Detections"
将检测结果映射到实体;重复触发
detections.md
· dt-sec-contextualization
entity-enrichment.md
object.id
分组/关联
特定外部供应商
all-security-events.md
§ 限定到特定供应商
供应商
contains
语法
MITRE路由决胜规则: MITRE ATT&CK相关问题按意图路由。“我们检测/观察到哪些技术(在我们的实体上)?”→
detections.md
DETECTION_FINDING
)。“外部威胁情报/攻击活动中报告了哪些技术?”→
threat-intelligence.md
THREAT_REPORT
)。切勿合并两者——标记为T1059的报告并不意味着您的环境中发生了T1059攻击。
威胁情报(外部报告与IOC)
意图/示例参考文档模式
展示/列出/统计威胁情报报告;按供应商、攻击者、恶意软件家族、目标国家/行业、TLP、报告类型统计
threat-intelligence.md
THREAT_REPORT
+
dedup {threat.report.id}
(先去重);切勿使用四键检测结果汇总
报告中排名靠前的IOC(CVE/IP/域名/URL/邮箱/哈希)或MITRE技术
threat-intelligence.md
§ IOC提取
dedup
expand
可观测对象 →
countDistinctExact(threat.report.id)
我们是否暴露于报告X?/这些IOC是否存在于我们的环境中?(威胁暴露)
threat-intelligence.md
§ 威胁暴露关联
将报告中的IOC/CVE/技术与
VULNERABILITY_FINDING
/RVA/
DETECTION_FINDING
进行连接;日志/链路追踪IOC排查→
dt-sec-ioc-hunting
合规(策略违规与基准)
意图/示例参考文档模式
通过率/态势(CIS/DORA/NIST/STIG)
compliance.md
先加载
compliance.md
——SPM步骤1–2 + passRate
严重配置错误
compliance.md
先加载
compliance.md
——步骤1–2 + 严重程度筛选
特定实体的合规/配置错误
compliance.md
§ 实体安全标签页视图(实体范围筛选
${entityIdsOrNames}
)·
entity-enrichment.md
镜像实体安全标签页(默认CIS标准,仅显示失败项):表格1 DT CIS失败规则 → 表格2 其他DT标准(注意重叠) → 表格3 外部配置错误。宽泛的态势/数量问题则使用§ CIS主标准汇总(计分卡)。
将控制项/标准映射到实体;按命名空间统计
compliance.md
通过
compliance.standard.short_name
/
compliance.rule.id
限定实体范围(⚠ 切勿使用
metadata_json
云/非K8s环境(PCI/ISO/HIPAA/GDPR;AWS/Azure/GCP)
compliance.md
§ 外部
外部分类(
compliance.standards
/
policy
/
control
按标准/框架分组的外部违规项
compliance.md
§ 外部
compliance.standards
数组——汇总前需
expand
配置漂移/本周新增失败规则与上周对比(DT)
compliance.md
§ 周环比配置漂移
上期反连接——扩大查询窗口无法替代此方法
本期新增且上期未出现的外部合规检测结果
compliance.md
§ 外部
上期反连接(与配置漂移规则相同)
KSPM(仅Kubernetes,DT原生)
compliance.md
product.name=="Security Posture Management"
覆盖范围、关联与仪表盘
意图/示例参考文档模式
覆盖范围/“已覆盖vs未覆盖”/覆盖缺口——主机/进程/工作负载
coverage-and-dashboards.md
(统计逻辑)· dt-sec-contextualization
correlation-and-coverage.md
(匹配方案)
必须从
smartscapeNodes
+
lookup
扫描事件开始
——仅汇总扫描事件没有分母,无法回答覆盖范围问题
特定实体被DT能力(RVA、SPM、RAP、其他DT原生能力)覆盖情况
coverage-and-dashboards.md
如果该实体在能力的运行窗口内没有相关检测结果或扫描/完成事件,则判定为未覆盖——该能力可能未启用或未配置为监控该实体
将外部检测结果映射到工作负载/主机/云资源dt-sec-contextualization
entity-enrichment.md
三方匹配(K8s)/按IP匹配主机/路径1(云)——⚠ 始终与Smartscape连接;切勿仅按原始
object.name
/
k8s.namespace.name
/
host.name
/云资源ID分组检测结果
每行一个实体的风险汇总dt-sec-contextualization
entity-enrichment.md
·
coverage-and-dashboards.md
RVA + 外部结果合并
仪表盘——KPI卡片、Top-N、趋势、环形图
coverage-and-dashboards.md
makeTimeseries
、汇总方案
请勿用于:
  • Dynatrace检测到的问题 →
    dt-obs-problems
  • 应用/基础设施日志 →
    dt-obs-logs
  • 分布式追踪 →
    dt-obs-tracing
  • 服务性能/RED指标 →
    dt-obs-services

Introduction to AppSec Data

AppSec数据介绍

All security events are stored in
security.events
and are categorized by
event.type
:
  • RVA vulnerabilities
    VULNERABILITY_STATE_REPORT_EVENT
    (15-minute snapshots per entity)
  • KSPM compliance
    COMPLIANCE_FINDING
    (per
    (rule, K8s object)
    , joined with
    COMPLIANCE_SCAN_COMPLETED
    on
    scan.id
    for latest-scan dedup)
  • External compliance (CSPM / VSPM / external posture tools)
    COMPLIANCE_FINDING
    with the external taxonomy (
    compliance.standards
    /
    compliance.policy
    /
    compliance.control
    );
    compliance.rule.*
    typically null
  • Detections
    DETECTION_FINDING
    (RAP via
    product.name == "Runtime Application Protection"
    ),
    SECURITY_EVENT
    (RAP events in some tenants), Automated Detections via
    event.provider == "Dynatrace Automated Detections"
    , external security tools; plus
    DETECTION_EXECUTION_SUMMARY
    for per-rule-run audit (Automated Detections only)
  • Scan coverage
    VULNERABILITY_SCAN
    ,
    COMPLIANCE_SCAN
  • Threat intelligence
    THREAT_REPORT
    (external TI platforms: AlienVault OTX pulses, CrowdStrike Falcon Intelligence). A separate class of data — not a finding: no
    finding.*
    /
    object.*
    /
    dt.security.risk.level
    , no affected entity, no scan cycle. Never folded into the cross-provider finding summary or the posture-overview decomposition — queried on its own via threat-intelligence.md. Dedup by
    threat.report.id
    .
Full taxonomy and field reference → data-model.md
所有安全事件都存储在**
security.events
**中,并按
event.type
分类:
  • RVA漏洞
    VULNERABILITY_STATE_REPORT_EVENT
    (每个实体每15分钟生成快照)
  • KSPM合规
    COMPLIANCE_FINDING
    (按
    (rule, K8s object)
    生成,通过
    scan.id
    COMPLIANCE_SCAN_COMPLETED
    连接以去重获取最新扫描结果)
  • 外部合规(CSPM/VSPM/外部态势工具)
    COMPLIANCE_FINDING
    ,带有外部分类(
    compliance.standards
    /
    compliance.policy
    /
    compliance.control
    );
    compliance.rule.*
    通常为空
  • 检测结果
    DETECTION_FINDING
    (RAP通过
    product.name == "Runtime Application Protection"
    识别)、
    SECURITY_EVENT
    (部分租户中的RAP事件)、通过
    event.provider == "Dynatrace Automated Detections"
    识别的自动化检测、外部安全工具;以及
    DETECTION_EXECUTION_SUMMARY
    (仅用于自动化检测的每规则运行审计)
  • 扫描覆盖
    VULNERABILITY_SCAN
    COMPLIANCE_SCAN
  • 威胁情报
    THREAT_REPORT
    (外部TI平台:AlienVault OTX脉冲、CrowdStrike Falcon Intelligence)。这是一类独立的数据——并非检测结果:没有
    finding.*
    /
    object.*
    /
    dt.security.risk.level
    字段,没有受影响实体,没有扫描周期。切勿将其纳入跨供应商检测结果汇总或态势概览分解——需通过threat-intelligence.md单独查询。按
    threat.report.id
    去重。
完整分类与字段参考 → data-model.md

Critical Constraint: Snapshot Windows

关键约束:快照窗口

DT RVA and KSPM are snapshot tools, not event streams. The minimum query window required for each pipeline:
  • RVA:
    30m
    fixed window (captures latest 15-min cycle); if a 30m snapshot is empty or clearly stale, use the controlled 24h latest-known-state fallback in vulnerabilities-dynatrace.md
  • KSPM:
    1h
    fixed window (needs latest
    COMPLIANCE_SCAN_COMPLETED
    marker for the inner-join)
  • External findings (incl. CSPM/VSPM):
    2h–24h+
    (no snapshot semantics — these are one-shot events)
Widening these windows does NOT look back further — they only capture the latest report/scan cycle. For historical trends, use
makeTimeseries
over longer windows.
DT-generated
VULNERABILITY_FINDING
vs. RVA state reports.
Dynatrace-generated
VULNERABILITY_FINDING
queries (e.g. AI-workload scoping in vulnerabilities-dynatrace-advanced.md § AI-workload vulnerabilities) also use a
30m
window, but dedup on
finding.id
because DT findings are re-emitted on every scan run (~15 min) — distinct from the RVA state-report
30m
window, which dedups on
{vulnerability.display_id, affected_entity.id}
. Do not mix the two dedup grains.
DT RVA和KSPM是快照工具,而非事件流。每个管道所需的最小查询窗口:
  • RVA:固定
    30m
    窗口(捕获最新15分钟周期的快照);如果30m快照为空或明显过时,使用vulnerabilities-dynatrace.md中受控的24h最新已知状态回退方案
  • KSPM:固定
    1h
    窗口(需要最新的
    COMPLIANCE_SCAN_COMPLETED
    标记用于内连接)
  • 外部检测结果(含CSPM/VSPM)
    2h–24h+
    (无快照语义——这些是一次性事件)
扩大这些窗口不会回溯更早的数据——仅会捕获最新的报告/扫描周期。如需历史趋势,在更长窗口上使用
makeTimeseries
DT生成的
VULNERABILITY_FINDING
与RVA状态报告。
Dynatrace生成的
VULNERABILITY_FINDING
查询(例如vulnerabilities-dynatrace-advanced.md § AI-workload vulnerabilities中的AI工作负载范围限定)也使用
30m
窗口,但需按**
finding.id
去重,因为DT检测结果会在每次扫描运行(约15分钟)时重新生成——这与RVA状态报告的
30m
窗口不同,后者按
{vulnerability.display_id, affected_entity.id}
**去重。请勿混淆两种去重粒度。

Default Time Ranges in the Dynatrace Apps

Dynatrace应用中的默认时间范围

The UI apps show pre-set defaults in their time picker. When a user references "the app's view" without giving an explicit window, match these to align query results with what the user sees in the UI:
AppDefault time picker
Vulnerabilities app30 minutes
Threats & Exploits app2 hours
Security Posture Management app2 hours
These app defaults are broader than the minimum snapshot windows above (e.g. SPM app = 2h vs. KSPM pipeline minimum = 1h). The minimum window is what the inner-join / latest-cycle dedup needs to function; the app default is what the user sees on first load. Use the minimum window when generating canonical pipeline DQL; use the app default when the user asks "what does the SPM app show me right now?" or builds a dashboard tile intended to match the app view.
See vulnerabilities-dynatrace.md § Snapshot vs. History for details.
UI应用的时间选择器有预设默认值。当用户提及“应用视图”但未指定明确窗口时,匹配这些默认值以确保查询结果与用户在UI中看到的内容一致:
应用默认时间选择器
漏洞应用30分钟
威胁与利用应用2小时
安全态势管理应用2小时
这些应用默认值宽于上述最小快照窗口(例如SPM应用=2h vs KSPM管道最小=1h)。最小窗口是内连接/最新周期去重所需的窗口;应用默认值是用户首次加载时看到的窗口。生成标准管道DQL时使用最小窗口;当用户询问“SPM应用现在显示什么?”或构建与应用视图匹配的仪表盘卡片时,使用应用默认值
详情请见vulnerabilities-dynatrace.md § 快照 vs 历史

How This Skill Is Organized

本技能的组织结构

The skill is split into two parts for scalability:
  1. SKILL.md (this file) — Entry point, quick lookup, routing to the right reference
  2. references/ — Detailed guidance by capability or domain:
    • data-model.md — Reference for
      fetch security.events
      — event types, providers, fields, entity scoping.
    • common-patterns.md — Cross-cutting patterns, common mistakes to avoid, and query troubleshooting reference.
  • vulnerabilities-dynatrace.md — Dynatrace Runtime Vulnerability Analytics (RVA): snapshot pipeline, counts, lifecycle, runtime assessment, CLV, tracking, mute, and entity scoping.
  • vulnerabilities-dynatrace-advanced.md — Advanced DT vulnerability guidance: best practices and AI-workload (
    VULNERABILITY_FINDING
    ) query workflows.
  • vulnerabilities-external.md — External SCA / SAST / image-scanner vulnerability findings (
    VULNERABILITY_FINDING
    ).
  • vulnerabilities-entities.md — DT RVA entity rankings: "most vulnerable hosts / K8s workloads / components" + CVE blast radius.
  • compliance.md — Dynatrace Security Posture Management (SPM / XSPM) compliance findings and external provider compliance findings.
  • detections.md — Runtime Application Protection (RAP) detections, Automated Detection rules, and external provider detections.
  • threat-intelligence.md — External threat-intelligence reports (
    THREAT_REPORT
    ): AlienVault OTX / CrowdStrike Falcon Intelligence, IOC extraction, and threat-exposure correlation. Not findings — queried separately.
  • all-security-events.md — Cross-provider queries, double-counting guard, unified summaries
  • coverage-and-dashboards.md — Entity coverage counting logic (
    smartscapeNodes
    denominator, covered vs. not-covered) and dashboard patterns (KPI tiles, top-N, trend charts, coverage donuts).
  • entity-enrichment — Moved to dt-sec-contextualization
    references/entity-enrichment.md
    (3-way match / host-by-IP / cloud). Load
    dt-sec-contextualization
    for any entity-mapping question.
为了可扩展性,本技能分为两部分:
  1. SKILL.md(本文档)——入口点、快速查询、路由到正确的参考文档
  2. references/ — 按能力或领域划分的详细指南:
    • data-model.md
      fetch security.events
      参考文档——事件类型、供应商、字段、实体范围限定。
    • common-patterns.md — 跨场景模式、常见错误规避、查询故障排除参考。
  • vulnerabilities-dynatrace.md — Dynatrace Runtime Vulnerability Analytics(RVA):快照管道、数量统计、生命周期、运行时评估、CLV、追踪、静音、实体范围限定。
  • vulnerabilities-dynatrace-advanced.md — DT漏洞高级指南:最佳实践与AI工作负载(
    VULNERABILITY_FINDING
    )查询流程。
  • vulnerabilities-external.md — 外部SCA/SAST/镜像扫描器漏洞检测结果(
    VULNERABILITY_FINDING
    )。
  • vulnerabilities-entities.md — DT RVA实体排名:“最易受攻击的主机/K8s工作负载/组件” + CVE爆炸半径。
  • compliance.md — Dynatrace Security Posture Management(SPM/XSPM)合规检测结果与外部供应商合规检测结果。
  • detections.md — Runtime Application Protection(RAP)检测、自动化检测规则、外部供应商检测结果。
  • threat-intelligence.md — 外部威胁情报报告(
    THREAT_REPORT
    ):AlienVault OTX/CrowdStrike Falcon Intelligence、IOC提取、威胁暴露关联。并非检测结果——需单独查询。
  • all-security-events.md — 跨供应商查询、重复计数防护、统一汇总
  • coverage-and-dashboards.md — 实体覆盖统计逻辑(
    smartscapeNodes
    分母、已覆盖vs未覆盖)与仪表盘模式(KPI卡片、Top-N、趋势图表、覆盖占比环形图)。
  • entity-enrichment — 已移至dt-sec-contextualization
    references/entity-enrichment.md
    (三方匹配/按IP匹配主机/云)。任何实体映射问题都需加载
    dt-sec-contextualization

Universal Best Practices

通用最佳实践

  1. Always load dt-dql-essentials first — DQL syntax and function names differ from SQL. Confirm all functions in
    dt-dql-essentials
    before generating queries.
  2. Ground every query in the routed reference's canonical template — do not improvise DQL. Identify intent, load the matching reference (per When to Use), and build from its canonical pipeline / named building block. Do not invent field names, enum values, join syntax, or pipeline shape from SQL habits. Deviate from a template only with syntax explicitly shown in a skill example or validated in
    dt-dql-essentials
    . If no template covers the request, say so and adapt the closest one — never fabricate fields or values.
  3. No
    dt.system.bucket
    filters
    — security event data may live in any bucket; filtering by bucket risks hiding findings.
  4. Use the correct provenance field for the family — RVA uses
    event.provider == "Dynatrace"
    , SPM/detections use
    product.vendor == "Dynatrace"
    . See data-model.md § Provider Taxonomy.
  5. Always include an explicit
    from:
    clause — use the correct window for the query class:
    Query classDefault windowNotes
    DT RVA snapshots
    30m
    fixed
    Captures latest 15-min state-report cycle — do not widen
    DT KSPM snapshots
    1h
    fixed
    Aligned with scan-completion cycle inner-join — do not widen
| RAP / external detection retrieval or current summary |
2h
first attempt | Matches Threats & Exploits app default. Widen to
24h
only if zero rows returned or if the user explicitly asks for a longer window (see detections.md § Widen-on-empty fallback) | | Cross-provider summary (aggregated) |
24h
| Summaries aggregate over time; start broad |
Omitting
from:
falls back to a default window that doesn't match snapshot semantics and produces drift between query runs. The 30m / 1h windows are not arbitrary — they're tied to the underlying RVA / SPM scan cadence. See common-patterns.md § 7 for the full window reference.
Decompose DT-inclusive broad / posture-overview questions ("which security products are integrated incl. Dynatrace-native?", posture overview, cross-category counts that include DT vulnerabilities/compliance) — never answer with one wide scan over all of
security.events
. Run three separate queries and merge: Stream A external + DT detections (
24h
, double-counting guard), Stream B DT RVA (
30m
), Stream C DT KSPM (
1h
). This keeps the high-cardinality snapshot streams in their tight windows and avoids double-counting. A narrower "which external integrations are sending data?" stays a single external-only query. See all-security-events.md § Broad-Question Query Decomposition. 6. Preserve entity identifiers on raw listings (top / latest / list / show-me — no
summarize
) so users see which entity each finding is on. The namespaces split by family and are not interchangeable: cross-provider
*_FINDING
/ scan events use the generic
dt.smartscape*
/
dt.entity*
/
dt.source*
fields; RVA state/change events leave those null and carry refs in
affected_entity*
/
related_entities*
. Not for pure count / pass-rate summaries. Field lists and wildcard reference → common-patterns.md § 17. 7. Broad entity-security questions require the external stream too. For prompts like "security findings of this host / K8s node / workload / cluster", do not stop after DT RVA and SPM. Also run the external/cross-provider
*_FINDING
stream scoped with the wide entity OR chain (
dt.smartscape_source.id
,
dt.entity.*
,
object.*
, and relevant
k8s.*
fields) in
24h
, then merge with RVA (
30m
) and SPM (
1h
). Treat
dt.source_entity
as a legacy/scan fallback, not a primary cross-provider scoping path. If the external branch returns 0 rows, report "no external findings found" with the scope used. Load dt-sec-contextualization
entity-enrichment.md
for the Smartscape join. See also all-security-events.md. 8. Always bound raw listing and top-N results. If the user asks for "top X", "last X", or "first X", end with
| sort ... | limit X
(after the ranking/sort). If the user asks to list/show findings but does not explicitly ask for all data and the output is not a summary (
summarize
/
makeTimeseries
), add
| limit 50
by default. Do not run unbounded raw projections on security findings. Full rule and exceptions → common-patterns.md § 16. 9. Preserve query shape — do not drop
by:
keys unless the user asks for coarser aggregation.
The canonical cross-provider
summarize
always keys by
{event.provider, product.name, event.type, dt.security.risk.level}
. Dropping any of these silently merges rows from different providers, products, or finding types into a single count and will be penalized by evaluators. Do not replace the four-key grouping with a simpler
by: {dt.security.risk.level}
or
by: {event.type}
unless the user explicitly requests a coarser view. See common-patterns.md § 15.
  1. Compliance status uses
    compliance.result.status.level
    (
    PASSED
    /
    FAILED
    /
    MANUAL
    /
    NOT_RELEVANT
    ) — never
    event.status
    or
    "PASS"
    /
    "FAIL"
    . Pass rate is computed on per-rule verdicts after the latest-scan dedup join
    on: {scan.id}
    . Field terminology, the dedup join, and the pass-rate rollup → compliance.md.
  2. Count distinct identities, not rows, after
    expand
    /
    join
    /
    lookup
    that fan out arrays — use
    countDistinctExact(vulnerability.display_id)
    /
    countDistinctExact(finding.id)
    , or
    dedup
    on identity + group key first. A plain
    count()
    is safe only when the grain entering the
    expand
    is already one row per counted item. Examples and the exception → common-patterns.md § Mistakes #55.
  3. Interpret empty entity-coverage probes as not covered. When validating whether a specific entity is covered by a Dynatrace security capability (RVA, SPM/KSPM, RAP, or another DT-native capability), absence of the relevant findings and scan/completion events means the entity is not covered by that capability. State the likely cause: the capability is not enabled, or it is not configured / deployed to monitor that entity. Do not soften this into "no findings" when the user asked about coverage. Counting logic → coverage-and-dashboards.md; match recipes → dt-sec-contextualization
    correlation-and-coverage.md
    .
  4. Report empty results truthfully — never fabricate numbers. 0 rows means "no matching data," stated with the scope and filters used; never invent plausible values. Before relaxing a filter, apply the family's documented recovery (RVA 30m→24h latest-known-state, detections 2h→24h widen, RVA filters on null
    k8s.*
    /
    dt.entity.*
    /
    dt.smartscape*
    → pivot to
    affected_entity.*
    /
    related_entities.*
    ) and say so explicitly if you adapt. Recovery details → vulnerabilities-dynatrace.md / detections.md.
For domain-specific best practices and the full diagnostic catalog, see the references listed in the "How This Skill Is Organized" section above.
  1. 始终先加载dt-dql-essentials — DQL语法与函数名称与SQL不同。生成查询前,请确认所有函数都在
    dt-dql-essentials
    中存在。
  2. 所有查询都基于路由参考文档的标准模板——切勿自行编写DQL。 识别意图,加载匹配的参考文档(按适用场景),并基于其标准管道/命名构建块进行开发。切勿根据SQL习惯自行发明字段名、枚举值、连接语法或管道结构。仅当技能示例中明确展示或
    dt-dql-essentials
    中验证过的语法,才可偏离模板。如果没有模板覆盖请求,请说明并适配最接近的模板——切勿编造字段或值。
  3. 不要使用
    dt.system.bucket
    筛选器
    — 安全事件数据可能存储在任何存储桶中;按存储桶筛选可能会隐藏检测结果。
  4. 针对不同类型使用正确的来源字段 — RVA使用
    event.provider == "Dynatrace"
    ,SPM/检测结果使用
    product.vendor == "Dynatrace"
    。详情请见data-model.md § 供应商分类
  5. 始终包含明确的
    from:
    子句——为查询类型使用正确的窗口:
    查询类型默认窗口说明
    DT RVA快照固定
    30m
    捕获最新15分钟状态报告周期——请勿扩大
    DT KSPM快照固定
    1h
    与扫描完成周期内连接对齐——请勿扩大
| RAP/外部检测结果检索或当前汇总 | 首次尝试
2h
| 匹配威胁与利用应用默认值。仅当返回零行或用户明确要求更长窗口时,扩大到
24h
(见detections.md § 空结果时扩大窗口) | | 跨供应商汇总(聚合) |
24h
| 汇总需按时间聚合;从宽范围开始 |
省略
from:
会回退到不符合快照语义的默认窗口,导致查询运行结果不一致。30m/1h窗口并非随意设定——它们与底层RVA/SPM扫描节奏绑定。完整窗口参考请见common-patterns.md § 7
分解包含DT的宽泛/态势概览问题(“已集成哪些安全产品,包括Dynatrace原生?”、态势概览、包含DT漏洞/合规的跨类别统计)——切勿通过一次扫描整个
security.events
来回答。运行三个独立查询并合并:流A外部+DT检测结果(
24h
,重复计数防护)、流B DT RVA(
30m
)、流C DT KSPM(
1h
)。这将高基数快照流保持在紧凑窗口内,并避免重复计数。更窄的“哪些外部集成正在发送数据?”则保持为仅外部工具的单查询。详情请见all-security-events.md § 宽泛问题查询分解。 6. 在原始列表中保留实体标识符(Top/最新/列表/展示——无
summarize
),以便用户查看每个检测结果对应的实体。不同类型的命名空间不可互换:跨供应商
*_FINDING
/扫描事件使用通用
dt.smartscape*
/
dt.entity.*
/
dt.source*
字段;RVA状态/变更事件中这些字段为空,引用存储在
affected_entity*
/
related_entities*
中。纯计数/通过率汇总无需保留。字段列表与通配符参考→common-patterns.md § 17。 7. 宽泛的实体安全问题也需要外部流。 对于“此主机/K8s节点/工作负载/集群的安全检测结果”这类提示,请勿仅查询DT RVA和SPM。还需运行外部/跨供应商
*_FINDING
流,通过宽实体OR链(
dt.smartscape_source.id
dt.entity.*
object.*
及相关
k8s.*
字段)筛选(
24h
),然后与RVA(
30m
)和SPM(
1h
)结果合并。将
dt.source_entity
视为遗留/扫描回退字段,而非跨供应商范围限定的主要路径。如果外部分支返回0行,请报告“未找到外部检测结果”并说明使用的范围。加载dt-sec-contextualization
entity-enrichment.md
进行Smartscape连接。另请见all-security-events.md。 8. 始终限制原始列表和Top-N结果。 如果用户要求“Top X”、“最近X个”或“前X个”,请在排序后添加
| sort ... | limit X
。如果用户要求列出/展示检测结果但未明确要求所有数据,且输出不是汇总(
summarize
/
makeTimeseries
),默认添加
| limit 50
。切勿对安全检测结果运行无限制的原始投影。完整规则与例外→common-patterns.md § 16。 9. 保留查询结构——除非用户要求更粗粒度的聚合,否则不要删除
by:
键。
标准跨供应商
summarize
始终按
{event.provider, product.name, event.type, dt.security.risk.level}
分组。删除任何键都会将不同供应商、产品或检测类型的行静默合并为单个计数,会被评估者扣分。除非用户明确要求更粗粒度的视图,否则请勿将四键分组替换为更简单的
by: {dt.security.risk.level}
by: {event.type}
。详情请见common-patterns.md § 15
  1. 合规状态使用
    compliance.result.status.level
    PASSED
    /
    FAILED
    /
    MANUAL
    /
    NOT_RELEVANT
    )——切勿使用
    event.status
    "PASS"
    /
    "FAIL"
    。通过率是在通过
    on: {scan.id}
    进行最新扫描去重连接后,按每个规则的判定结果计算的。字段术语、去重连接及通过率汇总→compliance.md
  2. expand
    /
    join
    /
    lookup
    展开数组后,统计不同的标识而非行数
    ——使用
    countDistinctExact(vulnerability.display_id)
    /
    countDistinctExact(finding.id)
    ,或先按标识+分组键
    dedup
    。仅当进入
    expand
    的粒度已是每个统计项一行时,普通
    count()
    才是安全的。示例与例外→common-patterns.md § 错误#55
  3. 将空实体覆盖探测结果解释为未覆盖。 验证特定实体是否被Dynatrace安全能力(RVA、SPM/KSPM、RAP或其他DT原生能力)覆盖时,若没有相关检测结果和扫描/完成事件,则该实体未被该能力覆盖。说明可能的原因:该能力未启用,或未配置/部署为监控该实体。当用户询问覆盖情况时,请勿将其含糊表述为“无检测结果”。统计逻辑→coverage-and-dashboards.md;匹配方案→dt-sec-contextualization
    correlation-and-coverage.md
  4. 如实报告空结果——切勿编造数字。 0行意味着“无匹配数据”,需说明使用的范围和筛选条件;切勿编造看似合理的值。放宽筛选条件前,请应用对应类型的文档化恢复方案(RVA 30m→24h最新已知状态、检测结果2h→24h扩大窗口、RVA筛选空
    k8s.*
    /
    dt.entity.*
    /
    dt.smartscape*
    →转向
    affected_entity.*
    /
    related_entities.*
    ),并明确说明是否进行了调整。恢复详情→vulnerabilities-dynatrace.md/detections.md
如需领域特定的最佳实践和完整诊断目录,请见上文“本技能的组织结构”部分列出的参考文档。

External Documentation

外部文档

Related Skills

相关技能

  • dt-dql-essentials — Load first. Core DQL syntax, command reference, function catalog, Smartscape patterns.
  • dt-sec-contextualization — Load for any entity-mapping question: 3-way match (K8s workload), host-by-IP, cloud Path 1, pod→node topology, cross-evidence correlation, coverage match recipes.
  • dt-obs-kubernetes — K8s topology; useful for security findings scoped to clusters / workloads
  • dt-obs-hosts — Host inventory, process-level context; useful when a finding's affected entity is a HOST or PROCESS_GROUP
  • dt-obs-services — Service-scoped queries; useful for UC-G3 "findings affecting
    <service-name>
    " and tracing from a vulnerable service to RED metrics
  • dt-obs-aws / dt-obs-azure / dt-obs-gcp — Cloud Smartscape; useful for enriching external cloud-security findings against the provider's resource topology, and for hyperscaler-specific provider field handling (cloud resource IDs, ARNs, account scoping)
  • dt-obs-tracing — Drill from a vulnerable / attacked entity to representative request traces
  • dt-obs-problems — Get affected/related entity IDs for a problem before querying security findings (UC-G5)
  • dt-dql-essentials — 优先加载。核心DQL语法、命令参考、函数目录、Smartscape模式。
  • dt-sec-contextualization — 任何实体映射问题都需加载:三方匹配(K8s工作负载)、按IP匹配主机、云路径1、Pod→Node拓扑、跨证据关联、覆盖匹配方案。
  • dt-obs-kubernetes — K8s拓扑;适用于限定到集群/工作负载的安全检测结果查询
  • dt-obs-hosts — 主机清单、进程级上下文;适用于检测结果的受影响实体为HOST或PROCESS_GROUP的场景
  • dt-obs-services — 服务范围查询;适用于UC-G3“影响
    <service-name>
    的检测结果”以及从易受攻击服务追踪到RED指标的场景
  • dt-obs-aws / dt-obs-azure / dt-obs-gcp — 云Smartscape;适用于将外部云安全检测结果与供应商资源拓扑关联,以及处理特定云供应商的字段(云资源ID、ARN、账户范围)
  • dt-obs-tracing — 从易受攻击/被攻击的实体钻取到代表性请求追踪
  • dt-obs-problems — 查询安全检测结果前,获取问题的受影响/关联实体ID(UC-G5)