GHSA-2c7c-3mj9-8fqh Decryption of malicious PBES2 JWE objects can consume unbounded system resources

Not scored Published

An attacker can cause denial of service by sending malicious JWE objects with large p2c values to applications using the go-jose library.

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

What is GHSA-2c7c-3mj9-8fqh?

GHSA-2c7c-3mj9-8fqh is a denial of service vulnerability in github.com/go-jose/go-jose/v3, published on 21 Nov 2023. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

The go-jose package is subject to a "billion hashes attack" causing denial-of-service when decrypting JWE inputs. This occurs when an attacker can provide a PBES2 encrypted JWE blob with a very large p2c value that, when decrypted, produces a denial-of-service.

Which versions are affected by GHSA-2c7c-3mj9-8fqh?

6 open source packages ship an affected version, including github.com/go-jose/go-jose/v3 and github.com/square/go-jose.

PackageAffectedFixed in
github.com/go-jose/go-jose/v3 GoAll versions3.0.1
github.com/go-jose/go-jose/v3 GoAll versions3.0.1
github.com/go-jose/go-jose/v3 GoAll versions3.0.1
github.com/square/go-jose GoAll versionsNone
github.com/square/go-jose GoAll versions2.6.2
github.com/square/go-jose GoAll versions2.6.2

How do I fix GHSA-2c7c-3mj9-8fqh?

Upgrade github.com/go-jose/go-jose/v3 to 3.0.1 or later.

Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.

Is GHSA-2c7c-3mj9-8fqh being exploited?

There is no known exploitation of GHSA-2c7c-3mj9-8fqh in the wild and no public exploit code.

Sources

Also known as GO-2023-2334.

Is GHSA-2c7c-3mj9-8fqh in your software?

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

Check your SBOMs for free