Every CVE Search/ Get API key

CVE-2014-0081

Rails vulnerable to Cross-site Scripting

4.3 MediumFix available

CVE-2014-0081 is a medium vulnerability (CVSS 4.3) in Rubyonrails Rails, published February 20, 2014. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 4.03%, the 90th percentile. Fixed in rails 3.2.17.

Multiple cross-site scripting (XSS) vulnerabilities in actionview/lib/action_view/helpers/number_helper.rb in Ruby on Rails before 3.2.17, 4.0.x before 4.0.3, and 4.1.x before 4.1.0.beta2 allow remote attackers to inject arbitrary web script or HTML via the (1) format, (2) negative_format, or (3) units parameter to the (a) number_to_currency, (b) number_to_percentage, or (c) number_to_human helper.

Exploit likelihood

4.03%Up 2.6 points since Feb 4, 2022
90%50%10%1%

What each source reports

NVD Score used 4.3

Multiple cross-site scripting (XSS) vulnerabilities in actionview/lib/action_view/helpers/number_helper.rb in Ruby on Rails before 3.2.17, 4.0.x before 4.0.3, and 4.1.x before 4.1.0.beta2 allow remote attackers to inject arbitrary web script or HTML via the (1) format, (2) negative_format, or (3) units parameter to the (a) number_to_currency, (b) number_to_percentage, or (c) number_to_human helper.

Record
CVE-2014-0081
CVSS 2.0
4.3 MediumAV:N/AC:M/Au:N/C:N/I:P/A:N
Weakness
CWE-79
Updated
2026-11-02
CVE List No score

Multiple cross-site scripting (XSS) vulnerabilities in actionview/lib/action_view/helpers/number_helper.rb in Ruby on Rails before 3.2.17, 4.0.x before 4.0.3, and 4.1.x before 4.1.0.beta2 allow remote attackers to inject arbitrary web script or HTML via the (1) format, (2) negative_format, or (3) units parameter to the (a) number_to_currency, (b) number_to_percentage, or (c) number_to_human helper.

Record
CVE-2014-0081
Updated
2026-11-02
EUVDEUVD-2017-0269 No score

Multiple cross-site scripting (XSS) vulnerabilities in actionview/lib/action_view/helpers/number_helper.rb in Ruby on Rails before 3.2.17, 4.0.x before 4.0.3, and 4.1.x before 4.1.0.beta2 allow remote attackers to inject arbitrary web script or HTML via the (1) format, (2) negative_format, or (3) units parameter to the (a) number_to_currency, (b) number_to_percentage, or (c) number_to_human helper.

Record
EUVD-2017-0269
Updated
2026-11-03
GitHub AdvisoriesGHSA-m46p-ggm5-5j83 No score

Rails vulnerable to Cross-site Scripting

There is an XSS vulnerability in the number_to_currency, number_to_percentage and number_to_human helpers in Ruby on Rails. This vulnerability has been assigned the CVE identifier CVE-2014-0081.

Versions Affected: All. Fixed Versions: 4.1.0.beta2, 4.0.3, 3.2.17.

Impact

These helpers allows users to nicely format a numeric value. Some of the parameters to the helper (format, negative_format and units) are not escaped correctly. Applications which pass user controlled data as one of these parameters are vulnerable to an XSS attack.

All users passing user controlled data to these parameters of the number helpers should either upgrade or use one of the workarounds immediately.

Releases

The 4.1.0.rc1, 4.0.3 and 3.2.17 releases are available at the normal locations.

Workarounds

The workaround for this issue is to escape the value passed to the parameter. For example, replace code like this:

<%= number_to_currency(1.02, format: params[:format]) %>

With code like this

<%= number_to_currency(1.02, format: h(params[:format])) %>

Patches

To aid users who aren't able to upgrade immediately we have provided patches for the two supported release series. They are in git-am format and consist of a single changeset.

  • 4-1-beta-number_helpers_xss.patch - Patch for 4.1-beta series
  • 4-0-number_helpers_xss.patch - Patch for 4.0 series
  • 3-2-number_helpers_xss.patch - Patch for 3.2 series

Please note that only the 4.0.x and 3.2.x series are supported at present. Users of earlier unsupported releases are advised to upgrade as soon as possible as we cannot guarantee the continued availability of security fixes for unsupported releases.

Credits

Thanks to Kevin Reintjes for reporting the issue to us.

-- Aaron Patterson http://tenderlovemaking.com/

Record
GHSA-m46p-ggm5-5j83
Weakness
CWE-79
Updated
2026-11-02
OSV No score

Multiple cross-site scripting (XSS) vulnerabilities in actionview/lib/action_view/helpers/number_helper.rb in Ruby on Rails before 3.2.17, 4.0.x before 4.0.3, and 4.1.x before 4.1.0.beta2 allow remote attackers to inject arbitrary web script or HTML via the (1) format, (2) negative_format, or (3) units parameter to the (a) number_to_currency, (b) number_to_percentage, or (c) number_to_human helper.

Record
CVE-2014-0081
Updated
2026-11-02
OSVDEBIAN-CVE-2014-0081 No score

Multiple cross-site scripting (XSS) vulnerabilities in actionview/lib/action_view/helpers/number_helper.rb in Ruby on Rails before 3.2.17, 4.0.x before 4.0.3, and 4.1.x before 4.1.0.beta2 allow remote attackers to inject arbitrary web script or HTML via the (1) format, (2) negative_format, or (3) units parameter to the (a) number_to_currency, (b) number_to_percentage, or (c) number_to_human helper.

Record
DEBIAN-CVE-2014-0081
Updated
2026-11-02
OSVGHSA-m46p-ggm5-5j83 No score

Rails vulnerable to Cross-site Scripting

There is an XSS vulnerability in the number_to_currency, number_to_percentage and number_to_human helpers in Ruby on Rails. This vulnerability has been assigned the CVE identifier CVE-2014-0081.

Versions Affected: All. Fixed Versions: 4.1.0.beta2, 4.0.3, 3.2.17.

Impact

These helpers allows users to nicely format a numeric value. Some of the parameters to the helper (format, negative_format and units) are not escaped correctly. Applications which pass user controlled data as one of these parameters are vulnerable to an XSS attack.

All users passing user controlled data to these parameters of the number helpers should either upgrade or use one of the workarounds immediately.

Releases

The 4.1.0.rc1, 4.0.3 and 3.2.17 releases are available at the normal locations.

Workarounds

The workaround for this issue is to escape the value passed to the parameter. For example, replace code like this:

<%= number_to_currency(1.02, format: params[:format]) %>

With code like this

<%= number_to_currency(1.02, format: h(params[:format])) %>

Patches

To aid users who aren't able to upgrade immediately we have provided patches for the two supported release series. They are in git-am format and consist of a single changeset.

  • 4-1-beta-number_helpers_xss.patch - Patch for 4.1-beta series
  • 4-0-number_helpers_xss.patch - Patch for 4.0 series
  • 3-2-number_helpers_xss.patch - Patch for 3.2 series

Please note that only the 4.0.x and 3.2.x series are supported at present. Users of earlier unsupported releases are advised to upgrade as soon as possible as we cannot guarantee the continued availability of security fixes for unsupported releases.

Credits

Thanks to Kevin Reintjes for reporting the issue to us.

-- Aaron Patterson http://tenderlovemaking.com/

Record
GHSA-m46p-ggm5-5j83
Weakness
CWE-79
Updated
2026-11-02
OSVMGASA-2014-0191 No score

Updated ruby-rails and associated packages fix multiple vulnerabilities

Updated ruby-activerecord and ruby-actionpack packages fix security vulnerabilities:

There is a data injection vulnerability in Active Record. Specially crafted strings can be used to save data in PostgreSQL array columns that may not be intended (CVE-2014-0080).

There is an XSS vulnerability in the number_to_currency, number_to_percentage and number_to_human helpers in Ruby on Rails (CVE-2014-0081).

The associated packages have been updated to version 4.0.3 to fix these issues.

