Lookup for vulnerable packages by Package URL.

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

{
    "url": "http://public2.vulnerablecode.io/api/packages/924136?format=api",
    "purl": "pkg:deb/debian/golang-github-ulikunitz-xz@0.5.15-1?distro=trixie",
    "type": "deb",
    "namespace": "debian",
    "name": "golang-github-ulikunitz-xz",
    "version": "0.5.15-1",
    "qualifiers": {
        "distro": "trixie"
    },
    "subpath": "",
    "is_vulnerable": false,
    "next_non_vulnerable_version": null,
    "latest_non_vulnerable_version": null,
    "affected_by_vulnerabilities": [],
    "fixing_vulnerabilities": [
        {
            "url": "http://public2.vulnerablecode.io/api/vulnerabilities/28749?format=api",
            "vulnerability_id": "VCID-aag6-jhbk-qqd6",
            "summary": "github.com/ulikunitz/xz leaks memory when decoding a corrupted multiple LZMA archives\n### Summary\n\nIt is possible to put data in front of an LZMA-encoded byte stream without detecting the situation while reading the header. This can lead to increased memory consumption because the current implementation allocates the full decoding buffer directly after reading the header. The LZMA header doesn't include a magic number or has  a checksum to detect such an issue according to the [specification](https://github.com/jljusten/LZMA-SDK/blob/master/DOC/lzma-specification.txt).\n\nNote that the code recognizes the issue later while reading the stream, but at this time the memory allocation has already been done.\n\n### Mitigations\n\nThe release v0.5.15 includes following mitigations:\n\n- The ReaderConfig DictCap field is now interpreted as a limit for the dictionary size.\n- The default is 2 Gigabytes - 1 byte (2^31-1 bytes).\n- Users can check with the [Reader.Header] method what the actual values are in  their LZMA files and set a smaller limit using ReaderConfig.\n- The dictionary size will not exceed the larger of the file size and the minimum dictionary size. This is another measure to prevent huge memory allocations for the dictionary.\n- The code supports stream sizes only up to a pebibyte (1024^5).\n\nNote that the original v0.5.14 version had a compiler error for 32 bit platforms, which has been fixed by v0.5.15.\n\n### Methods affected\n\nOnly software that uses [lzma.NewReader](https://pkg.go.dev/github.com/ulikunitz/xz/lzma#NewReader) or [lzma.ReaderConfig.NewReader](https://pkg.go.dev/github.com/ulikunitz/xz/lzma#ReaderConfig.NewReader) is affected. There is no issue for software using the xz functionality.\n\nI thank  @GregoryBuligin for his report, which is provided below.\n\n### Summary\nWhen unpacking a large number of LZMA archives, even in a single goroutine, if the first byte of the archive file is 0 (a zero byte added to the beginning), an error __writeMatch: distance out of range__ occurs. Memory consumption spikes sharply, and the GC clearly cannot handle this situation.\n\n### Details\nJudging by the error  __writeMatch: distance out of range__, the problems occur in the code around this function.\nhttps://github.com/ulikunitz/xz/blob/c8314b8f21e9c5e25b52da07544cac14db277e89/lzma/decoderdict.go#L81\n\n### PoC\nRun a function similar to this one in 1 or several goroutines on a multitude of LZMA archives that have a 0 (a zero byte) added to the beginning.\n```\nconst ProjectLocalPath = \"some/path\"\nconst TmpDir = \"tmp\"\n\nfunc UnpackLZMA(lzmaFile string) error {\n\tfile, err := os.Open(lzmaFile)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer file.Close()\n\n\treader, err := lzma.NewReader(bufio.NewReader(file))\n\tif err != nil {\n\t\treturn err\n\t}\n\n\ttmpFile, err := os.CreateTemp(TmpDir, TmpLZMAPrefix)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer func() {\n\t\ttmpFile.Close()\n\t\t_ = os.Remove(tmpFile.Name())\n\t}()\n\n\tsha256Hasher := sha256.New()\n\tmultiWriter := io.MultiWriter(tmpFile, sha256Hasher)\n\n\tif _, err = io.Copy(multiWriter, reader); err != nil {\n\t\treturn err\n\t}\n\n\tunpackHash := hex.EncodeToString(sha256Hasher.Sum(nil))\n\tunpackDir := filepath.Join(\n\t\tProjectLocalPath, unpackHash[:2],\n\t)\n\t_ = os.MkdirAll(unpackDir, DirPerm)\n\n\tunpackPath := filepath.Join(unpackDir, unpackHash)\n\n\treturn os.Rename(tmpFile.Name(), unpackPath)\n}\n```\n\n\n\n### Impact\nServers with a small amount of RAM that download and unpack a large number of unverified LZMA archives",
            "references": [
                {
                    "reference_url": "https://access.redhat.com/hydra/rest/securitydata/cve/CVE-2025-58058.json",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "5.3",
                            "scoring_system": "cvssv3",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
                        }
                    ],
                    "url": "https://access.redhat.com/hydra/rest/securitydata/cve/CVE-2025-58058.json"
                },
                {
                    "reference_url": "https://api.first.org/data/v1/epss?cve=CVE-2025-58058",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19082",
                            "published_at": "2026-04-29T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19301",
                            "published_at": "2026-04-08T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19354",
                            "published_at": "2026-04-09T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19357",
                            "published_at": "2026-04-11T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19308",
                            "published_at": "2026-04-12T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19253",
                            "published_at": "2026-04-13T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19215",
                            "published_at": "2026-04-16T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19224",
                            "published_at": "2026-04-18T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19237",
                            "published_at": "2026-04-21T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19136",
                            "published_at": "2026-04-24T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19126",
                            "published_at": "2026-04-26T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19506",
                            "published_at": "2026-04-04T12:55:00Z"
                        },
                        {
                            "value": "0.00062",
                            "scoring_system": "epss",
                            "scoring_elements": "0.19223",
                            "published_at": "2026-04-07T12:55:00Z"
                        },
                        {
                            "value": "0.00065",
                            "scoring_system": "epss",
                            "scoring_elements": "0.2027",
                            "published_at": "2026-04-02T12:55:00Z"
                        }
                    ],
                    "url": "https://api.first.org/data/v1/epss?cve=CVE-2025-58058"
                },
                {
                    "reference_url": "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2025-58058",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2025-58058"
                },
                {
                    "reference_url": "https://ftp.suse.com/pub/projects/security/yaml/suse-cvss-scores.yaml",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "5.3",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
                        }
                    ],
                    "url": "https://ftp.suse.com/pub/projects/security/yaml/suse-cvss-scores.yaml"
                },
                {
                    "reference_url": "https://github.com/ulikunitz/xz",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "5.3",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
                        },
                        {
                            "value": "MODERATE",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/ulikunitz/xz"
                },
                {
                    "reference_url": "https://github.com/ulikunitz/xz/commit/88ddf1d0d98d688db65de034f48960b2760d2ae2",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "5.3",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
                        },
                        {
                            "value": "MODERATE",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/ulikunitz/xz/commit/88ddf1d0d98d688db65de034f48960b2760d2ae2"
                },
                {
                    "reference_url": "https://github.com/ulikunitz/xz/security/advisories/GHSA-jc7w-c686-c4v9",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "5.3",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
                        },
                        {
                            "value": "MODERATE",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/ulikunitz/xz/security/advisories/GHSA-jc7w-c686-c4v9"
                },
                {
                    "reference_url": "https://nvd.nist.gov/vuln/detail/CVE-2025-58058",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "5.3",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
                        },
                        {
                            "value": "MODERATE",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://nvd.nist.gov/vuln/detail/CVE-2025-58058"
                },
                {
                    "reference_url": "https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1112508",
                    "reference_id": "1112508",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1112508"
                },
                {
                    "reference_url": "https://bugzilla.redhat.com/show_bug.cgi?id=2391585",
                    "reference_id": "2391585",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://bugzilla.redhat.com/show_bug.cgi?id=2391585"
                }
            ],
            "fixed_packages": [
                {
                    "url": "http://public2.vulnerablecode.io/api/packages/924136?format=api",
                    "purl": "pkg:deb/debian/golang-github-ulikunitz-xz@0.5.15-1?distro=trixie",
                    "is_vulnerable": false,
                    "affected_by_vulnerabilities": [],
                    "resource_url": "http://public2.vulnerablecode.io/packages/pkg:deb/debian/golang-github-ulikunitz-xz@0.5.15-1%3Fdistro=trixie"
                }
            ],
            "aliases": [
                "CVE-2025-58058",
                "GHSA-jc7w-c686-c4v9"
            ],
            "risk_score": 3.1,
            "exploitability": "0.5",
            "weighted_severity": "6.2",
            "resource_url": "http://public2.vulnerablecode.io/vulnerabilities/VCID-aag6-jhbk-qqd6"
        },
        {
            "url": "http://public2.vulnerablecode.io/api/vulnerabilities/48532?format=api",
            "vulnerability_id": "VCID-esea-tj2b-h7ey",
            "summary": "github.com/ulikunitz/xz fixes readUvarint Denial of Service (DoS)\n### Impact\n\nxz is a compression and decompression library focusing on the xz format completely written in Go. The function readUvarint used to read the xz container format may not terminate a loop provide malicous input.\n\n### Patches\n\nThe problem has been fixed in release v0.5.8.\n\n### Workarounds\n\nLimit the size of the compressed file input to a reasonable size for your use case.\n\n### References\n\nThe standard library had recently the same issue and got the [CVE-2020-16845](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-16845) allocated.\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Open an issue in [xz](https://github.com/ulikunitz/xz/issues).",
            "references": [
                {
                    "reference_url": "https://access.redhat.com/hydra/rest/securitydata/cve/CVE-2021-29482.json",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
                        }
                    ],
                    "url": "https://access.redhat.com/hydra/rest/securitydata/cve/CVE-2021-29482.json"
                },
                {
                    "reference_url": "https://api.first.org/data/v1/epss?cve=CVE-2021-29482",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62789",
                            "published_at": "2026-04-29T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62712",
                            "published_at": "2026-04-04T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62676",
                            "published_at": "2026-04-07T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62728",
                            "published_at": "2026-04-13T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62744",
                            "published_at": "2026-04-09T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62762",
                            "published_at": "2026-04-11T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62752",
                            "published_at": "2026-04-12T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62769",
                            "published_at": "2026-04-16T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62777",
                            "published_at": "2026-04-18T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62758",
                            "published_at": "2026-04-21T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62773",
                            "published_at": "2026-04-24T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62621",
                            "published_at": "2026-04-01T12:55:00Z"
                        },
                        {
                            "value": "0.00433",
                            "scoring_system": "epss",
                            "scoring_elements": "0.62679",
                            "published_at": "2026-04-02T12:55:00Z"
                        }
                    ],
                    "url": "https://api.first.org/data/v1/epss?cve=CVE-2021-29482"
                },
                {
                    "reference_url": "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-29482",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-29482"
                },
                {
                    "reference_url": "https://github.com/ulikunitz/xz/commit/69c6093c7b2397b923acf82cb378f55ab2652b9b",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/ulikunitz/xz/commit/69c6093c7b2397b923acf82cb378f55ab2652b9b"
                },
                {
                    "reference_url": "https://github.com/ulikunitz/xz/issues/35",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/ulikunitz/xz/issues/35"
                },
                {
                    "reference_url": "https://github.com/ulikunitz/xz/security/advisories/GHSA-25xm-hr59-7c27",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://github.com/ulikunitz/xz/security/advisories/GHSA-25xm-hr59-7c27"
                },
                {
                    "reference_url": "https://nvd.nist.gov/vuln/detail/CVE-2021-29482",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://nvd.nist.gov/vuln/detail/CVE-2021-29482"
                },
                {
                    "reference_url": "https://pkg.go.dev/vuln/GO-2020-0016",
                    "reference_id": "",
                    "reference_type": "",
                    "scores": [
                        {
                            "value": "7.5",
                            "scoring_system": "cvssv3.1",
                            "scoring_elements": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
                        },
                        {
                            "value": "HIGH",
                            "scoring_system": "generic_textual",
                            "scoring_elements": ""
                        }
                    ],
                    "url": "https://pkg.go.dev/vuln/GO-2020-0016"
                },
                {
                    "reference_url": "https://bugzilla.redhat.com/show_bug.cgi?id=1954368",
                    "reference_id": "1954368",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://bugzilla.redhat.com/show_bug.cgi?id=1954368"
                },
                {
                    "reference_url": "https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=988243",
                    "reference_id": "988243",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=988243"
                },
                {
                    "reference_url": "https://access.redhat.com/errata/RHSA-2021:2920",
                    "reference_id": "RHSA-2021:2920",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://access.redhat.com/errata/RHSA-2021:2920"
                },
                {
                    "reference_url": "https://access.redhat.com/errata/RHSA-2022:0687",
                    "reference_id": "RHSA-2022:0687",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://access.redhat.com/errata/RHSA-2022:0687"
                },
                {
                    "reference_url": "https://access.redhat.com/errata/RHSA-2022:1276",
                    "reference_id": "RHSA-2022:1276",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://access.redhat.com/errata/RHSA-2022:1276"
                },
                {
                    "reference_url": "https://access.redhat.com/errata/RHSA-2022:2183",
                    "reference_id": "RHSA-2022:2183",
                    "reference_type": "",
                    "scores": [],
                    "url": "https://access.redhat.com/errata/RHSA-2022:2183"
                }
            ],
            "fixed_packages": [
                {
                    "url": "http://public2.vulnerablecode.io/api/packages/924135?format=api",
                    "purl": "pkg:deb/debian/golang-github-ulikunitz-xz@0.5.6-2?distro=trixie",
                    "is_vulnerable": true,
                    "affected_by_vulnerabilities": [
                        {
                            "vulnerability": "VCID-aag6-jhbk-qqd6"
                        }
                    ],
                    "resource_url": "http://public2.vulnerablecode.io/packages/pkg:deb/debian/golang-github-ulikunitz-xz@0.5.6-2%3Fdistro=trixie"
                },
                {
                    "url": "http://public2.vulnerablecode.io/api/packages/924136?format=api",
                    "purl": "pkg:deb/debian/golang-github-ulikunitz-xz@0.5.15-1?distro=trixie",
                    "is_vulnerable": false,
                    "affected_by_vulnerabilities": [],
                    "resource_url": "http://public2.vulnerablecode.io/packages/pkg:deb/debian/golang-github-ulikunitz-xz@0.5.15-1%3Fdistro=trixie"
                }
            ],
            "aliases": [
                "CVE-2021-29482",
                "GHSA-25xm-hr59-7c27"
            ],
            "risk_score": 4.0,
            "exploitability": "0.5",
            "weighted_severity": "8.0",
            "resource_url": "http://public2.vulnerablecode.io/vulnerabilities/VCID-esea-tj2b-h7ey"
        }
    ],
    "risk_score": null,
    "resource_url": "http://public2.vulnerablecode.io/packages/pkg:deb/debian/golang-github-ulikunitz-xz@0.5.15-1%3Fdistro=trixie"
}