Vulnerabilities/

Use of Insufficiently Random Values in undici

Severity:
Medium

Description

Undici fetch() uses Math.random() to choose the boundary for a multipart/form-data request. It is known that the output of Math.random() can be predicted if several of its generated values are known.

If there is a mechanism in an app that sends multipart requests to an attacker-controlled website, they can use this to leak the necessary values.

Recommendation

Update the undici package to the latest compatible version. Followings are version details:

References

Related Issues

Tags:
npm
undici
Anything's wrong? Let us know Last updated on January 22, 2025

This issue is available in SmartScanner Professional

See Pricing