Skip to content
OpenAdvisories
Medium · 6.1 CVE-2020-25739 EUVD-2021-0786GHSA-78vq-9j56-wrfr

Gon gem lack of escaping certain input when outputting as JSON

Published Sep 23, 2020 · Updated Aug 4, 2024 · Assigned by mitre

Description

An issue was discovered in the gon gem before gon-6.4.0 for Ruby. MultiJson does not honor the escape_mode parameter to escape fields as an XSS protection mechanism. To mitigate, json_dumper.rb in gon now does escaping for XSS by default without relying on MultiJson.

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 12 ruby-gon 6.4.0-1 —
Debian 9 ruby-gon 6.1.0-1+deb9u1 DLA-2380-1
ReleasePackageFixed inAdvisory
Ubuntu 20.04 LTS ruby-gon No fix yet —
Ubuntu 18.04 LTS ruby-gon 6.1.0-1+deb9u1build0.18.04.1 USN-4560-1
Ubuntu 16.04 LTS ruby-gon No fix yet —

Affected packages

EcosystemPackageAffectedFixedRecord
RubyGems gon < 6.4.0 6.4.0 GHSA-78vq-9j56-wrfr

Advisories 2

References