Lookup for vulnerable packages by Package URL.

GET /api/packages/322503?format=api
HTTP 200 OK
Allow: GET, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "url": "http://public2.vulnerablecode.io/api/packages/322503?format=api",
    "purl": "pkg:gem/tzinfo@0.3.31",
    "type": "gem",
    "namespace": "",
    "name": "tzinfo",
    "version": "0.3.31",
    "qualifiers": {},
    "subpath": "",
    "is_vulnerable": true,
    "next_non_vulnerable_version": "0.3.61",
    "latest_non_vulnerable_version": "1.2.10",
    "affected_by_vulnerabilities": [
        {
            "url": "http://public2.vulnerablecode.io/api/vulnerabilities/53763?format=api",
            "vulnerability_id": "VCID-kkef-q9fm-xuhw",
            "summary": "TZInfo relative path traversal vulnerability allows loading of arbitrary files\n### Impact\n\n#### Affected versions\n\n  - 0.3.60 and earlier.\n  - 1.0.0 to 1.2.9 when used with the Ruby data source (tzinfo-data).\n\n#### Vulnerability \n\nWith the Ruby data source (the tzinfo-data gem for tzinfo version 1.0.0 and later and built-in to earlier versions), 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.\n\nFor example, with version 1.2.9, you can run the following to load a file with path `/tmp/payload.rb`:\n\n```ruby\nTZInfo::Timezone.get(\"foo\\n/../../../../../../../../../../../../../../../../tmp/payload\")\n```\n\nThe exact number of parent directory traversals needed will vary depending on the location of the tzinfo-data gem.\n\nTZInfo versions 1.2.6 to 1.2.9 can be made to load files from outside of the Ruby load path. Versions up to and including 1.2.5 can only be made to load files from directories within the load path. \n\nThis could be exploited in, for example, a Ruby on Rails application using tzinfo version 1.2.9, that allows file uploads and has a time zone selector that accepts arbitrary time zone identifiers. The CVSS score and severity have been set on this basis.\n\nVersions 2.0.0 and later are not vulnerable.\n\n### Patches\n\nVersions 0.3.61 and 1.2.10 include fixes to correctly validate time zone identifiers (commit 9eddbb5c0e682736f61d0dd803b6031a5db9eadf for 0.3.x and commit 9905ca93abf7bf3e387bd592406e403cd18334c7 for 1.2.x).\n\nNote that 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. For example if `/tmp/upload` was in the load path, then `TZInfo::Timezone.get('foo')` could load a file with path `/tmp/upload/tzinfo/definition/foo.rb`. Applications should ensure that untrusted files are not placed in a directory on the load path.\n\n### Workarounds\n\nAs 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`.\n\n### For more information\n\nIf you have any questions or comments about this advisory:\n  - Open an issue in [the tzinfo repository](https://github.com/tzinfo/tzinfo).",
            "references": [
                {
                    "reference_url": "https://access.redhat.com/hydra/rest/securitydata/cve/CVE-2022-31163.json",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        }
                    ],
                    "url": "https://access.redhat.com/hydra/rest/securitydata/cve/CVE-2022-31163.json"
                },
                {
                    "reference_url": "https://api.first.org/data/v1/epss?cve=CVE-2022-31163",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89774",
                            "published_at": "2026-04-26T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89773",
                            "published_at": "2026-04-29T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89758",
                            "published_at": "2026-04-21T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89764",
                            "published_at": "2026-04-18T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89763",
                            "published_at": "2026-04-16T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89747",
                            "published_at": "2026-04-13T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89708",
                            "published_at": "2026-04-02T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89749",
                            "published_at": "2026-04-09T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89742",
                            "published_at": "2026-04-08T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89723",
                            "published_at": "2026-04-04T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89725",
                            "published_at": "2026-04-07T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89754",
                            "published_at": "2026-04-12T12:55:00Z"
                        },
                        {
                            "value": "0.05032",
                            "scoring_system": "epss",
                            "scoring_elements": "0.89756",
                            "published_at": "2026-04-11T12:55:00Z"
                        }
                    ],
                    "url": "https://api.first.org/data/v1/epss?cve=CVE-2022-31163"
                },
                {
                    "reference_url": "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-31163",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-31163"
                },
                {
                    "reference_url": "https://ftp.suse.com/pub/projects/security/yaml/suse-cvss-scores.yaml",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        }
                    ],
                    "url": "https://ftp.suse.com/pub/projects/security/yaml/suse-cvss-scores.yaml"
                },
                {
                    "reference_url": "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/tzinfo/CVE-2022-31163.yml",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/tzinfo/CVE-2022-31163.yml"
                },
                {
                    "reference_url": "https://github.com/tzinfo/tzinfo",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/tzinfo/tzinfo"
                },
                {
                    "reference_url": "https://github.com/tzinfo/tzinfo/commit/9905ca93abf7bf3e387bd592406e403cd18334c7",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        },
                        {
                            "value": "Track*",
                            "scoring_system": "ssvc",
                            "scoring_elements": "SSVCv2/E:P/A:N/T:T/P:M/B:A/M:M/D:R/2024-09-05T14:09:24Z/"
                        }
                    ],
                    "url": "https://github.com/tzinfo/tzinfo/commit/9905ca93abf7bf3e387bd592406e403cd18334c7"
                },
                {
                    "reference_url": "https://github.com/tzinfo/tzinfo/commit/9eddbb5c0e682736f61d0dd803b6031a5db9eadf",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        },
                        {
                            "value": "Track*",
                            "scoring_system": "ssvc",
                            "scoring_elements": "SSVCv2/E:P/A:N/T:T/P:M/B:A/M:M/D:R/2024-09-05T14:09:24Z/"
                        }
                    ],
                    "url": "https://github.com/tzinfo/tzinfo/commit/9eddbb5c0e682736f61d0dd803b6031a5db9eadf"
                },
                {
                    "reference_url": "https://github.com/tzinfo/tzinfo/commit/ca29f349856d62cb2b2edb3257d9ddd2f97b3c27",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://github.com/tzinfo/tzinfo/commit/ca29f349856d62cb2b2edb3257d9ddd2f97b3c27"
                },
                {
                    "reference_url": "https://github.com/tzinfo/tzinfo/releases/tag/v0.3.61",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        },
                        {
                            "value": "Track*",
                            "scoring_system": "ssvc",
                            "scoring_elements": "SSVCv2/E:P/A:N/T:T/P:M/B:A/M:M/D:R/2024-09-05T14:09:24Z/"
                        }
                    ],
                    "url": "https://github.com/tzinfo/tzinfo/releases/tag/v0.3.61"
                },
                {
                    "reference_url": "https://github.com/tzinfo/tzinfo/releases/tag/v1.2.10",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        },
                        {
                            "value": "Track*",
                            "scoring_system": "ssvc",
                            "scoring_elements": "SSVCv2/E:P/A:N/T:T/P:M/B:A/M:M/D:R/2024-09-05T14:09:24Z/"
                        }
                    ],
                    "url": "https://github.com/tzinfo/tzinfo/releases/tag/v1.2.10"
                },
                {
                    "reference_url": "https://github.com/tzinfo/tzinfo/security/advisories/GHSA-5cm2-9h8c-rvfx",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3",
                            "scoring_elements": ""
                        },
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "cvssv3.1_qr",
                            "scoring_elements": ""
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        },
                        {
                            "value": "Track*",
                            "scoring_system": "ssvc",
                            "scoring_elements": "SSVCv2/E:P/A:N/T:T/P:M/B:A/M:M/D:R/2024-09-05T14:09:24Z/"
                        }
                    ],
                    "url": "https://github.com/tzinfo/tzinfo/security/advisories/GHSA-5cm2-9h8c-rvfx"
                },
                {
                    "reference_url": "https://lists.debian.org/debian-lts-announce/2022/08/msg00009.html",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        },
                        {
                            "value": "Track*",
                            "scoring_system": "ssvc",
                            "scoring_elements": "SSVCv2/E:P/A:N/T:T/P:M/B:A/M:M/D:R/2024-09-05T14:09:24Z/"
                        }
                    ],
                    "url": "https://lists.debian.org/debian-lts-announce/2022/08/msg00009.html"
                },
                {
                    "reference_url": "https://nvd.nist.gov/vuln/detail/CVE-2022-31163",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://nvd.nist.gov/vuln/detail/CVE-2022-31163"
                },
                {
                    "reference_url": "https://bugzilla.redhat.com/show_bug.cgi?id=2110551",
                    "reference_id": "2110551",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://bugzilla.redhat.com/show_bug.cgi?id=2110551"
                },
                {
                    "reference_url": "https://github.com/advisories/GHSA-5cm2-9h8c-rvfx",
                    "reference_id": "GHSA-5cm2-9h8c-rvfx",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "HIGH",
                            "scoring_system": "cvssv3.1_qr",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/advisories/GHSA-5cm2-9h8c-rvfx"
                },
                {
                    "reference_url": "https://access.redhat.com/errata/RHSA-2022:7242",
                    "reference_id": "RHSA-2022:7242",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://access.redhat.com/errata/RHSA-2022:7242"
                },
                {
                    "reference_url": "https://access.redhat.com/errata/RHSA-2023:1486",
                    "reference_id": "RHSA-2023:1486",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://access.redhat.com/errata/RHSA-2023:1486"
                },
                {
                    "reference_url": "https://access.redhat.com/errata/RHSA-2023:2097",
                    "reference_id": "RHSA-2023:2097",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://access.redhat.com/errata/RHSA-2023:2097"
                }
            ],
            "fixed_packages": [
                {
                    "url": "http://public2.vulnerablecode.io/api/packages/81313?format=api",
                    "purl": "pkg:gem/tzinfo@0.3.61",
                    "is_vulnerable": false,
                    "affected_by_vulnerabilities": [],
                    "resource_url": "http://public2.vulnerablecode.io/packages/pkg:gem/tzinfo@0.3.61"
                },
                {
                    "url": "http://public2.vulnerablecode.io/api/packages/81314?format=api",
                    "purl": "pkg:gem/tzinfo@1.2.10",
                    "is_vulnerable": false,
                    "affected_by_vulnerabilities": [],
                    "resource_url": "http://public2.vulnerablecode.io/packages/pkg:gem/tzinfo@1.2.10"
                }
            ],
            "aliases": [
                "CVE-2022-31163",
                "GHSA-5cm2-9h8c-rvfx"
            ],
            "risk_score": 4.0,
            "exploitability": "0.5",
            "weighted_severity": "8.0",
            "resource_url": "http://public2.vulnerablecode.io/vulnerabilities/VCID-kkef-q9fm-xuhw"
        }
    ],
    "fixing_vulnerabilities": [],
    "risk_score": "4.0",
    "resource_url": "http://public2.vulnerablecode.io/packages/pkg:gem/tzinfo@0.3.31"
}