Policy Bypass in LightGlue Nested Config Resolution in huggingface/transformers

Summary

CVECVE-2026-5241
StatePUBLISHED
Assigner@huntr_ai
Source PriorityCVE Program / NVD first with legacy fallback
Published2026-06-03 14:16:46 UTC
Updated2026-07-15 01:16:40 UTC
DescriptionA vulnerability in the LightGlue model loading path of huggingface/transformers version 5.2.0 allows an attacker-controlled model repository to execute arbitrary code during model initialization. The issue arises because the `trust_remote_code` parameter, intended to prevent remote code execution, is overridden by untrusted serialized configuration data in a nested code path. Specifically, when loading a LightGlue model using `AutoModel.from_pretrained()` with `trust_remote_code=False`, the `LightGlueConfig` reads the `trust_remote_code` value from the untrusted `config.json` file and propagates it into nested `AutoConfig.from_pretrained()` calls. This results in the execution of attacker-provided Python modules, even when the victim explicitly disables remote code execution. The vulnerability poses a high risk for environments such as API inference servers, research notebooks, CI/CD pipelines, and model evaluation workers, potentially leading to credential theft, lateral movement, or persistence/backdoor deployment.

Risk And Classification

Primary CVSS: v3.1 9.6 CRITICAL from [email protected]

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H

EPSS: 0.005310000 probability, percentile 0.412630000 (date 2026-07-16)

Problem Types: CWE-829 | CWE-829 CWE-829 Inclusion of Functionality from Untrusted Control Sphere | CWE-829 Inclusion of Functionality from Untrusted Control Sphere


VersionSourceTypeScoreSeverityVector
3.1[email protected]Primary9.6CRITICALCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H
3.1ADPCVSS7.7HIGHCVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:N
3.10b0ca135-0b70-47e7-9f44-1890c2a1c46cSecondary7.7HIGHCVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:N
3.0[email protected]Secondary8HIGHCVSS:3.0/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N
3.0CNADECLARED8HIGHCVSS:3.0/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N

CVSS v3.1 Breakdown

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Changed
Confidentiality
High
Integrity
High
Availability
High

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H

CVSS v3.0 Breakdown

Attack Vector
Network
Attack Complexity
High
Privileges Required
None
User Interaction
Required
Scope
Changed
Confidentiality
High
Integrity
High
Availability
None

CVSS:3.0/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N

NVD Known Affected Configurations (CPE 2.3)

TypeVendorProductVersionUpdateEditionLanguage
Application Huggingface Transformers 5.2.0 All All All

Vendor Declared Affected Products

SourceVendorProductVersionPlatforms
CNA Huggingface Huggingface/transformers affected unspecified 5.5.0 custom Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1782471555 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1782471579 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1783073038 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1782991170 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1782471656 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1782471663 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1783069204 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1782991170 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.3 unaffected 1782471606 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782135464 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782136276 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782135346 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782132167 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782132207 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782132240 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782132286 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782132236 * rpm Not specified
ADP Red Hat Red Hat OpenShift AI 3.4 unaffected 1782132163 * rpm Not specified
ADP Red Hat OpenShift Lightspeed Not specified Not specified
ADP Red Hat OpenShift Lightspeed Not specified Not specified
ADP Red Hat OpenShift Lightspeed Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat AI Inference Server Not specified Not specified
ADP Red Hat Red Hat Ansible Automation Platform 2 Not specified Not specified
ADP Red Hat Red Hat Ansible Automation Platform 2 Not specified Not specified
ADP Red Hat Red Hat Ansible Automation Platform 2 Not specified Not specified
ADP Red Hat Red Hat Enterprise Linux AI RHEL AI 3 Not specified Not specified
ADP Red Hat Red Hat Enterprise Linux AI RHEL AI 3 Not specified Not specified
ADP Red Hat Red Hat Enterprise Linux AI RHEL AI 3 Not specified Not specified
ADP Red Hat Red Hat Enterprise Linux AI RHEL AI 3 Not specified Not specified
ADP Red Hat Red Hat Enterprise Linux AI RHEL AI 3 Not specified Not specified
ADP Red Hat Red Hat Enterprise Linux AI RHEL AI 3 Not specified Not specified
ADP Red Hat Red Hat Enterprise Linux AI RHEL AI 3 Not specified Not specified
ADP Red Hat Red Hat Enterprise Linux AI RHEL AI 3 Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified
ADP Red Hat Red Hat OpenShift AI RHOAI Not specified Not specified

References

ReferenceSourceLinkTags
access.redhat.com/errata/RHSA-2026:34456 0b0ca135-0b70-47e7-9f44-1890c2a1c46c access.redhat.com
github.com/huggingface/transformers/commit/676559d5022b74aaa0cee1cee0842... [email protected] github.com Patch
security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-5241.json 0b0ca135-0b70-47e7-9f44-1890c2a1c46c security.access.redhat.com
access.redhat.com/errata/RHSA-2026:37275 0b0ca135-0b70-47e7-9f44-1890c2a1c46c access.redhat.com
huntr.com/bounties/ceb3ce1a-4c45-497a-b25e-cb9a7685e619 134c704f-9b21-4f2e-91b3-4a467353bcc0 huntr.com Exploit, Third Party Advisory
bugzilla.redhat.com/show_bug.cgi 0b0ca135-0b70-47e7-9f44-1890c2a1c46c bugzilla.redhat.com
access.redhat.com/security/cve/CVE-2026-5241 0b0ca135-0b70-47e7-9f44-1890c2a1c46c access.redhat.com
CVE Program record CVE.ORG www.cve.org canonical
NVD vulnerability detail NVD nvd.nist.gov canonical, analysis

Additional Advisory Data

SourceTimeEvent
ADP2026-06-03T15:02:16.132ZReported to Red Hat.
ADP2026-06-03T12:33:10.227ZMade public.

Solutions

ADP: RHSA-2026:37275: Red Hat OpenShift AI 3.3

ADP: RHSA-2026:34456: Red Hat OpenShift AI 3.4

Workarounds

ADP: Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.

© CVE.report 2026 |

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report