{"answers":{"affected":"2 open source packages ship an affected version, including moment.","exploited":"There is no known exploitation of CVE-2026-17495 in the wild and no public exploit code.","fix":"Upgrade moment to 2.31.0 or later.","what":"CVE-2026-17495 is a medium-severity path traversal vulnerability in moment, published on 15 Sep 2026. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2026-17495 and fix it if it is affected.\n\nWhat it is: CVE-2026-17495 is a medium-severity path traversal vulnerability in moment, published on 15 Sep 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2026-17495 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- moment (npm): affected from 2.29.2; fixed in 2.31.0\n- moment (npm): affected from 2.29.2; fixed in 2.31.0\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-2026-17495/ (Markdown: https://insights.sbomify.com/CVE-2026-17495/index.md)","id":"CVE-2026-17495","markdown":"https://insights.sbomify.com/CVE-2026-17495/index.md","name":"CVE-2026-17495","record":{"aliases":["CLEANSTART-2026-FU60890","CLSA-2026-1793190763","DEBIAN-CVE-2026-17495","ECHO-4992-a84d-e0aa","GHSA-4p3w-j4w9-5jqw","MINI-2wmq-xrc8-r6hf","MINI-3phx-mfrv-xgpw","MINI-4cf7-xh75-7fvf","MINI-4h2g-5w43-fc6r","MINI-4m2q-ccx2-45g6","MINI-59m9-r8jc-g52x","MINI-5pp7-fvwj-mxfj","MINI-5q54-fv7p-h8mh","MINI-68m2-7v46-68wf","MINI-697x-8m33-w3g4","MINI-6vjm-wh83-v46w","MINI-8qxp-pw83-p9fj","MINI-fhrr-xmjq-qmg7","MINI-fjqw-4hx6-5w82","MINI-hc9v-r3x2-29qw","MINI-hffx-q3j3-7xc7","MINI-hw75-pg2h-6v37","MINI-hx2v-qc4c-v969","MINI-jj5g-m6ph-m457","MINI-mcp7-vr75-r273","MINI-vcm6-5wrx-p4p3","MINI-vfpc-pqh3-97h4","MINI-w55w-3725-5q26","MINI-wgqh-hpcg-qcgg","MINI-x82p-8w5h-fq58","MINI-xrcv-r223-r67r","UBUNTU-CVE-2026-17495"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"yes","non_default_config":false,"product_category":"JavaScript date library","requires_auth":"none","summary":"Attackers can execute arbitrary code by passing crafted non-string objects to moment.locale(), bypassing path traversal guards in server-side applications.","user_interaction":"not_required","vuln_class":"path_traversal"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"openjs","cpe":[],"cvss":{"score":5.9,"severity":"medium","source":"cna","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N","version":"3.1"},"cwes":[{"id":"CWE-27","name":"Path Traversal: 'dir/../../filename'"}],"description":"moment is a JavaScript date library for parsing, validating, manipulating, and formatting dates. In versions 2.29.2 through 2.30.1, a specially crafted non-string object passed to moment.locale() can bypass the locale-name path-traversal guard. The guard assumes the input is a string, so an object whose match() method satisfies the check while its toString() returns a traversal path reaches an internal require() call with attacker-controlled path segments. This is an incomplete fix for CVE-2022-24785 and primarily affects npm (server-side) users that pass user-provided input directly to moment.locale(). The issue is fixed in moment 2.31.0, and users should upgrade to 2.31.0 or later. As a workaround, validate that any user-supplied input is a string before passing it to moment.locale().","ecosystems":["npm"],"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":"moment vulnerable to Path Traversal via crafted non-string locale name","id":"CVE-2026-17495","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"npm","product":null,"products":[],"type":"path_traversal","year":"2026"},"n_packages":2,"n_references":2,"next":{"headline":"NoteGen chat preview XSS via unsanitized AI/skill HTML rendering","id":"CVE-2026-17496"},"packages":[{"ecosystem":"npm","fixed":["2.31.0"],"introduced":["2.29.2"],"last_affected":[],"package":"moment","purl":null,"source":"GHSA-4p3w-j4w9-5jqw"},{"ecosystem":"npm","fixed":["2.31.0"],"introduced":["2.29.2"],"last_affected":[],"package":"moment","purl":"pkg:npm/moment","source":"GHSA-4p3w-j4w9-5jqw"}],"prev":{"headline":"Power System Buffer Overflow","id":"CVE-2026-17494"},"products":["moment"],"published":"2026-09-15","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":"partial"},"state":"PUBLISHED","updated":"2026-09-15","vendors":["moment"]},"summary":"Attackers can execute arbitrary code by passing crafted non-string objects to moment.locale(), bypassing path traversal guards in server-side applications.","url":"https://insights.sbomify.com/CVE-2026-17495/"}