github / github/codeql

False positive: Env var is from config, not vault, and contains the name of another env var

未关闭
#19,681 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
false-positive
主要语言
CodeQL
星标
10.1k
派生
2.1k
平均合并
2 天 15 小时
30 天内合并 PR
141

描述

**Description of the false positive**

This flagged for outputting the value of an environment variable to logs. Generally, that could be a problem. In this case, the env var clearly contained the name of another env var to look in for the secret. Is there a way to not flag in this situation? For example, could we determine that this environment variable came from a k8s env var (where secrets are not allowed) as opposed to from vault?

**Code samples or links to source code**

https://github.com/github/blackbird/blob/d5fc30382331e6f5cd03c7f8695afadeeb631075/crates/config/src/embeddings.rs#L76-L79

**URL to the alert on GitHub code scanning (optional)**

https://github.com/github/blackbird/security/code-scanning/5068

贡献指南

打开贡献指南

调研方向

Start with the linked code in crates/config/src/embeddings.rs at lines 76-79 and inspect code-scanning alert 5068 to identify the CodeQL query and data-flow path producing the finding. Done means this configuration value is no longer reported as secret output while genuine environment-variable secret exposure remains detected.

由索引模型根据 Issue 内容生成。

评估

技术栈
rust
领域
security
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。