Every CVE Search/ Get API key

CVE-2021-32740

Regular Expression Denial of Service in Addressable templates

7.5 HighFix available

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
Low
Privileges needed
None
User interaction
None

What an attacker can affect

Confidentiality
None
Integrity
None
Availability
High

Exploit likelihood

2.14%Up 1.4 points since Jul 7, 2021
90%50%10%1%

What each source reports

CVE List Score used 7.5

Regular Expression Denial of Service in Addressable templates

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

Record
CVE-2021-32740
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Weakness
CWE-400
Updated
2026-11-02
EUVDEUVD-2021-1480 7.5

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

Record
EUVD-2021-1480
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Updated
2026-11-03
GitHub AdvisoriesGHSA-jxhc-q857-3j6g 7.5

Regular Expression Denial of Service in Addressable templates

Impact

Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected.

Patches

The vulnerability was introduced in version 2.3.0 (previously yanked) and has been present in all subsequent versions up to, and including, 2.7.0. It is fixed in version 2.8.0.

Workarounds

The vulnerability can be avoided by only creating Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

References

For more information

If you have any questions or comments about this advisory:

Record
GHSA-jxhc-q857-3j6g
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Weakness
CWE-400, CWE-1333
Updated
2026-11-02
NVD 7.5

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

Record
CVE-2021-32740
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
CVSS 2.0
5.0 MediumAV:N/AC:L/Au:N/C:N/I:N/A:P
Weakness
CWE-400
Updated
2026-11-02
OSVALPINE-CVE-2021-32740 7.5

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

Record
ALPINE-CVE-2021-32740
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Updated
2026-11-03
OSV 7.5

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

Record
CVE-2021-32740
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Updated
2026-11-02
Show 11 moreShow less
OSVDEBIAN-CVE-2021-32740 7.5

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

Record
DEBIAN-CVE-2021-32740
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Updated
2026-11-02
OSVGHSA-jxhc-q857-3j6g 7.5

Regular Expression Denial of Service in Addressable templates

Impact

Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected.

Patches

The vulnerability was introduced in version 2.3.0 (previously yanked) and has been present in all subsequent versions up to, and including, 2.7.0. It is fixed in version 2.8.0.

Workarounds

The vulnerability can be avoided by only creating Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

References

For more information

If you have any questions or comments about this advisory:

Record
GHSA-jxhc-q857-3j6g
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Weakness
CWE-1333, CWE-400
Updated
2026-11-02
OSVOESA-2021-1278 7.5

rubygem-addressable security update

Addressable is a replacement for the URI implementation that is part of Ruby's standard library. It more closely conforms to the relevant RFCs and adds support for URI and URL templates.

Security Fix(es):

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.(CVE-2021-32740)

Record
OESA-2021-1278
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Updated
2026-11-02
OSVRHSA-2021:4702 9.8

Red Hat Security Advisory: Satellite 6.10 Release

Record
RHSA-2021:4702
CVSS 3.1
9.8 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Updated
2026-11-02
OSVUBUNTU-CVE-2021-32740 7.5

Addressable is an alternative implementation to the URI implementation that is part of Ruby's standard library. An uncontrolled resource consumption vulnerability exists after version 2.3.0 through version 2.7.0. Within the URI template implementation in Addressable, a maliciously crafted template may result in uncontrolled resource consumption, leading to denial of service when matched against a URI. In typical usage, templates would not normally be read from untrusted user input, but nonetheless, no previous security advisory for Addressable has cautioned against doing this. Users of the parsing capabilities in Addressable but not the URI template capabilities are unaffected. The vulnerability is patched in version 2.8.0. As a workaround, only create Template objects from trusted sources that have been validated not to produce catastrophic backtracking.

Record
UBUNTU-CVE-2021-32740
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Updated
2026-11-02
OSVMGASA-2021-0417 No score

Updated ruby-addressable packages fix security vulnerability

A security flaw was found on rubygem-addressable that a crafted template may cause a Denial of Service (CVE-2021-32740).

Record
MGASA-2021-0417
Updated
2026-11-02
OSVopenSUSE-SU-2024:11592-1 No score

ruby2.7-rubygem-http-5.0.4-1.1 on GA media

These are all security issues fixed in the ruby2.7-rubygem-http-5.0.4-1.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2024:11592-1
Updated
2026-11-02
OSVopenSUSE-SU-2024:12247-1 No score

ruby3.1-rubygem-http-5.1.0-1.1 on GA media

These are all security issues fixed in the ruby3.1-rubygem-http-5.1.0-1.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2024:12247-1
Updated
2026-11-02
OSVopenSUSE-SU-2024:13157-1 No score

ruby3.2-rubygem-http-5.1.0-1.4 on GA media

These are all security issues fixed in the ruby3.2-rubygem-http-5.1.0-1.4 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2024:13157-1
Updated
2026-11-02
OSVSUSE-SU-2021:2927-1 No score

Security update for rubygem-addressable

