{"answers":{"affected":"4 open source packages ship an affected version, including ch.qos.logback:logback-core.","exploited":"There is no known exploitation of CVE-2024-12798 in the wild and no public exploit code.","fix":"Upgrade ch.qos.logback:logback-core to a fixed version for your release line: 1.3.15 or 1.5.13.","what":"CVE-2024-12798 is a medium-severity code injection vulnerability in QOS.CH Sarl Logback-core, published on 19 Dec 2024. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2024-12798 and fix it if it is affected.\n\nWhat it is: CVE-2024-12798 is a medium-severity code injection vulnerability in QOS.CH Sarl Logback-core, published on 19 Dec 2024. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.\nExploitation: There is no known exploitation of CVE-2024-12798 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- ch.qos.logback:logback-core (Maven): affected all versions; fixed in 1.3.15\n- ch.qos.logback:logback-core (Maven): affected all versions; fixed in 1.3.15\n- ch.qos.logback:logback-core (Maven): affected from 1.4.0; fixed in 1.5.13\n- ch.qos.logback:logback-core (Maven): affected from 1.4.0; fixed in 1.5.13\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2024-12798/ (Markdown: https://insights.sbomify.com/CVE-2024-12798/index.md)","id":"CVE-2024-12798","markdown":"https://insights.sbomify.com/CVE-2024-12798/index.md","name":"CVE-2024-12798","record":{"aliases":["CLEANSTART-2026-DB97868","CLEANSTART-2026-TA42944","CLSA-2026-1793131185","CLSA-2026-1793136275","DEBIAN-CVE-2024-12798","ECHO-50cb-9ed7-3fa1","GHSA-pr98-23f8-jwxv","MINI-2r9x-552p-6g4m","MINI-8m7c-62jx-8q95","MINI-cqgc-rfj6-q49w","MINI-cx9h-9rqx-5w3j","MINI-g529-4vq2-8794","MINI-gw5x-w6q6-66mw","MINI-h86q-4wgr-c84r","MINI-jv29-xg79-3wjg","MINI-vfx3-9f2j-4pr8","MINI-wr9h-6xqh-2hp8","ROOT-APP-MAVEN-CVE-2024-12798","UBUNTU-CVE-2024-12798"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"adjacent_or_local","non_default_config":true,"product_category":"Java logging library","requires_auth":"low_privilege","summary":"Attackers with write access to logback config or env vars can execute arbitrary code via JaninoEventEvaluator in Logback-core.","user_interaction":"required","vuln_class":"code_injection"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"NCSC.ch","cpe":[],"cvss":{"score":5.9,"severity":"medium","source":"cna","vector":"CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:P/VC:L/VI:H/VA:L/SC:L/SI:H/SA:L/RE:L/U:Clear","version":"4.0"},"cwes":[{"id":"CWE-917","name":"Improper Neutralization of Special Elements used in an Expression Language Statement"}],"description":"ACE vulnerability in JaninoEventEvaluator  by QOS.CH logback-core\n      upto including version 0.1 to 1.3.14 and 1.4.0 to 1.5.12 in Java applications allows\n      attacker to execute arbitrary code by compromising an existing\n      logback configuration file or by injecting an environment variable\n      before program execution.\n\nMalicious logback configuration files can allow the attacker to execute \narbitrary code using the JaninoEventEvaluator extension.\n\nA successful attack requires the user to have write access to a \nconfiguration file. Alternatively, the attacker could inject a malicious \nenvironment variable pointing to a malicious configuration file. In both \ncases, the attack requires existing privilege.","ecosystems":["Maven"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"JaninoEventEvaluator vulnerability","id":"CVE-2024-12798","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"Maven","product":null,"products":[],"type":"code_injection","year":"2024"},"n_packages":4,"n_references":2,"next":{"headline":"Insufficiently Protected Credentials","id":"CVE-2024-12799"},"packages":[{"ecosystem":"Maven","fixed":["1.3.15"],"introduced":["0"],"last_affected":[],"package":"ch.qos.logback:logback-core","purl":null,"source":"GHSA-pr98-23f8-jwxv"},{"ecosystem":"Maven","fixed":["1.3.15"],"introduced":["0"],"last_affected":[],"package":"ch.qos.logback:logback-core","purl":"pkg:maven/ch.qos.logback/logback-core","source":"GHSA-pr98-23f8-jwxv"},{"ecosystem":"Maven","fixed":["1.5.13"],"introduced":["1.4.0"],"last_affected":[],"package":"ch.qos.logback:logback-core","purl":null,"source":"GHSA-pr98-23f8-jwxv"},{"ecosystem":"Maven","fixed":["1.5.13"],"introduced":["1.4.0"],"last_affected":[],"package":"ch.qos.logback:logback-core","purl":"pkg:maven/ch.qos.logback/logback-core","source":"GHSA-pr98-23f8-jwxv"}],"prev":{"headline":"RFC7250 handshakes with unauthenticated servers don't abort as expected","id":"CVE-2024-12797"},"products":["Logback-core"],"published":"2024-12-19","related":[],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"no","exploitation":"none","technical_impact":"total"},"state":"PUBLISHED","updated":"2025-01-03","vendors":["QOS.CH Sarl"]},"summary":"Attackers with write access to logback config or env vars can execute arbitrary code via JaninoEventEvaluator in Logback-core.","url":"https://insights.sbomify.com/CVE-2024-12798/"}