CVE-2022-3145 is a medium-severity (CVSS 4.7) Open Redirect vulnerability in @okta/oidc-middleware. A fix is available for @okta/oidc-middleware — see the affected versions and patch details below.
@okta/oidc-middlewareOpen Redirect vulnerability
Exploitation Status
No confirmed exploitation observed yet
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for CVE-2022-3145.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
How broadly this vulnerability is actually deployed: weekly install volume shows current usage, and reverse-dependency count shows how many other packages break if it stays unpatched.
@okta/oidc-middlewarenpmDescription
An open redirect vulnerability exists in Okta OIDC Middleware prior to version 5.0.0 allowing an attacker to redirect a user to an arbitrary URL.
Affected products and versions Okta OIDC Middleware prior to version 5.0.0.
Resolution The vulnerability is fixed in OIDC Middleware 5.0.0. To remediate this vulnerability, upgrade Okta OIDC Middleware to this version or later.
CVE details CVE ID: CVE-2022-3145 Published Date: 01/05/2023 Vulnerability Type: Open Redirect CWE: CWE-601 CVSS v3.1 Score: 4.3 Severity: Medium Vector string: AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N
Severity Details To exploit this issue, an attacker would need to send a victim a malformed URL containing a target server that they control. Once a user successfully completed the login process, the victim user would then be redirected to the attacker controlled site.
References https://github.com/okta/okta-oidc-middleware
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 📦npm | @okta/oidc-middleware | all versions | 5.0.0npm install @okta/oidc-middleware@5.0.0 |
Affected Products
oidc middlewareoktaDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for @okta/oidc-middleware, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update @okta/oidc-middleware to 5.0.0 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2022-3145 is resolved across your whole dependency graph.
Workarounds
Stop reflecting attacker-controlled destinations: resolve every redirect target against an allowlist of paths or hosts you own, prefer a server-side key over a full URL in the request, and reject absolute URLs entirely where the flow only ever needs a relative one.
Frequently Asked Questions
Is CVE-2022-3145 in your dependencies?
Find it across npm, including transitive dependencies.