Skip to content

GHSA-4whc-pp4x-9pf3 CVE-2015-1840

jquery-rails and jquery-ujs subject to Exposure of Sensitive Information

Medium RubyGems
Severity
Medium
The publisher's own rating, not a CVSS score
Exploit chance (EPSS)
4.52%
Chance of exploitation in the next 30 days. Higher than 91.53% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-200 Exposure of Sensitive Information to an Unauthorized Actor
Fix
Available
2 packages have a fixed version

Description

jquery_ujs.js in jquery-rails before 3.1.3 and 4.x before 4.0.4 and rails.js in jquery-ujs before 1.0.4, as used with Ruby on Rails 3.x and 4.x, allow remote attackers to bypass the Same Origin Policy, and trigger transmission of a CSRF token to a different-domain web server, via a leading space character in a URL within an attribute value.

Affected versions

RubyGems

PackageVulnerableFixed in
jquery-rails
< 3.1.3
3.1.3
jquery-rails
>= 4.0.0, < 4.0.4
4.0.4
jquery-ujs
< 1.0.4
1.0.4

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

jquery-rails RubyGems → 3.1.3

bundler
bundle update jquery-rails # Gemfile: gem "jquery-rails", ">= 3.1.3"

jquery-ujs RubyGems → 1.0.4

bundler
bundle update jquery-ujs # Gemfile: gem "jquery-ujs", ">= 1.0.4"

Weakness

CWE-200: Exposure of Sensitive Information to an Unauthorized Actor

The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.

How to prevent it
  • Architecture and Design: Compartmentalize the system to have "safe" areas where trust boundaries can be unambiguously drawn. Do not allow sensitive data to go outside of the trust boundary and always be careful when interfacing with a compartment outside of the safe area. Ensure that appropriate compartmentalization is built into the system design, and the compartmentalization allows for and reinforces privilege separation functionality. Architects and designers should rely on the principle of least privilege to decide the appropriate time to use privileges and the time to drop privileges.

References

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
CVE-2020-11023
Potential XSS vulnerability in jQuery
Medium Known exploited Also affects jquery-rails
GHSA-579v-mp3v-rrw5
jQuery vulnerable to Cross-Site Scripting (XSS)
Medium Also affects jquery-rails
GHSA-2pqj-h3vj-pqgw
Cross-Site Scripting in jquery
Medium Also affects jquery-rails
GHSA-q4m3-2j7h-f7xw
Cross-Site Scripting in jquery
Medium Also affects jquery-rails
GHSA-gxr4-xjj5-5px2
Potential XSS vulnerability in jQuery
Medium Also affects jquery-rails
DRUPAL-CORE-2019-006
XSS in jQuery as used in Drupal, Backdrop CMS, and other products
Medium Also affects jquery-rails
GHSA-mhpp-875w-9cpv
Denial of Service in jquery
High Also affects jquery-rails
GHSA-rmxg-73gg-4p98
Cross-Site Scripting (XSS) in jquery
Medium Also affects jquery-rails
Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor