# GHSA-55p7-v223-x366: IdentityServer Open Redirect vulnerability

- Severity: Medium (CVSS:4.0, scored by GitHub) `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:L/VI:N/VA:N/SC:L/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Published: 2024-07-31T19:57:33.000Z
- Modified: 2024-11-30T05:42:13.333Z
- Weaknesses: CWE-601

## Description

### Impact
It is possible for an attacker to craft malicious Urls that certain functions in IdentityServer will incorrectly treat as local and trusted. If such a Url is returned as a redirect, some browsers will follow it to a third-party, untrusted site.

### Affected Methods
- In the `DefaultIdentityServerInteractionService`, the `GetAuthorizationContextAsync` method may return non-null and the `IsValidReturnUrl` method may return true for malicious Urls, indicating incorrectly that they can be safely redirected to.

   _UI code calling these two methods is the most commonly used code path that will expose the vulnerability. The default UI templates rely on this behavior in the Login, Challenge, and Consent pages. Customized user interface code might also rely on this behavior. The following uncommonly used APIs are also vulnerable:_

- The `ServerUrlExtensions.GetIdentityServerRelativeUrl`, `ReturnUrlParser.ParseAsync` and `OidcReturnUrlParser.ParseAsync`  methods may incorrectly return non-null, and the `ReturnUrlParser.IsValidReturnUrl` and `OidcReturnUrlParser.IsValidReturnUrl` methods may incorrectly return true for malicious Urls.

### Patches
IdentityServer4 is no longer supported and will not be receiving updates. Please consider updating to [Duende.IdentityServer](https://duendesoftware.com).

(As written by GitHub Advisory Database.)

## Affected

- IdentityServer4 (NuGet): up to 4.1.2

## Every score

- GitHub: CVSS:3.1 4.7 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:N/A:N`
- GitHub: CVSS:4.0 Medium `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:L/VI:N/VA:N/SC:L/SI:N/SA:N`

## References

- <https://github.com/DuendeSoftware/IdentityServer/security/advisories/GHSA-ff4q-64jc-gx98> (web)
- <https://github.com/IdentityServer/IdentityServer4/security/advisories/GHSA-55p7-v223-x366> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2024-39694> (advisory)
- <https://github.com/IdentityServer/IdentityServer4> (package)

## Sources

- GitHub Advisory Database: [GHSA-55p7-v223-x366](https://github.com/advisories/GHSA-55p7-v223-x366), CC-BY-4.0, modified 2024-11-30

---

Page: https://cve.day/GHSA-55p7-v223-x366 · Whole record: https://cve.day/GHSA-55p7-v223-x366.json · Rebuilt by cve.day 2026-11-25T22:56:29.464Z
