CVE-2019-16751 Devise Token Auth vulnerable to Cross-site Scripting

Medium 6.1 Published Updated

Unauthenticated attackers can execute malicious JavaScript in victims' browsers via a crafted URL in the Devise Token Auth library.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
A user has to click or open something
Fix
Available

What is CVE-2019-16751?

CVE-2019-16751 is a medium-severity cross-site scripting vulnerability in n/a, published on 24 Sep 2019. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

Official description

An issue was discovered in Devise Token Auth through 1.1.2. The omniauth failure endpoint is vulnerable to Reflected Cross Site Scripting (XSS) through the message parameter. Unauthenticated attackers can craft a URL that executes a malicious JavaScript payload in the victim's browser. This affects the fallback_render method in the omniauth callbacks controller.

Weakness: CWE-79

Which versions are affected by CVE-2019-16751?

2 open source packages ship an affected version, including devise_token_auth. It affects 1 product.

PackageAffectedFixed in
devise_token_auth RubyGemsFrom 0.1.331.1.3
devise_token_auth RubyGemsFrom 0.1.331.1.3

Products include Devise Token Auth Project Devise Token Auth.

How do I fix CVE-2019-16751?

Upgrade devise_token_auth to 1.1.3 or later.

Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.

Is CVE-2019-16751 being exploited?

There is no known exploitation of CVE-2019-16751 in the wild and no public exploit code.

Sources

Also known as GHSA-mvqr-r76c-wm5f.

Is CVE-2019-16751 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free