Skip to content
Heist/ feed
Back to feed
Medium

CUPS has a use-after-free in `cupsdDeleteTemporaryPrinters` via dangling subscription pointer

Type: advisorySources: OSV

OpenPrinting CUPS is an open source printing system for Linux and other Unix-like operating systems. In versions 2.4.16 and prior, a use-after-free vulnerability exists in the CUPS scheduler (cupsd) when temporary printers are automatically deleted. cupsdDeleteTemporaryPrinters() in scheduler/printers.c calls cupsdDeletePrinter() without first expiring subscriptions that reference the printer, leaving cupsd_subscription_t.dest as a dangling pointer to freed heap memory. The dangling pointer is subsequently dereferenced at multiple code sites, causing a crash (denial of service) of the cupsd daemon. With heap grooming, this can be leveraged for code execution.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2026-39316
Confirmed fixed CVEs
Not specified
Updated in this feed
3 Nov 2026, 02:35 UTC · Revision 1

Source evidence

CUPS has a use-after-free in `cupsdDeleteTemporaryPrinters` via dangling subscription pointer

core-osv · Original source

Published 7 Apr 2026, 17:00 UTC

OpenPrinting CUPS is an open source printing system for Linux and other Unix-like operating systems. In versions 2.4.16 and prior, a use-after-free vulnerability exists in the CUPS scheduler (cupsd) when temporary printers are automatically deleted. cupsdDeleteTemporaryPrinters() in scheduler/printers.c calls cupsdDeletePrinter() without first expiring subscriptions that reference the printer, leaving cupsd_subscription_t.dest as a dangling pointer to freed heap memory. The dangling pointer is subsequently dereferenced at multiple code sites, causing a crash (denial of service) of the cupsd daemon. With heap grooming, this can be leveraged for code execution.

osv:CVE-2026-39316
Complete source record
{
  "id": "75ab4e0489ebb40fe83f501b125a1c30670e0512d076eb5475dddc7d1bde2ab8",
  "url": "https://osv.dev/vulnerability/CVE-2026-39316",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "CUPS has a use-after-free in `cupsdDeleteTemporaryPrinters` via dangling subscription pointer",
    "summary": "OpenPrinting CUPS is an open source printing system for Linux and other Unix-like operating systems. In versions 2.4.16 and prior, a use-after-free vulnerability exists in the CUPS scheduler (cupsd) when temporary printers are automatically deleted. cupsdDeleteTemporaryPrinters() in scheduler/printers.c calls cupsdDeletePrinter() without first expiring subscriptions that reference the printer, leaving cupsd_subscription_t.dest as a dangling pointer to freed heap memory. The dangling pointer is subsequently dereferenced at multiple code sites, causing a crash (denial of service) of the cupsd daemon. With heap grooming, this can be leveraged for code execution.",
    "evidence": "osv:CVE-2026-39316",
    "products": [],
    "severity": "medium",
    "structured": {
      "id": "CVE-2026-39316",
      "aliases": [
        "CVE-2026-39316",
        "GHSA-pjv5-prqp-46rg"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/openprinting/cups",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "last_affected": "7523763f00d2063f88026d93bc5b29806240de2b"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "last_affected": "2.4.16"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "StringRangeExpression"
                  },
                  {
                    "cpe": "cpe:2.3:a:openprinting:cups:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "last_affected": "2.4.16"
                      }
                    ],
                    "source": "CPE_RANGE"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v2.4.16",
            "v2.4.15",
            "v2.4.14",
            "v2.4.13",
            "v2.4.12",
            "v2.4.11",
            "v2.4.10",
            "v2.4.9",
            "v2.4.8",
            "v2.4.7",
            "v2.4.6",
            "v2.4.5",
            "v2.4.3",
            "v2.4.4",
            "v2.4.2",
            "v2.4.1",
            "v2.4.0",
            "v2.4rc1",
            "v2.4b1",
            "v2.3.3op2",
            "v2.3.3op1",
            "v2.3.3",
            "v2.3.1",
            "v2.3.0",
            "v2.3rc1",
            "v2.3b8",
            "v2.3b7",
            "v2.3b6",
            "v2.3b5",
            "v2.3b4",
            "v2.3b3",
            "v2.3b2",
            "v2.3b1",
            "v2.2.6",
            "v2.2.5",
            "v2.2.4",
            "v2.2.3",
            "v2.2.2",
            "v2.2.1",
            "v2.2.0",
            "v2.2rc1",
            "v2.2b2",
            "v2.2b1"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-39316.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:25.278851817Z",
      "provider": "osv",
      "references": [
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/39xxx/CVE-2026-39316.json",
        "https://github.com/OpenPrinting/cups/security/advisories/GHSA-pjv5-prqp-46rg",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-39316"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-416"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/39xxx/CVE-2026-39316.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-39316",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 491951,
  "published_at": "2026-04-07T17:00:26.801+00:00"
}