CVE-2021-31402 dio vulnerable to CRLF injection with HTTP method string

High 7.5 Published Updated

Attackers can inject CRLF characters into HTTP requests via the method string in the Dart dio package, potentially altering request structure.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2021-31402?

CVE-2021-31402 is a high-severity vulnerability in n/a, published on 15 Apr 2021. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

The dio package 4.0.0 for Dart allows CRLF injection if the attacker controls the HTTP method string, a different vulnerability than CVE-2020-35669.

Weakness: CWE-74

Which versions are affected by CVE-2021-31402?

2 open source packages ship an affected version, including dio. It affects 1 product.

PackageAffectedFixed in
dio PubAll versions5.0.0
dio PubAll versions5.0.0

Products include Flutterchina Dio.

How do I fix CVE-2021-31402?

Upgrade dio to 5.0.0 or later.

Is CVE-2021-31402 being exploited?

There is no known exploitation of CVE-2021-31402 in the wild and no public exploit code.

Sources

Also known as GHSA-9324-jv53-9cc8.

Is CVE-2021-31402 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free