CVE-2016-7103: jQuery-UI Cross-site Scripting in dialog closeText

jquery-ui Updated 02 Oct 2025

Summary

24/10/2017
Yes i
Moderate
6.1

CVE-2016-7103: jQuery-UI vulnerable to Cross-site Scripting in dialog closeText. Affects jquery-ui versions < 1.12.0. Fixed in 1.12.0. How to fix ↓

Also tracked for

The same CVE-2016-7103 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

jQuery-UI is a library for manipulating UI elements via jQuery. It provides a range of interactive components and widgets to enhance user experience on web applications. One of its features is the dialog function, which allows developers to create customizable dialog boxes. However, versions prior to 1.12.0 are vulnerable to a cross-site scripting (XSS) attack when arbitrary user input is supplied as the value of the closeText parameter in the dialog function.

Vulnerability Detail

The vulnerability (CVE-2016-7103) in jQuery-UI arises from improper handling of user input in the closeText parameter of the dialog function. If an application passes user-controlled data to this parameter without proper sanitization, an attacker can inject malicious scripts that will be executed in the context of the victim's browser. This can lead to various security issues, such as session hijacking, data theft, or unauthorized actions on behalf of the user.

How To Fix

Minimum fixed version

1.12.0

This is the first release that contains the fix.

npm install jquery-ui@1.12.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If upgrading to the latest version of jQuery-UI is not immediately feasible, a temporary workaround is to manually sanitize any user input passed to the closeText parameter. This can be done by using appropriate input validation and output encoding techniques to prevent the execution of malicious scripts. Here is an example of how to sanitize the closeText parameter in JavaScript:

var closeText = sanitize(userInput);

// Example sanitize function
function sanitize(input) {
  // Implement input validation and output encoding logic here
  // to prevent script execution
  return sanitizedInput;
}

Conclusion

The vulnerability in jQuery-UI's dialog closeText parameter exposes applications to cross-site scripting attacks. To ensure the security of your application, it is recommended to upgrade to jQuery-UI version 1.12.0 or later. If immediate upgrade is not possible, manually sanitize user input passed to the closeText parameter. For further assistance and support in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for jquery-ui →

Share this vulnerability

FAQ

The vulnerability allows an attacker to inject and execute arbitrary scripts in the context of a victim's browser. This can lead to various security risks, including session hijacking, data theft, or unauthorized actions on behalf of the user.

Versions prior to 1.12.0 are vulnerable to this XSS vulnerability in the closeText parameter of the dialog function.

You can use Vulert's playground (https://vulert.com/scanner) to check if your application is affected by this vulnerability. Vulert monitors and alerts in real-time for open-source vulnerabilities, using package-lock.json as a reference.

Yes, the CVSS score for this vulnerability is 6.1, indicating a moderate severity level.

While specific exploits for this vulnerability may exist, they have not been disclosed in the provided information. However, it is crucial to address this vulnerability promptly to mitigate any potential risks.

Related vulnerabilities

Recent vulnerabilities recorded for jquery-ui.

How To Fix

Minimum fixed version

1.12.0

This is the first release that contains the fix.

npm install jquery-ui@1.12.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback