Every CVE Search/ Get API key

CVE-2021-21330

Open redirect vulnerability in aiohttp

3.1 LowFix available

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
High
Privileges needed
None
User interaction
Required

What an attacker can affect

Confidentiality
None
Integrity
Low
Availability
None

Exploit likelihood

1.91%Up 0.1 points since Apr 14, 2021
90%50%10%1%

What each source reports

CVE List Score used 3.1

Open redirect vulnerability in aiohttp

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Record
CVE-2021-21330
CVSS 3.1
3.1 LowCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:N
Weakness
CWE-601
Updated
2026-11-02
EUVDEUVD-2021-0003 3.1

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Record
EUVD-2021-0003
CVSS 3.1
3.1 LowCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:N
Updated
2026-11-03
GitHub AdvisoriesGHSA-v6wp-4m6f-gcjg 2.3

`aiohttp` Open Redirect vulnerability (`normalize_path_middleware` middleware)

Impact

Open redirect vulnerability — a maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website.

It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware.

Patches

This security problem has been fixed in v3.7.4. Upgrade your dependency as follows: pip install aiohttp >= 3.7.4

Workarounds

If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

References

For more information

If you have any questions or comments about this advisory:

Credit: Jelmer Vernooij and Beast Glatisant.

Record
GHSA-v6wp-4m6f-gcjg
CVSS 4.0
2.3 LowCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N
CVSS 3.1
3.1 LowCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:N
Weakness
CWE-601
Updated
2026-11-02
NVD 3.1

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Record
CVE-2021-21330
CVSS 3.1
3.1 LowCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:N
CVSS 3.1
6.1 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
CVSS 2.0
5.8 MediumAV:N/AC:M/Au:N/C:P/I:P/A:N
Weakness
CWE-601
Updated
2026-11-02
OSVAZL-44805 6.1

CVE-2021-21330 affecting package python-aiohttp 3.6.2-3

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Record
AZL-44805
CVSS 3.1
6.1 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Updated
2026-11-05
OSV 6.1

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Record
CVE-2021-21330
CVSS 3.1
6.1 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Updated
2026-11-02
Show 11 moreShow less
OSVDEBIAN-CVE-2021-21330 6.1

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Record
DEBIAN-CVE-2021-21330
CVSS 3.1
6.1 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Updated
2026-11-02
OSVGHSA-v6wp-4m6f-gcjg 2.3

`aiohttp` Open Redirect vulnerability (`normalize_path_middleware` middleware)

Impact

Open redirect vulnerability — a maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website.

It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware.

Patches

This security problem has been fixed in v3.7.4. Upgrade your dependency as follows: pip install aiohttp >= 3.7.4

Workarounds

If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

References

For more information

If you have any questions or comments about this advisory:

Credit: Jelmer Vernooij and Beast Glatisant.

Record
GHSA-v6wp-4m6f-gcjg
CVSS 4.0
2.3 LowCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N
CVSS 3.1
3.1 LowCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:N
Weakness
CWE-601
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-21330 3.1

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Record
UBUNTU-CVE-2021-21330
CVSS 3.1
3.1 LowCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:N
CVSS 3.1
6.1 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Updated
2026-11-02
OSVMGASA-2021-0161 No score

Updated python-aiohttp package fixes security vulnerability

Beast Glatisant and Jelmer Vernooij reported that python-aiohttp is prone to an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website (CVE-2021-21330).

Record
MGASA-2021-0161
Updated
2026-11-02
OSVopenSUSE-SU-2024:13209-1 No score

python310-aiohttp-3.8.5-2.1 on GA media

These are all security issues fixed in the python310-aiohttp-3.8.5-2.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2024:13209-1
Updated
2026-11-02
OSVopenSUSE-SU-2026:11467-1 No score

python313-aiohttp-3.14.3-1.1 on GA media

These are all security issues fixed in the python313-aiohttp-3.14.3-1.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2026:11467-1
Updated
2026-11-02
OSVPYSEC-2021-76 No score

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In aiohttp before version 3.7.4 there is an open redirect vulnerability. A maliciously crafted link to an aiohttp-based web-server could redirect the browser to a different website. It is caused by a bug in the aiohttp.web_middlewares.normalize_path_middleware middleware. This security problem has been fixed in 3.7.4. Upgrade your dependency using pip as follows "pip install aiohttp >= 3.7.4". If upgrading is not an option for you, a workaround can be to avoid using aiohttp.web_middlewares.normalize_path_middleware in your applications.

Record
PYSEC-2021-76
Updated
2026-11-02
OSVSUSE-RU-2022:3275-1 No score

Recommended update for python-aiohttp, python-typing_extensions

This update for python-aiohttp, python-typing_extensions fixes the following issues:

  • Include in SLE-15 (bsc#1197831)
  • Fixed required/optional keys with old-style TypedDict
  • Test in separate multibuild flavor to break depcycles with full python stdlib
  • Clean requirements specifications for python flavors
  • Add transitional typing-extensions provides
  • Fix tests for Python 3.9
  • Official support for Python 3.8 and 3.9
  • Fix build without python2 available
  • Fix isinstance() with generic protocol subclasses after subscripting
  • Fix tests for non-default interpreters
  • Use environment marker to specify typing dependency
  • Fix unions of protocols on Python 2
Record
SUSE-RU-2022:3275-1
Updated
2026-11-02
OSVSUSE-SU-2021:1313-1 No score

Security update for python-aiohttp

This update for python-aiohttp fixes the following issues:

  • CVE-2021-21330: Fixed the way pure-Python HTTP parser interprets // (bsc#1184745)
Record
SUSE-SU-2021:1313-1
Updated
2026-11-02
OSVUSN-5386-1 No score

python-aiohttp vulnerability

Jelmer Vernooij and Beast Glatisant discovered that AIOHTTP incorrectly handled certain URLs, leading to an open redirect attack. A remote attacker could possibly use this issue to perform phishing attacks.

Record
USN-5386-1
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
aiohttp
PyPI
before 3.7.4
3.7.4
python-aiohttp
Azure Linux:3
through 3.6.2-3 None known
python-aiohttp
Debian:12
before 3.7.4-1
3.7.4-1
python-aiohttp
Debian:13
before 3.7.4-1
3.7.4-1
python-aiohttp
Debian:14
before 3.7.4-1
3.7.4-1
python-aiohttp
Debian:10
before 3.5.1-1+deb10u1, plus listed versions
3.5.1-1
3.5.1-1+deb10u1
aiohttp
PyPI
before 3.7.4, plus listed versions
0.10.10.00.10.10.10.20.11.0
Show 45 moreShow less
0.12.00.13.00.13.10.14.00.14.10.14.20.14.30.14.40.15.00.15.10.15.20.15.30.16.00.16.10.16.20.16.30.16.40.16.50.16.60.17.00.17.10.17.20.17.30.17.40.18.00.18.10.18.20.18.30.18.40.19.00.20.20.00.20.10.20.20.21.00.21.10.21.20.21.40.21.50.21.60.22.00.22.0a00.22.0b00.22.0b10.22.0b2
3.7.4
python-aiohttp
Mageia:8
before 3.7.4-1.mga8
3.7.4-1.mga8
aiohttp
PyPI
before 3.7.4, plus listed versions
0.10.20.30.40.4.1
Show 45 moreShow less
0.4.20.4.30.4.40.5.00.6.00.6.10.6.20.6.30.6.40.6.50.7.00.7.10.7.20.7.30.8.00.8.10.8.20.8.30.8.40.9.00.9.10.9.20.9.30.10.00.10.10.10.20.11.00.12.00.13.00.13.10.14.00.14.10.14.20.14.30.14.40.15.00.15.10.15.20.15.30.16.00.16.10.16.20.16.30.16.40.16.5
3.7.4
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
Show 45 moreShow less
Affected packages
PackageAffectedFixed
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
python-aiohttp
SUSE:Linux Enterprise Module for Public Cloud 15 SP1
before 3.6.0-150100.3.9.1
3.6.0-150100.3.9.1
python-typing_extensions
SUSE:Linux Enterprise Module for Public Cloud 15 SP1
before 3.10.0.0-150100.3.3.1
3.10.0.0-150100.3.3.1
python-aiohttp
SUSE:Linux Enterprise Module for Public Cloud 15 SP2
before 3.6.0-150100.3.9.1
3.6.0-150100.3.9.1
python-typing_extensions
SUSE:Linux Enterprise Module for Public Cloud 15 SP2
before 3.10.0.0-150100.3.3.1
3.10.0.0-150100.3.3.1
python-aiohttp
SUSE:Linux Enterprise Module for Public Cloud 15 SP3
before 3.6.0-150100.3.9.1
3.6.0-150100.3.9.1
python-typing_extensions
SUSE:Linux Enterprise Module for Public Cloud 15 SP3
before 3.10.0.0-150100.3.3.1
3.10.0.0-150100.3.3.1
python-aiohttp
SUSE:Linux Enterprise Module for Public Cloud 15 SP4
before 3.6.0-150100.3.9.1
3.6.0-150100.3.9.1
python-typing_extensions
SUSE:Linux Enterprise Module for Server Applications 15 SP4
before 3.10.0.0-150400.3.2.1
3.10.0.0-150400.3.2.1
python-aiohttp
openSUSE:Leap 15.3
before 3.6.0-150100.3.9.1
3.6.0-150100.3.9.1
python-aiohttp
openSUSE:Leap 15.4
before 3.6.0-150100.3.9.1
3.6.0-150100.3.9.1
python-typing_extensions
openSUSE:Leap 15.4
before 3.10.0.0-150400.3.2.1
3.10.0.0-150400.3.2.1
python-aiohttp
SUSE:Linux Enterprise Module for Public Cloud 15 SP1
before 3.4.4-3.6.1
3.4.4-3.6.1
python-aiohttp
SUSE:Linux Enterprise Module for Public Cloud 15 SP2
before 3.4.4-3.6.1
3.4.4-3.6.1
python-aiohttp
Ubuntu:Pro:18.04:LTS
before 3.0.1-1ubuntu0.1~esm1, plus listed versions
2.2.3-1build12.2.3-22.3.6-13.0.1-1
3.0.1-1ubuntu0.1~esm1
python-aiohttp
Ubuntu:Pro:20.04:LTS
before 3.6.2-1ubuntu0.1~esm1, plus listed versions
3.5.4-13.5.4-1build13.6.1-13.6.2-13.6.2-1build1
3.6.2-1ubuntu0.1~esm1
python-aiohttp
openSUSE:Tumbleweed
before 3.8.5-2.1
3.8.5-2.1
python-aiohttp
openSUSE:Tumbleweed
From an advisory covering 10 CVEs
before 3.14.3-1.1
3.14.3-1.1

History

History
RecordedChangedSources
affected
factsOSV
aliasesEUVD
first indexedCVE List, GitHub Advisories, NVD, OSV

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

In short

CVE-2021-21330 is a low vulnerability (CVSS 3.1) in Aio-libs Aiohttp, published February 26, 2021. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 1.91%, the 79th percentile. Fixed in aiohttp 3.7.4.

References

Show 194 moreShow less
This page doesn't list everything

Left out here: 320 versions and 424 references. The JSON record has them.

MoveEnter Open