This update for rubygem-addressable fixes the following issues:

  • CVE-2021-32740: Fixed denial of service via maliciously crafted templates (bsc#1188207).
Record
SUSE-SU-2021:2927-1
Updated
2026-11-02
OSVSUSE-SU-2021:2928-1 No score

Security update for rubygem-addressable

This update for rubygem-addressable fixes the following issues:

  • CVE-2021-32740: Fixed denial of service via maliciously crafted templates (bsc#1188207).
Record
SUSE-SU-2021:2928-1
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
addressable
RubyGems
2.3.0 to 2.7.0
2.8.0
ruby-addressable
Alpine:v3.15
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Alpine:v3.16
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Alpine:v3.17
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Alpine:v3.18
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Alpine:v3.19
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Alpine:v3.20
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Alpine:v3.21
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Alpine:v3.22
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Alpine:v3.23
2.3.0 up to 2.8.0-r0
2.8.0-r0
Show 44 moreShow less
Affected packages
PackageAffectedFixed
ruby-addressable
Alpine:v3.24
2.3.0 up to 2.8.0-r0
2.8.0-r0
ruby-addressable
Debian:12
before 2.7.0-2
2.7.0-2
ruby-addressable
Debian:13
before 2.7.0-2
2.7.0-2
ruby-addressable
Debian:14
before 2.7.0-2
2.7.0-2
addressable
RubyGems
2.3.0 up to 2.8.0, plus listed versions
2.3.22.3.32.3.42.3.52.3.6
Show 8 moreShow less
2.3.72.3.82.4.02.5.02.5.12.5.22.6.02.7.0
2.8.0
ruby-addressable
Mageia:8
before 2.7.0-1.1.mga8
2.7.0-1.1.mga8
rubygem-addressable
openEuler:20.03-LTS-SP1
before 2.5.2-2.oe1
2.5.2-2.oe1
rubygem-addressable
openEuler:20.03-LTS-SP2
before 2.5.2-2.oe1
2.5.2-2.oe1
python-ecdsa
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:0.13.3-2.el7pc
0:0.13.3-2.el7pc
python3-ecdsa
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:0.13.3-2.el7pc
0:0.13.3-2.el7pc
python-ecdsa
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:0.13.3-2.el7pc
0:0.13.3-2.el7pc
python3-ecdsa
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:0.13.3-2.el7pc
0:0.13.3-2.el7pc
tfm-rubygem-activerecord-session_store
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:2.0.0-1.el7sat
0:2.0.0-1.el7sat
satellite
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:6.10.0-3.el7sat
0:6.10.0-3.el7sat
satellite
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:6.10.0-3.el7sat
0:6.10.0-3.el7sat
candlepin
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:4.0.9-1.el7sat
0:4.0.9-1.el7sat
python-pyyaml
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:5.4.1-1.el7pc
0:5.4.1-1.el7pc
python3-pyyaml
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:5.4.1-1.el7pc
0:5.4.1-1.el7pc
python-pyyaml
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:5.4.1-1.el7pc
0:5.4.1-1.el7pc
python3-pyyaml
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:5.4.1-1.el7pc
0:5.4.1-1.el7pc
tfm-rubygem-nokogiri
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:1.11.3-2.el7sat
0:1.11.3-2.el7sat
tfm-rubygem-nokogiri
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:1.11.3-2.el7sat
0:1.11.3-2.el7sat
satellite-capsule
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:6.10.0-3.el7sat
0:6.10.0-3.el7sat
foreman
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:2.5.2.17-2.el7sat
0:2.5.2.17-2.el7sat
foreman
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:2.5.2.17-2.el7sat
0:2.5.2.17-2.el7sat
python-aiohttp
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:3.7.4-1.el7pc
0:3.7.4-1.el7pc
python-aiohttp
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:3.7.4-1.el7pc
0:3.7.4-1.el7pc
tfm-rubygem-actionpack
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:6.0.3.7-1.el7sat
0:6.0.3.7-1.el7sat
tfm-rubygem-rails
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:6.0.3.7-1.el7sat
0:6.0.3.7-1.el7sat
python3-django
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:2.2.24-1.el7pc
0:2.2.24-1.el7pc
python3-django
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:2.2.24-1.el7pc
0:2.2.24-1.el7pc
tfm-rubygem-puma
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:5.3.2-1.el7sat
0:5.3.2-1.el7sat
tfm-rubygem-addressable
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:2.8.0-1.el7sat
0:2.8.0-1.el7sat
python-urllib3
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:1.26.5-1.el7pc
0:1.26.5-1.el7pc
python3-urllib3
Red Hat:satellite_capsule:6.10::el7
From an advisory covering 21 CVEs
before 0:1.26.5-1.el7pc
0:1.26.5-1.el7pc
python-urllib3
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:1.26.5-1.el7pc
0:1.26.5-1.el7pc
python3-urllib3
Red Hat:satellite:6.10::el7
From an advisory covering 21 CVEs
before 0:1.26.5-1.el7pc
0:1.26.5-1.el7pc
rubygem-addressable
SUSE:OpenStack Cloud Crowbar 9
before 2.3.6-4.3.3
2.3.6-4.3.3
rubygem-addressable
SUSE:OpenStack Cloud Crowbar 8
before 2.3.6-3.3.3
2.3.6-3.3.3
ruby-addressable
Ubuntu:Pro:16.04:LTS
All versions, plus listed versions
2.3.8-12.3.8-1ubuntu0.1~esm1
None known
ruby-addressable
Ubuntu:Pro:18.04:LTS
All versions, plus listed versions
2.5.1-22.5.2-12.5.2-1ubuntu0.1~esm1
None known
ruby-addressable
Ubuntu:Pro:20.04:LTS
All versions, plus listed versions
2.5.2-12.7.0-12.7.0-1ubuntu0.1~esm1
None known
rubygem-http
openSUSE:Tumbleweed
before 5.1.0-1.1
5.1.0-1.1
ruby3.2-rubygem-http
openSUSE:Tumbleweed
before 5.1.0-1.4
5.1.0-1.4

History

History
RecordedChangedSources
affected, facts
affected, aliases, referencesOSV
aliasesEUVD
first indexedCVE List, GitHub Advisories, NVD, OSV

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2021-32740 is a high vulnerability (CVSS 7.5) in Addressable Project Addressable, published July 6, 2021. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 2.14%, the 82nd percentile. Fixed in addressable 2.8.0.

References

Show 194 moreShow less
This page doesn't list everything

Left out here: 413 references. The JSON record has them.

MoveEnter Open