From c31c5cacde6e0f1e80ac04bd89090a72757f601a Mon Sep 17 00:00:00 2001 From: Owen Mansel-Chan Date: Tue, 30 Jun 2026 23:54:49 +0100 Subject: [PATCH] Fix cleartext logging test --- .../CWE-312-CleartextLogging/CleartextLogging.expected | 3 --- .../query-tests/Security/CWE-312-CleartextLogging/test.py | 4 ++-- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/python/ql/test/query-tests/Security/CWE-312-CleartextLogging/CleartextLogging.expected b/python/ql/test/query-tests/Security/CWE-312-CleartextLogging/CleartextLogging.expected index 56eb9367fef..d157f8f742d 100644 --- a/python/ql/test/query-tests/Security/CWE-312-CleartextLogging/CleartextLogging.expected +++ b/python/ql/test/query-tests/Security/CWE-312-CleartextLogging/CleartextLogging.expected @@ -98,6 +98,3 @@ nodes | test.py:103:21:103:37 | ControlFlowNode for Attribute | semmle.label | ControlFlowNode for Attribute | | test.py:105:11:105:31 | ControlFlowNode for Subscript | semmle.label | ControlFlowNode for Subscript | subpaths -testFailures -| test.py:103:21:103:37 | ControlFlowNode for Attribute | Unexpected result: Source | -| test.py:105:11:105:31 | ControlFlowNode for Subscript | Unexpected result: Alert | diff --git a/python/ql/test/query-tests/Security/CWE-312-CleartextLogging/test.py b/python/ql/test/query-tests/Security/CWE-312-CleartextLogging/test.py index a4c595fbaf9..f5dd29482ac 100644 --- a/python/ql/test/query-tests/Security/CWE-312-CleartextLogging/test.py +++ b/python/ql/test/query-tests/Security/CWE-312-CleartextLogging/test.py @@ -100,9 +100,9 @@ def FPs(account, account_id): import settings config = { "sleep_timer": 5, - "password": settings.password + "password": settings.password # $ SPURIOUS: Source } - print(config["sleep_timer"]) # OK + print(config["sleep_timer"]) # $ SPURIOUS: Alert # OK if __name__ == "__main__":