{"id":"GHSA-5xf2-f6ch-6p8r","summary":"CodeChecker has a buffer overflow in the log command","details":"### Summary\nCodeChecker versions up to 6.26.1 contain a buffer overflow vulnerability in the internal `ldlogger` library, which is executed by the `CodeChecker log` command.\n\n### Details\nUnsafe usage of `strcpy()` function in the internal `ldlogger` library allows attackers to trigger a buffer overflow by supplying crafted inputs from the command line. Specifically, the destination buffer is stack-allocated with a fixed size of 4096 bytes, while `strcpy()` is called without any length checks, enabling an attacker to overrun the buffer.\n\n### PoC\nExample script is included below to illustrate how this vulnerability can be exploited.\n```bash\n#!/bin/bash\n\nexport CC_LOGGER_DEF_DIRS=1; \npayload=''; for i in $(seq 1 4090); do payload+='A'; done\n\nCodeChecker log -b \"/very/long/path/to/$payload/gcc a.c\" -o compilation.json\n```\n\n### Impact\nAny environment where the vulnerable `CodeChecker log` command is executed with untrusted user input is affected by this vulnerability.","aliases":["CVE-2025-40843","PYSEC-2025-100"],"modified":"2026-06-05T14:45:49.832338459Z","published":"2025-09-22T18:04:20Z","database_specific":{"github_reviewed":true,"github_reviewed_at":"2025-09-22T18:04:20Z","nvd_published_at":"2025-10-28T19:15:41Z","cwe_ids":["CWE-121"],"severity":"MODERATE"},"references":[{"type":"WEB","url":"https://github.com/Ericsson/codechecker/security/advisories/GHSA-5xf2-f6ch-6p8r"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-40843"},{"type":"WEB","url":"https://github.com/Ericsson/codechecker/commit/4122eb1b43d00c880e4f0747d2ca0a674feb7a50"},{"type":"PACKAGE","url":"https://github.com/Ericsson/codechecker"},{"type":"WEB","url":"https://github.com/pypa/advisory-database/tree/main/vulns/codechecker/PYSEC-2025-100.yaml"}],"affected":[{"package":{"name":"codechecker","ecosystem":"PyPI","purl":"pkg:pypi/codechecker"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"6.26.2"}]}],"versions":["6.16.0","6.16.0a1","6.17.0","6.18.0","6.18.1","6.18.2","6.19.0","6.19.1","6.20.0","6.20.0rc1","6.21.0","6.21.0rc1","6.22.0","6.22.0rc1","6.22.1","6.22.2","6.22.2.post1","6.23.0","6.23.0rc2","6.23.1","6.24.0","6.24.1","6.24.2","6.24.4","6.25.0","6.25.1","6.26.0","6.26.1"],"database_specific":{"last_known_affected_version_range":"\u003c= 6.26.1","source":"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2025/09/GHSA-5xf2-f6ch-6p8r/GHSA-5xf2-f6ch-6p8r.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L"}]}