Intel

AIKIDO-2026-767492

web-auth/cose-lib is vulnerable to Uncontrolled Resource Consumption

Uncontrolled Resource ConsumptionGHSA-9v8c-2mgr-qvx3 Published 2 days ago

59

Medium Risk

This Affects:

PHPweb-auth/cose-lib
0.0.1 - 4.7.1
Fixed in 4.7.2
Are you affected? Scan for Free

TL;DR

COSE RSA signature verification performs modular exponentiation and key export on caller-supplied RSA keys before bounding their size. A key with an oversized modulus or a public exponent close to the modulus forces full-width exponentiation in the RSASSA-PSS path, and superlinear base-10 conversion in RsaKey::asPem() on builds without GMP or BCMath, so a single crafted key consumes seconds to minutes of CPU per verification. This produces denial of service against verifiers that accept RSA keys from untrusted sources. The fix caps the modulus at 16384 bits and the exponent at 256 bits before any arithmetic and moves the PSS path to OpenSSL with direct DER encoding.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and you verify COSE signatures using RSA keys supplied from an untrusted source.

Background info

web-auth/cose-lib is vulnerable to Uncontrolled Resource Consumption in versions 0.0.1 - 4.7.1.

How to fix this

Upgrade the web-auth/cose-lib library to the patch version.

Are You Affected?

Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.

Free. No credit card required.

Aikido Platform