CVE-2022-33146: web2py Open Redirect Vulnerability
Summary
CVE-2022-33146: Open redirect in web2py. Affects web2py versions < 2.22.5. Fixed in 2.22.5. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
web2py is a popular open-source web application framework written in Python. It is designed to facilitate the rapid development of web applications, providing a robust set of tools and libraries for developers. The framework is known for its ease of use, built-in web-based interface, and support for multiple databases. However, certain versions of web2py are vulnerable to an open redirect issue, which can be exploited by attackers to redirect users to malicious sites.
Vulnerability Detail
The open redirect vulnerability in web2py versions prior to 2.22.5 allows a remote attacker to manipulate URLs, redirecting users to arbitrary websites. This can lead to phishing attacks, where users are tricked into providing sensitive information on a fraudulent site. The vulnerability arises from improper validation of user input in URL redirection mechanisms, making it possible for attackers to craft URLs that appear legitimate but lead to harmful destinations.
How To Fix
Latest published version: 2.1.1 as of 23 Oct 2026
pip install --upgrade "web2py==2.1.1"
Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.
If you need the minimum change
2.22.5
This is the first release that contains the fix.
pip install --upgrade "web2py==2.22.5"
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
If you cannot immediately update to the patched version, consider implementing input validation to restrict the URLs that can be redirected to. Ensure that only trusted domains are allowed for redirection, and reject any URLs that do not meet your criteria.
Conclusion
The open redirect vulnerability in web2py poses a significant risk to users and applications utilizing the affected versions. It is crucial to update to version 2.22.5 or later to mitigate this risk. Additionally, implementing input validation can serve as a temporary measure until an update can be applied.
See every vulnerability recorded for web2py →
FAQ
An open redirect vulnerability allows attackers to redirect users to any URL, potentially leading to phishing or malicious sites.
You can use the Vulert playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.
The primary risk is phishing attacks, where users are tricked into providing sensitive information on a malicious site.
Yes, you can implement strict input validation to limit redirection to trusted domains as a temporary workaround.
The CVSS score for this vulnerability is 6.1, indicating a moderate level of severity.
References
Related vulnerabilities
Recent vulnerabilities recorded for web2py.