CVE-2020-36564 Improper input validation in github.com/justinas/nosurf
Attackers can bypass CSRF protection by providing a malformed token, allowing unauthorized state-changing requests.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2020-36564?
CVE-2020-36564 is a high-severity vulnerability in github.com/justinas/nosurf, published on 27 Dec 2022. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
Due to improper validation of caller input, validation is silently disabled if the provided expected token is malformed, causing any user supplied token to be considered valid.
Weakness: CWE-20
Which versions are affected by CVE-2020-36564?
3 open source packages ship an affected version, including github.com/justinas/nosurf. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
github.com/justinas/nosurf Go | All versions | 1.1.1 |
github.com/justinas/nosurf Go | All versions | 1.1.1 |
github.com/justinas/nosurf Go | All versions | 1.1.1 |
Products include Nosurf Project Nosurf.
How do I fix CVE-2020-36564?
Upgrade github.com/justinas/nosurf to 1.1.1 or later.
Is CVE-2020-36564 being exploited?
There is no known exploitation of CVE-2020-36564 in the wild and no public exploit code.
Other vulnerabilities in github.com/justinas/nosurf
Sources
Also known as GHSA-5x84-q523-vvwr, GO-2020-0049.