github / github/codeql

False positive in python/ql/src/Security/CWE-312/CleartextLogging.ql

Open
#20,168 1 comment 0 reactions 0 assignees View on GitHub
false-positive
Dominant language
CodeQL
Stars
10.1k
Forks
2.1k
Avg merge
2d 15h
Merged PRs (30d)
141

Description

secrets_client.describe_secret(SecretId=secret_name)
secrets_client.delete_secret(SecretId=secret_name, ForceDeleteWithoutRecovery=True)
print(f"Deleted secret '{secret_name}' in region '{region}'")
This expression logs as clear text.
This expression logs as clear text.

Variable name doesn’t represent a secret.

Contributor guide

Open the contributing guide

Research direction

Start with python/ql/src/Security/CWE-312/CleartextLogging.ql and reproduce the issue using the Python snippet in the report. Trace why secret_name is treated as a secret despite the report’s naming evidence; done when this example is no longer flagged while genuine cleartext logging remains detected.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.