Record
MGASA-2014-0191
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
rails
RubyGems
3.0.0 up to 3.2.17
3.2.17
rails
RubyGems
4.0.0 up to 4.0.3
4.0.3
actionpack
RubyGems
3.0.0 up to 3.2.17
3.2.17
actionpack
RubyGems
4.0.0 up to 4.0.3
4.0.3
rails
Debian:12
before 2.3.14.1
2.3.14.1
rails
Debian:13
before 2.3.14.1
2.3.14.1
rails
Debian:14
before 2.3.14.1
2.3.14.1
ruby-actionpack-3.2
Debian:7
before 3.2.6-6+deb7u2, plus listed versions
3.2.6-63.2.6-6+deb7u1
3.2.6-6+deb7u2
rails
RubyGems
3.0.0 up to 3.2.17, plus listed versions
3.0.13.0.103.0.10.rc13.0.113.0.12
Show 45 moreShow less
3.0.12.rc13.0.133.0.13.rc13.0.143.0.153.0.163.0.173.0.183.0.193.0.23.0.203.0.33.0.43.0.4.rc13.0.53.0.5.rc13.0.63.0.6.rc13.0.6.rc23.0.73.0.7.rc13.0.7.rc23.0.83.0.8.rc13.0.8.rc23.0.8.rc43.0.93.0.9.rc13.0.9.rc33.0.9.rc43.0.9.rc53.1.03.1.0.beta13.1.0.rc13.1.0.rc23.1.0.rc33.1.0.rc43.1.0.rc53.1.0.rc63.1.0.rc83.1.13.1.1.rc13.1.1.rc23.1.1.rc33.1.10
3.2.17
rails
RubyGems
4.0.0 up to 4.0.3, plus listed versions
4.0.14.0.1.rc14.0.1.rc24.0.1.rc34.0.1.rc44.0.2
4.0.3
Show 37 moreShow less
Affected packages
PackageAffectedFixed
actionpack
RubyGems
3.0.0 up to 3.2.17, plus listed versions
3.0.13.0.103.0.10.rc13.0.113.0.12
Show 45 moreShow less
3.0.12.rc13.0.133.0.13.rc13.0.143.0.153.0.163.0.173.0.183.0.193.0.23.0.203.0.33.0.43.0.4.rc13.0.53.0.5.rc13.0.63.0.6.rc13.0.6.rc23.0.73.0.7.rc13.0.7.rc23.0.83.0.8.rc13.0.8.rc23.0.8.rc43.0.93.0.9.rc13.0.9.rc33.0.9.rc43.0.9.rc53.1.03.1.0.beta13.1.0.rc13.1.0.rc23.1.0.rc33.1.0.rc43.1.0.rc53.1.0.rc63.1.0.rc83.1.13.1.1.rc13.1.1.rc23.1.1.rc33.1.10
3.2.17
actionpack
RubyGems
4.0.0 up to 4.0.3, plus listed versions
4.0.14.0.1.rc14.0.1.rc24.0.1.rc34.0.1.rc44.0.2
4.0.3
ruby-actionmailer
Mageia:4
before 4.0.3-1.mga4
4.0.3-1.mga4
ruby-actionpack
Mageia:4
before 4.0.3-1.mga4
4.0.3-1.mga4
ruby-activemodel
Mageia:4
before 4.0.3-1.mga4
4.0.3-1.mga4
ruby-activerecord
Mageia:4
before 4.0.3-1.mga4
4.0.3-1.mga4
ruby-activesupport
Mageia:4
before 4.0.3-1.mga4
4.0.3-1.mga4
ruby-rails
Mageia:4
before 4.0.3-1.mga4
4.0.3-1.mga4
ruby-railties
Mageia:4
before 4.0.3-1.mga4
4.0.3-1.mga4
cfme
Red Hat:cloudforms_managementengine:5::el6
before 0:5.2.2.3-1.el6cf
0:5.2.2.3-1.el6cf
cfme-appliance
Red Hat:cloudforms_managementengine:5::el6
before 0:5.2.2.3-1.el6cf
0:5.2.2.3-1.el6cf
cfme-debuginfo
Red Hat:cloudforms_managementengine:5::el6
before 0:5.2.2.3-1.el6cf
0:5.2.2.3-1.el6cf
cfme-lib
Red Hat:cloudforms_managementengine:5::el6
before 0:5.2.2.3-1.el6cf
0:5.2.2.3-1.el6cf
mingw32-cfme-host
Red Hat:cloudforms_managementengine:5::el6
before 0:5.2.2.3-1.el6cf
0:5.2.2.3-1.el6cf
ruby193-ruby
Red Hat:cloudforms_managementengine:5::el6
before 0:1.9.3.448-40.1.el6
0:1.9.3.448-40.1.el6
ruby193-ruby-debuginfo
Red Hat:cloudforms_managementengine:5::el6
before 0:1.9.3.448-40.1.el6
0:1.9.3.448-40.1.el6
ruby193-ruby-devel
Red Hat:cloudforms_managementengine:5::el6
before 0:1.9.3.448-40.1.el6
0:1.9.3.448-40.1.el6
ruby193-ruby-irb
Red Hat:cloudforms_managementengine:5::el6
before 0:1.9.3.448-40.1.el6
0:1.9.3.448-40.1.el6
ruby193-ruby-libs
Red Hat:cloudforms_managementengine:5::el6
before 0:1.9.3.448-40.1.el6
0:1.9.3.448-40.1.el6
ruby193-ruby-tcltk
Red Hat:cloudforms_managementengine:5::el6
before 0:1.9.3.448-40.1.el6
0:1.9.3.448-40.1.el6
ruby193-rubygem-actionpack
Red Hat:cloudforms_managementengine:5::el6
before 1:3.2.13-5.el6cf
1:3.2.13-5.el6cf
ruby193-rubygem-amq-protocol
Red Hat:cloudforms_managementengine:5::el6
before 0:1.9.2-3.el6cf
0:1.9.2-3.el6cf
ruby193-rubygem-amq-protocol-doc
Red Hat:cloudforms_managementengine:5::el6
before 0:1.9.2-3.el6cf
0:1.9.2-3.el6cf
ruby193-rubygem-bigdecimal
Red Hat:cloudforms_managementengine:5::el6
before 0:1.1.0-40.1.el6
0:1.1.0-40.1.el6
ruby193-rubygem-bunny
Red Hat:cloudforms_managementengine:5::el6
before 0:1.0.7-1.el6cf
0:1.0.7-1.el6cf
ruby193-rubygem-bunny-doc
Red Hat:cloudforms_managementengine:5::el6
before 0:1.0.7-1.el6cf
0:1.0.7-1.el6cf
ruby193-rubygem-excon
Red Hat:cloudforms_managementengine:5::el6
before 0:0.31.0-1.el6cf
0:0.31.0-1.el6cf
ruby193-rubygem-fog
Red Hat:cloudforms_managementengine:5::el6
before 0:1.19.0-1.el6cf
0:1.19.0-1.el6cf
ruby193-rubygem-io-console
Red Hat:cloudforms_managementengine:5::el6
before 0:0.3-40.1.el6
0:0.3-40.1.el6
ruby193-rubygem-linux_admin
Red Hat:cloudforms_managementengine:5::el6
before 0:0.7.0-1.el6cf
0:0.7.0-1.el6cf
ruby193-rubygem-more_core_extensions
Red Hat:cloudforms_managementengine:5::el6
before 0:1.1.2-1.el6cf
0:1.1.2-1.el6cf
ruby193-rubygem-nokogiri
Red Hat:cloudforms_managementengine:5::el6
before 0:1.5.6-3.el6cf
0:1.5.6-3.el6cf
ruby193-rubygem-nokogiri-debuginfo
Red Hat:cloudforms_managementengine:5::el6
before 0:1.5.6-3.el6cf
0:1.5.6-3.el6cf
ruby193-rubygems
Red Hat:cloudforms_managementengine:5::el6
before 0:1.8.23-40.1.el6
0:1.8.23-40.1.el6
ruby193-rubygems-devel
Red Hat:cloudforms_managementengine:5::el6
before 0:1.8.23-40.1.el6
0:1.8.23-40.1.el6
ruby193-rubygem-actionpack
Red Hat:rhel_software_collections:1::el6
before 1:3.2.8-5.3.el6
1:3.2.8-5.3.el6
ruby193-rubygem-actionpack-doc
Red Hat:rhel_software_collections:1::el6
before 1:3.2.8-5.3.el6
1:3.2.8-5.3.el6

History

History
WhenChangedSources
2026-11-03aliasesEUVD
2026-11-02createdCVE List, GitHub Advisories, NVD, OSV

References

Show 42 moreShow less
This page doesn't list everything

Left out here: 100 versions. The JSON record has them.

MoveEnter Open