Cross Site Scripting Vulnerability in Backbone Package

backbone Updated 02 Oct 2025

Summary

31/05/2018
N/A
Yes i
Medium
5.4

CVE-2016-10537: backbone is a module that adds in structure to a JavaScript heavy application through key-value pairs and custom events connecting to your RESTful API through JSON There exists a potential Cross Site Scripting vulnerabil... Affects backbone across 2 version ranges.

< 0.5.3-1 < 3505bde58ec82f15e920298813d37476242793bb

Fixed in 0.5.3-1. How to fix ↓

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

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

Backbone is a JavaScript library that provides structure to web applications by using models with key-value binding and custom events. It facilitates interaction with RESTful APIs through JSON, making it easier to manage data and user interactions in complex applications. However, versions 0.3.3 and earlier are vulnerable to a Cross Site Scripting (XSS) issue, which can lead to security risks if user input is not properly sanitized.

Vulnerability Detail

The vulnerability arises from the Model#Escape function in Backbone versions 0.3.3 and earlier. The regex used for escaping user input fails to convert certain characters, such as '<' to '<', allowing malicious users to inject scripts into web pages. This can lead to XSS attacks, where attackers can execute arbitrary JavaScript in the context of the user's browser, potentially stealing sensitive information or manipulating the user interface.

How To Fix

Minimum fixed version

0.5.3-1

This is the first release that contains the fix.

sudo apt-get install --only-upgrade backbone

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

Workaround

If upgrading is not immediately possible, a temporary workaround is to manually sanitize user input before it is processed by the Backbone library. This can be done using a library like DOMPurify to clean the input. Example code snippet:

const cleanInput = DOMPurify.sanitize(userInput);
model.set('inputField', cleanInput);

Conclusion

The Cross Site Scripting vulnerability in Backbone versions 0.3.3 and earlier poses a significant risk to web applications that utilize this library. It is crucial to upgrade to a secure version to protect against potential attacks. Additionally, using tools like Vulert can help monitor for vulnerabilities in your software.

See every vulnerability recorded for backbone →

Share this vulnerability

FAQ

XSS is a security vulnerability that allows attackers to inject malicious scripts into web pages viewed by other users, potentially compromising user data and session information.

You can use the Vulert platform to monitor and alert for open-source vulnerabilities in your software. Simply upload your manifest file like package-lock.json to check for vulnerabilities.

Failure to address this vulnerability can lead to XSS attacks, where attackers can steal sensitive information, hijack user sessions, or manipulate the user interface.

Yes, upgrading to Backbone version 0.5.3-1 or later resolves this vulnerability and ensures that user input is properly sanitized.

The CVSS score for this vulnerability is 5.4, indicating a moderate level of risk associated with its exploitation.

Related vulnerabilities

Recent vulnerabilities recorded for backbone.

How To Fix

Minimum fixed version

0.5.3-1

This is the first release that contains the fix.

sudo apt-get install --only-upgrade backbone

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