{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2026-1839",
        "assignerOrgId": "c09c270a-b464-47c1-9133-acb35b22c19a",
        "state": "PUBLISHED",
        "assignerShortName": "@huntr_ai",
        "dateReserved": "2026-02-03T16:49:27.781Z",
        "datePublished": "2026-04-07T05:22:00.959Z",
        "dateUpdated": "2026-04-07T13:27:41.789Z"
    },
    "containers": {
        "cna": {
            "title": "Arbitrary Code Execution via Unsafe torch.load() in Trainer Checkpoint Loading in huggingface/transformers",
            "providerMetadata": {
                "orgId": "c09c270a-b464-47c1-9133-acb35b22c19a",
                "shortName": "@huntr_ai",
                "dateUpdated": "2026-04-07T05:22:00.959Z"
            },
            "descriptions": [
                {
                    "lang": "en",
                    "value": "A vulnerability in the HuggingFace Transformers library, specifically in the `Trainer` class, allows for arbitrary code execution. The `_load_rng_state()` method in `src/transformers/trainer.py` at line 3059 calls `torch.load()` without the `weights_only=True` parameter. This issue affects all versions of the library supporting `torch>=2.2` when used with PyTorch versions below 2.6, as the `safe_globals()` context manager provides no protection in these versions. An attacker can exploit this vulnerability by supplying a malicious checkpoint file, such as `rng_state.pth`, which can execute arbitrary code when loaded. The issue is resolved in version v5.0.0rc3."
                }
            ],
            "affected": [
                {
                    "vendor": "huggingface",
                    "product": "huggingface/transformers",
                    "versions": [
                        {
                            "version": "unspecified",
                            "lessThan": "v5.0.0rc3",
                            "status": "affected",
                            "versionType": "custom"
                        }
                    ]
                }
            ],
            "references": [
                {
                    "url": "https://huntr.com/bounties/3c77bb97-e493-493d-9a88-c57f5c536485"
                },
                {
                    "url": "https://github.com/huggingface/transformers/commit/03c8082ba4594c9b8d6fe190ca9bed0e5f8ca396"
                }
            ],
            "metrics": [
                {
                    "cvssV3_0": {
                        "version": "3.0",
                        "attackComplexity": "HIGH",
                        "attackVector": "LOCAL",
                        "availabilityImpact": "HIGH",
                        "confidentialityImpact": "HIGH",
                        "integrityImpact": "LOW",
                        "privilegesRequired": "NONE",
                        "scope": "UNCHANGED",
                        "userInteraction": "REQUIRED",
                        "vectorString": "CVSS:3.0/AV:L/AC:H/PR:N/UI:R/S:U/C:H/I:L/A:H",
                        "baseScore": 6.5,
                        "baseSeverity": "MEDIUM"
                    }
                }
            ],
            "problemTypes": [
                {
                    "descriptions": [
                        {
                            "type": "CWE",
                            "lang": "en",
                            "description": "CWE-502 Deserialization of Untrusted Data",
                            "cweId": "CWE-502"
                        }
                    ]
                }
            ],
            "source": {
                "advisory": "3c77bb97-e493-493d-9a88-c57f5c536485",
                "discovery": "EXTERNAL"
            }
        },
        "adp": [
            {
                "references": [
                    {
                        "url": "https://huntr.com/bounties/3c77bb97-e493-493d-9a88-c57f5c536485",
                        "tags": [
                            "exploit"
                        ]
                    }
                ],
                "metrics": [
                    {
                        "other": {
                            "type": "ssvc",
                            "content": {
                                "timestamp": "2026-04-07T13:27:38.099805Z",
                                "id": "CVE-2026-1839",
                                "options": [
                                    {
                                        "Exploitation": "poc"
                                    },
                                    {
                                        "Automatable": "no"
                                    },
                                    {
                                        "Technical Impact": "total"
                                    }
                                ],
                                "role": "CISA Coordinator",
                                "version": "2.0.3"
                            }
                        }
                    }
                ],
                "title": "CISA ADP Vulnrichment",
                "providerMetadata": {
                    "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
                    "shortName": "CISA-ADP",
                    "dateUpdated": "2026-04-07T13:27:41.789Z"
                }
            }
        ]
    }
}