---
id: CVE-2026-41846
title: >-
  Spring MVC applications which accept user-supplied values in the cssClass,
  cssErrorClass, or cssStyle attributes of JSP form tags allow arbitrary
  HTML/JavaScript code injection, potentially resulting in a cross-site
  scripting (XSS) vulne…
summary: >-
  Spring MVC applications which accept user-supplied values in the cssClass,
  cssErrorClass, or cssStyle attributes of JSP form tags allow arbitrary
  HTML/JavaScript code injection, potentially resulting in a cross-site
  scripting (XSS) vulne…
severity: medium
cvss: 5.9
cvssVector: 'CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:L/A:N'
cwe:
  - CWE-79
vendor: vmware
product: spring_framework
affected:
  - 'spring_framework >= 5.3.0, < 5.3.49'
  - 'spring_framework >= 6.1.0, < 6.1.28'
  - 'spring_framework >= 6.2.0, < 6.2.18.1'
  - 'spring_framework >= 7.0.0, < 7.0.7.1'
patched:
  - spring_framework 7.0.7.1
published: '2026-06-09'
updated: '2026-07-17'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2026-41846'
references:
  - url: 'https://spring.io/security/cve-2026-41846'
    label: security@vmware.com
tags:
  - nvd
epss: 0.00152
epssPercentile: 0.04715
ingestedAt: '2026-07-17T21:16:23.826Z'
---

## Overview

Spring MVC applications which accept user-supplied values in the cssClass, cssErrorClass, or cssStyle attributes of JSP form tags allow arbitrary HTML/JavaScript code injection, potentially resulting in a cross-site scripting (XSS) vulnerability.

Affected versions:
Spring Framework 7.0.0 through 7.0.7; 6.2.0 through 6.2.18; 6.1.0 through 6.1.27; 5.3.0 through 5.3.48.

## Affected

- `spring_framework >= 5.3.0, < 5.3.49`
- `spring_framework >= 6.1.0, < 6.1.28`
- `spring_framework >= 6.2.0, < 6.2.18.1`
- `spring_framework >= 7.0.0, < 7.0.7.1`

## Remediation

Upgrade past the affected range:

- `spring_framework 7.0.7.1`
