{"answers":{"affected":"4 open source packages ship an affected version, including tzinfo. It affects 2 products.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2022-31163 exists.","fix":"Upgrade tzinfo to a fixed version for your release line: 0.3.61 or 1.2.10.","what":"CVE-2022-31163 is a high-severity path traversal vulnerability in Debian Debian Linux, published on 21 Jul 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2022-31163 and fix it if it is affected.\n\nWhat it is: CVE-2022-31163 is a high-severity path traversal vulnerability in Debian Debian Linux, published on 21 Jul 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.\nExploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2022-31163 exists.\n\nAffected packages and fixed versions:\n- tzinfo (RubyGems): affected all versions; fixed in 0.3.61\n- tzinfo (RubyGems): affected all versions; fixed in 0.3.61\n- tzinfo (RubyGems): affected from 1.0.0; fixed in 1.2.10\n- tzinfo (RubyGems): affected from 1.0.0; fixed in 1.2.10\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-2022-31163/ (Markdown: https://insights.sbomify.com/CVE-2022-31163/index.md)","id":"CVE-2022-31163","markdown":"https://insights.sbomify.com/CVE-2022-31163/index.md","name":"CVE-2022-31163","record":{"aliases":["DEBIAN-CVE-2022-31163","DLA-3077-1","DLA-3866-1","GHSA-5cm2-9h8c-rvfx","OESA-2024-1398","OESA-2024-1399","SUSE-SU-2022:2592-1","SUSE-SU-2022:2765-1","UBUNTU-CVE-2022-31163","openSUSE-SU-2024:12249-1","openSUSE-SU-2024:13171-1","openSUSE-SU-2024:14178-1"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"yes","non_default_config":false,"product_category":"Ruby timezone library","requires_auth":"none","summary":"Attackers can exploit path traversal in TZInfo to load arbitrary files, leading to code execution within the Ruby process.","user_interaction":"required","vuln_class":"path_traversal"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"debian_linux","vendor":"debian"},{"product":"tzinfo","vendor":"tzinfo_project"}],"cvss":{"score":7.5,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-23","name":"Relative Path Traversal"},{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"}],"description":"TZInfo is a Ruby library that provides access to time zone data and allows times to be converted using time zone rules. Versions prior to 0.36.1, as well as those prior to 1.2.10 when used with the Ruby data source tzinfo-data, are vulnerable to relative path traversal. With the Ruby data source, time zones are defined in Ruby files. There is one file per time zone. Time zone files are loaded with `require` on demand. In the affected versions, `TZInfo::Timezone.get` fails to validate time zone identifiers correctly, allowing a new line character within the identifier. With Ruby version 1.9.3 and later, `TZInfo::Timezone.get` can be made to load unintended files with `require`, executing them within the Ruby process. Versions 0.3.61 and 1.2.10 include fixes to correctly validate time zone identifiers. Versions 2.0.0 and later are not vulnerable. Version 0.3.61 can still load arbitrary files from the Ruby load path if their name follows the rules for a valid time zone identifier and the file has a prefix of `tzinfo/definition` within a directory in the load path. Applications should ensure that untrusted files are not placed in a directory on the load path. As a workaround, the time zone identifier can be validated before passing to `TZInfo::Timezone.get` by ensuring it matches the regular expression `\\A[A-Za-z0-9+\\-_]+(?:\\/[A-Za-z0-9+\\-_]+)*\\z`.","ecosystems":["RubyGems","SUSE:Linux Enterprise High Availability Extension 15","SUSE:Linux Enterprise High Availability Extension 15 SP1","SUSE:Linux Enterprise High Availability Extension 15 SP2","SUSE:Linux Enterprise High Availability Extension 15 SP3","SUSE:Linux Enterprise High Availability Extension 15 SP4","SUSE:OpenStack Cloud Crowbar 8","SUSE:OpenStack Cloud Crowbar 9","openSUSE:Leap 15.3","openSUSE:Leap 15.4","openSUSE:Tumbleweed"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"weaponised"},"has_fix":true,"headline":"TZInfo relative path traversal vulnerability allows loading of arbitrary files","id":"CVE-2022-31163","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"RubyGems","product":"debian:debian_linux","products":["debian:debian_linux"],"type":"path_traversal","year":"2022"},"n_packages":16,"n_references":6,"next":{"headline":"Tovy before v0.7.51 vulnerable to users logging in as and impersonating other users","id":"CVE-2022-31164"},"packages":[{"ecosystem":"RubyGems","fixed":["0.3.61"],"introduced":["0"],"last_affected":[],"package":"tzinfo","purl":null,"source":"GHSA-5cm2-9h8c-rvfx"},{"ecosystem":"RubyGems","fixed":["0.3.61"],"introduced":["0"],"last_affected":[],"package":"tzinfo","purl":"pkg:gem/tzinfo","source":"GHSA-5cm2-9h8c-rvfx"},{"ecosystem":"RubyGems","fixed":["1.2.10"],"introduced":["1.0.0"],"last_affected":[],"package":"tzinfo","purl":null,"source":"GHSA-5cm2-9h8c-rvfx"},{"ecosystem":"RubyGems","fixed":["1.2.10"],"introduced":["1.0.0"],"last_affected":[],"package":"tzinfo","purl":"pkg:gem/tzinfo","source":"GHSA-5cm2-9h8c-rvfx"},{"ecosystem":"SUSE:Linux Enterprise High Availability Extension 15","fixed":["1.2.4-150000.3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/suse/rubygem-tzinfo\u0026distro=SUSE%20Linux%20Enterprise%20High%20Availability%20Extension%2015","source":"SUSE-SU-2022:2592-1"},{"ecosystem":"SUSE:Linux Enterprise High Availability Extension 15 SP1","fixed":["1.2.4-150000.3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/suse/rubygem-tzinfo\u0026distro=SUSE%20Linux%20Enterprise%20High%20Availability%20Extension%2015%20SP1","source":"SUSE-SU-2022:2592-1"},{"ecosystem":"SUSE:Linux Enterprise High Availability Extension 15 SP2","fixed":["1.2.4-150000.3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/suse/rubygem-tzinfo\u0026distro=SUSE%20Linux%20Enterprise%20High%20Availability%20Extension%2015%20SP2","source":"SUSE-SU-2022:2592-1"},{"ecosystem":"SUSE:Linux Enterprise High Availability Extension 15 SP3","fixed":["1.2.4-150000.3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/suse/rubygem-tzinfo\u0026distro=SUSE%20Linux%20Enterprise%20High%20Availability%20Extension%2015%20SP3","source":"SUSE-SU-2022:2592-1"},{"ecosystem":"SUSE:Linux Enterprise High Availability Extension 15 SP4","fixed":["1.2.4-150000.3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/suse/rubygem-tzinfo\u0026distro=SUSE%20Linux%20Enterprise%20High%20Availability%20Extension%2015%20SP4","source":"SUSE-SU-2022:2592-1"},{"ecosystem":"SUSE:OpenStack Cloud Crowbar 8","fixed":["1.2.2-3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/suse/rubygem-tzinfo\u0026distro=SUSE%20OpenStack%20Cloud%20Crowbar%208","source":"SUSE-SU-2022:2765-1"},{"ecosystem":"SUSE:OpenStack Cloud Crowbar 9","fixed":["1.2.2-3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/suse/rubygem-tzinfo\u0026distro=SUSE%20OpenStack%20Cloud%20Crowbar%209","source":"SUSE-SU-2022:2765-1"},{"ecosystem":"openSUSE:Leap 15.3","fixed":["1.2.4-150000.3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/opensuse/rubygem-tzinfo\u0026distro=openSUSE%20Leap%2015.3","source":"SUSE-SU-2022:2592-1"},{"ecosystem":"openSUSE:Leap 15.4","fixed":["1.2.4-150000.3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo","purl":"pkg:rpm/opensuse/rubygem-tzinfo\u0026distro=openSUSE%20Leap%2015.4","source":"SUSE-SU-2022:2592-1"},{"ecosystem":"openSUSE:Tumbleweed","fixed":["1.2.10-1.4"],"introduced":["0"],"last_affected":[],"package":"ruby3.2-rubygem-tzinfo-1.2","purl":"pkg:rpm/opensuse/ruby3.2-rubygem-tzinfo-1.2\u0026distro=openSUSE%20Tumbleweed","source":"openSUSE-SU-2024:13171-1"},{"ecosystem":"openSUSE:Tumbleweed","fixed":["1.2.10-1.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo-1.2","purl":"pkg:rpm/opensuse/rubygem-tzinfo-1.2\u0026distro=openSUSE%20Tumbleweed","source":"openSUSE-SU-2024:12249-1"},{"ecosystem":"openSUSE:Tumbleweed","fixed":["1.2.11-1.5"],"introduced":["0"],"last_affected":[],"package":"rubygem-tzinfo-1.2","purl":"pkg:rpm/opensuse/rubygem-tzinfo-1.2\u0026distro=openSUSE%20Tumbleweed","source":"openSUSE-SU-2024:14178-1"}],"prev":{"headline":"Slack Morphism for Rust before 0.41.0 can accidentally leak Slack OAuth client information in application debug logs","id":"CVE-2022-31162"},"products":["tzinfo"],"published":"2022-07-21","related":[{"cvss_score":10,"headline":"ProFTPD Improper Access Control","id":"CVE-2015-3306","kev_date_added":"2026-10-08","published":"2015-05-18"},{"cvss_score":9.9,"headline":"RoundCube Webmail Deserialization of Untrusted Data","id":"CVE-2025-49113","kev_date_added":"2026-02-20","published":"2025-06-02"},{"cvss_score":9.8,"headline":"GNU InetUtils Argument Injection","id":"CVE-2026-24061","kev_date_added":"2026-01-26","published":"2026-01-21"},{"cvss_score":9.8,"headline":"Linux Kernel Improper Check for Unusual or Exceptional Conditions","id":"CVE-2025-39682","kev_date_added":"2026-09-18","published":"2025-09-05"},{"cvss_score":9.8,"headline":"Mozilla Firefox Use-After-Free","id":"CVE-2024-9680","kev_date_added":"2024-10-15","published":"2024-10-09"},{"cvss_score":9.8,"headline":"RARLAB UnRAR Directory Traversal","id":"CVE-2022-30333","kev_date_added":"2022-08-09","published":"2022-05-09"},{"cvss_score":9.8,"headline":"Roundcube Webmail SQL Injection","id":"CVE-2021-44026","kev_date_added":"2023-06-22","published":"2021-11-19"}],"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":"CC BY 4.0","name":"SUSE","prefix":"SUSE"},{"class":"attribution","licence":"CC BY 4.0","name":"SUSE","prefix":"openSUSE"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"no","exploitation":"poc","technical_impact":"total"},"state":"PUBLISHED","updated":"2024-09-05","vendors":["tzinfo"]},"summary":"Attackers can exploit path traversal in TZInfo to load arbitrary files, leading to code execution within the Ruby process.","url":"https://insights.sbomify.com/CVE-2022-31163/"}